# intellij-rainbow-brackets **Repository Path**: thoughtworks/intellij-rainbow-brackets ## Basic Information - **Project Name**: intellij-rainbow-brackets - **Description**: 🌈Rainbow Brackets for IntelliJ based IDEs/Android Studio - **Primary Language**: Kotlin - **License**: Apache-2.0 - **Default Branch**: 2020.1 - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 15 - **Forks**: 2 - **Created**: 2021-06-08 - **Last Updated**: 2025-08-06 ## Categories & Tags **Categories**: idea-plugins **Tags**: None ## README
logo

Intellij rainbow brackets

Rainbow Brackets / Rainbow Parentheses for IntelliJ based IDEs.


- [Compatibility](#compatibility) - [Supported languages](#supported-languages) - [Author's choice](#authors-choice) - [Sponsored By](#sponsored-by) - [Screenshots](#screenshots) - [Install](#install) - [Customize colors](#customize-colors) - [Use color generator](#use-color-generator) - [Config file path](#config-file-path) - [HTML code in js](#html-code-in-js) - [Kotlin function literal braces and arrow](#kotlin-function-literal-braces-and-arrow) - [Disable rainbow brackets for specific languages](#disable-rainbow-brackets-for-specific-languages) - [Contribute](#contribute) - [Support Us](#support-us) - [Backers](#backers) - [Sponsors](#sponsors) - [Acknowledgements](#acknowledgements) ## 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](https://github.com/tonsky/FiraCode) (Font) ## Sponsored By This plugin is being sponsored by [Codota](https://www.codota.com/?utm_source=jbmarket&utm_campaign=jbrainbowbrackets&utm_medium=banner) and [CodeStream](https://sponsorlink.codestream.com/?utm_source=jbmarket&utm_campaign=jbrainbowbrackets&utm_medium=banner). Code faster and smarter using code completions learned from millions of programs directly in IntelliJ, Android Studio or Eclipse. [Get Codota](https://www.codota.com/?utm_source=jbmarket&utm_campaign=jbrainbowbrackets&utm_medium=banner) [![https://codestream.com](https://alt-images.codestream.com/codestream_logo_jbrainbowbrackets.png)](https://sponsorlink.codestream.com/?utm_source=jbmarket&utm_campaign=jbrainbowbrackets&utm_medium=banner) 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](https://sponsorlink.codestream.com/?utm_source=jbmarket&utm_campaign=jbrainbowbrackets&utm_medium=banner)! Development powered by [JetBrains](https://www.jetbrains.com/?from=IntelliJRainbowBrackets). [![https://www.jetbrains.com/?from=IntelliJRainbowBrackets](./screenshots/jetbrains.svg)](https://www.jetbrains.com/?from=IntelliJRainbowBrackets) Whichever technologies you use, there's a JetBrains tool to match. ## Screenshots * with Java ![](./screenshots/with-java.png) ![](./screenshots/with-material-theme-ui.png) * with Scala ![](./screenshots/with-scala.png) * with Clojure ![](./screenshots/with-Clojure.png) * with Kotlin ![](./screenshots/with-kotlin.png) * with HTML/XML ![](./screenshots/with-HTML.png) * 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. ![](https://user-images.githubusercontent.com/10737066/40234968-46593fe2-5adb-11e8-8ea8-0026fad86ca9.gif) Alt + Button3: NOTE: Button3 means "Secondary Click (click or tap with two fingers)" on Mac os, "Right click" for Windows or Linux. ![](https://user-images.githubusercontent.com/10737066/40235004-642dfe54-5adb-11e8-9fd7-648b92fab8f5.gif) * Rainbow indent guide lines ![](https://user-images.githubusercontent.com/10737066/65765792-c41cb500-e15b-11e9-8877-2239c6afa7bf.gif) * [night-owl-jetbrains](https://github.com/xdrop/night-owl-jetbrains) ![](https://github.com/xdrop/night-owl-jetbrains/raw/2018.2/screenshot.png) * looking forward to your screenshots(PR welcome!) ## Install For Windows & Linux - File > Settings > Plugins > Marketplace > Search for "Rainbow Brackets" > Install Plugin > Restart IntelliJ IDEA For Mac - IntelliJ IDEA > Preferences > Plugins > Marketplace > Search for "Rainbow Brackets" > Install Plugin > Restart IntelliJ IDEA ### Install snapshot build You can download the latest snapshot build from [here](https://circleci.com/gh/izhangzhihao/intellij-rainbow-brackets), just click in the latest build and click the 'Artifacts' tab.(You must logged in via github) ## Customize colors Settings/Preferences > Editor > Color Scheme > Rainbow Brackets: ![Customize colors](./screenshots/customize-colors.png) ## Use color generator I didn't like the build-in colors, I want some new color but does want to try out and pick colors. Please use color generator. Settings/Preferences > Other Settings > Rainbow Brackets > Use color generator If you turn on this option, we will auto generate some colors for you. If you need more control, you can decide the options of color generator by edit [the config file](#config-file-path), The value of the option `customColorGeneratorOption` is a json object, available options are: ```hue``` – Controls the hue of the generated color. You can pass a string representing a color name: ```red```, ```orange```, ```yellow```, ```green```, ```blue```, ```purple```, ```pink``` and ```monochrome``` are currently supported. If you pass a hexidecimal color string such as ```#00FFFF```, color generator will extract its hue value and use that to generate colors. ```luminosity``` – Controls the luminosity of the generated color. You can specify a string containing ```bright```, ```light``` or ```dark```. Please make sure the value of the option `customColorGeneratorOption` is escaped in xml format, you can use [this tool](https://www.freeformatter.com/xml-escape.html#ad-output) to do this. Please don't forget to restart your IDE after change the config file. ```xml ``` ### Want to config the number of colors? Settings/Preferences > Other Settings > Rainbow Brackets > `Number of colors`: 5 or more NOTE: For default and darcula color scheme(`Editor -> Color Scheme -> Rainbow Brackets -> Scheme`) the color number is 10, for the other scheme the number is 5, if your number is bigger than the number, you can config them in the config file. If the color is not exist, we will use color generator to generator it for you. Please follow [the official guide](https://www.jetbrains.com/help/idea/configuring-colors-and-fonts.html#share-color-scheme): * `Export a color scheme as XML` * Edit the xml file, put `ROUND_BRACKETS_RAINBOW_COLOR5` to `ROUND_BRACKETS_RAINBOW_COLOR100` to match your number just like [the default color scheme](./src/main/resources/colorSchemes/rainbow-color-default-darcula.xml). * `Import a color scheme` ## Config file path If you want to customize the 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 `~/Library/Preferences/IntelliJIdea2020.1/options/rainbow_brackets.xml`. If you are using the ToolBox, then it will be like `~/Library/ApplicationSupport/JetBrains/IntelliJIdea2020.1/options/rainbow_brackets.xml` In Linux env maybe like `~/.IntelliJIdea/config/options/rainbow_brackets.xml`. In Windows env maybe like `C:\Users\izhangzhihao\.IntelliJIdea2020.1\config\options\rainbow_brackets.xml`. ## HTML code in js To enable rainbow brackets for HTML inside js code like this: ```javascript var html = '
Hello
'; ``` This plugin will automatically override color scheme property "HTML_CODE" [cause our rainbow color been covered by intellij built-in functionality](https://intellij-support.jetbrains.com/hc/en-us/community/posts/360000117450-My-HighlightVisitor-been-covered-by-intellij-built-in-functionality). You still could set `