GithubHelp home page GithubHelp logo

chrisdeely / intellij-rainbow-brackets Goto Github PK

View Code? Open in Web Editor NEW

This project forked from izhangzhihao/intellij-rainbow-brackets

0.0 2.0 0.0 1.81 MB

🌈Rainbow Brackets / Rainbow Parentheses for IntelliJ based IDEs

Home Page: https://plugins.jetbrains.com/plugin/10080-rainbow-brackets

License: Apache License 2.0

Kotlin 100.00%

intellij-rainbow-brackets's Introduction

Intellij rainbow brackets

Rainbow Brackets / Rainbow Parentheses for IntelliJ based IDEs.


Compatibility

IntelliJ IDEA, PhpStorm, WebStorm, PyCharm, RubyMine, AppCode, CLion, Gogland, DataGrip, Rider, MPS, Android Studio

Supported languages

Java, Scala, Clojure, Kotlin, Python, Haskell, Agda, Rust, JavaScript, TypeScript, Erlang, Go, Groovy, Ruby, Elixir, ObjectiveC, PHP, HTML, XML, SQL, Apex language, C#, Dart, ...

Author's choice

Rainbow Brackets + Material Theme UI(Oceanic theme) + Nyan Progress Bar + Fira Code (Font)

Sponsored By

The Intellij Rainbow Brackets plugin is sponsored by CodeStream.

https://codestream.com

Discussing code is now as easy as highlighting a block and typing a comment right from your IDE. Take the pain out of code reviews and improve code quality. Try it free!

Screenshots

  • with Java

  • with Scala

  • with Clojure

  • with Kotlin

  • with HTML/XML

  • Scope highlighting

The highlight effects will not remove after release the shortcuts, but press ESC key can do this. You could also config Press any key to remove the highlighting effect in setting page.

Ctrl + Button3(Windows & Linux) or Meta+ Button3(Mac):

NOTE: Button3 means "Secondary Click (click or tap with two fingers)" on Mac os, "Right click" for Windows or Linux.

Alt + Button3:

NOTE: Button3 means "Secondary Click (click or tap with two fingers)" on Mac os, "Right click" for Windows or Linux.

  • Rainbow indent guide lines

  • looking forward to your screenshots(PR welcome!)

Install

For Windows - File > Settings > Plugins > Browse repositories... > Search for "Rainbow Brackets" > Install Plugin > Restart IntelliJ IDEA

For Mac - IntelliJ IDEA > Preferences > Plugins > Browse repositories... > Search for "Rainbow Brackets" > Install Plugin > Restart IntelliJ IDEA

Customize colors

Settings/Preferences > Editor > Color Scheme > Rainbow Brackets:

Customize colors

Config file path

If you want to customize advanced configuration, you could edit the config file then restart your IDE. Config file path in APP_CONFIG/rainbow_brackets.xml.

In MAC OS env maybe like /Users/izhangzhihao/Library/Preferences/IntelliJIdea2018.3/options/rainbow_brackets.xml.

In Linux env maybe like ~/.IntelliJIdea/config/options/rainbow_brackets.xml.

In Windows env maybe like C:\Users\izhangzhihao\.IntelliJIdea2018.3\config\options\rainbow_brackets.xml.

HTML code in js

To enable rainbow brackets for HTML inside js code like this:

var html = '<div><div><div>Hello</div></div></div>';

This plugin will automatically override color scheme property "HTML_CODE" cause our rainbow color been covered by intellij built-in functionality. You still could set <option name="rainbowifyHTMLInsideJS" value="false" /> in config file to disable just like Config brackets colors.

Kotlin function literal braces and arrow

To enable rainbow brackets for multiple level lambda Kotlin code like this:

event.throwable?.let { throwable ->
    IdeErrorsDialog.findPluginId(throwable)?.let { pluginId ->
        PluginManager.getPlugin(pluginId)?.let { ideaPluginDescriptor ->
            if (!ideaPluginDescriptor.isBundled) {
                bean.pluginName = ideaPluginDescriptor.name
                bean.pluginVersion = ideaPluginDescriptor.version
            }
        }
    }
}

This plugin will automatically override color scheme property "KOTLIN_FUNCTION_LITERAL_BRACES_AND_ARROW" cause our rainbow color been covered by kotlin plugin built-in functionality. You still could set <option name="rainbowifyKotlinFunctionLiteralBracesAndArrow" value="false" /> in config file to disable just like Config brackets colors.

Disable rainbow brackets for specific languages

If you want to disable rainbow brackets for javascript languages and java languages, you could set languageBlacklist property in config file just like:

<application>
  <component name="RainbowSettings">
    <option name="languageBlacklist">
      <array>
        <option value="java" />
        <option value="javascript" />
      </array>
    </option>
  </component>
</application>

NOTE: The languages name should be lowercase, and do NOT use shorthand.

Contribute

NOTE: To view the PSI tree and explore the internal structure of source code, you need to setup your IDE follow this.

  • gradle test
  • gradle runIde
  • gradle buildPlugin

Support Us

You can support us by the following actions:

  • Star this project on GitHub
  • Share this plugin with your friends/colleagues
  • Rate this plugin on JetBrains plugin repository
  • Make pull requests
  • Report bugs
  • Tell us your ideas
  • Become a sponsor by donating on Open Collective
  • Become a sponsor by donating with AliPay or WeChatPay
AliPay WeChatPay

Backers

Thank you to all our backers! ❤️ [Become a backer]

Sponsors

Support this project by becoming a sponsor! 🌈 Your logo will show up here with a link to your website. [Become a sponsor]

Acknowledgements

Intellij-rainbow-brackets is heavily inspired by Rainbow Brackets for Visual Studio Code

intellij-rainbow-brackets's People

Contributors

codacy-badger avatar gazialankus avatar gitter-badger avatar imgbotapp avatar intellij-rainbow-brackets avatar izhangzhihao avatar onisuly avatar yiiguxing avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.