mirror of
https://github.com/chylex/IntelliJ-Rainbow-Brackets.git
synced 2025-04-10 18:15:50 +02:00
Merge branch 'IC-2017.2' into kotlin-label
This commit is contained in:
commit
c3e975af9f
@ -15,7 +15,7 @@
|
||||
|
||||
# Table of Contents
|
||||
|
||||
- [Rainbow Brackets](#rainbow-brackets)
|
||||
- [Table of Contents](#table-of-contents)
|
||||
- [Compatibility](#compatibility)
|
||||
- [Supported languages](#supported-languages)
|
||||
- [Screenshots](#screenshots)
|
||||
@ -55,7 +55,7 @@ Java, Scala, Clojure, Kotlin, Python, Haskell, Agda, Rust, JavaScript, TypeScrip
|
||||
|
||||
* with Kotlin
|
||||
|
||||

|
||||

|
||||
|
||||
* with HTML/XML
|
||||
|
||||
@ -167,7 +167,7 @@ var html = '<div><div><div>Hello</div></div></div>';
|
||||
```
|
||||
|
||||
This plugin will automatically override color scheme "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 `<option name="rainbowifyHTMLInsideJS" value="true" />` in config file to disable just like [Config brackets colors](#config-brackets-colors).
|
||||
You still could set `<option name="rainbowifyHTMLInsideJS" value="false" />` in config file to disable just like [Config brackets colors](#config-brackets-colors).
|
||||
|
||||
## Kotlin function literal braces and arrow
|
||||
|
||||
@ -187,7 +187,7 @@ event.throwable?.let { throwable ->
|
||||
```
|
||||
|
||||
This plugin will automatically override color scheme "KOTLIN_FUNCTION_LITERAL_BRACES_AND_ARROW" cause our rainbow color been covered by kotlin plugin built-in functionality.
|
||||
You still could set `<option name="isRainbowifyKotlinFunctionLiteralBracesAndArrow" value="true" />` in config file to disable just like [Config brackets colors](#config-brackets-colors).
|
||||
You still could set `<option name="rainbowifyKotlinFunctionLiteralBracesAndArrow" value="false" />` in config file to disable just like [Config brackets colors](#config-brackets-colors).
|
||||
|
||||
## Contribute
|
||||
|
||||
|
Binary file not shown.
Before ![]() (image error) Size: 97 KiB After ![]() (image error) Size: 106 KiB ![]() ![]() |
@ -10,6 +10,7 @@ import com.intellij.openapi.editor.colors.TextAttributesKey.createTextAttributes
|
||||
import com.intellij.openapi.editor.markup.EffectType
|
||||
import com.intellij.openapi.editor.markup.TextAttributes
|
||||
import com.intellij.openapi.extensions.PluginId
|
||||
import java.awt.Color
|
||||
import java.awt.Font
|
||||
|
||||
class RainbowComponent : ApplicationComponent {
|
||||
@ -36,6 +37,11 @@ class RainbowComponent : ApplicationComponent {
|
||||
globalScheme.setAttributes(createTextAttributesKey("KOTLIN_LABEL"),
|
||||
TextAttributes(null, null, null, EffectType.BOXED, Font.PLAIN))
|
||||
}
|
||||
|
||||
if (settings.isOverrideMatchedBraceAttributes) {
|
||||
globalScheme.setAttributes(createTextAttributesKey("MATCHED_BRACE_ATTRIBUTES"),
|
||||
TextAttributes(null, Color(Integer.decode("0x3b514d")), null, EffectType.BOXED, Font.BOLD))
|
||||
}
|
||||
}
|
||||
|
||||
companion object {
|
||||
|
@ -23,6 +23,7 @@ class RainbowSettings : PersistentStateComponent<RainbowSettings> {
|
||||
var isRainbowifyHTMLInsideJS = true
|
||||
var isRainbowifyKotlinFunctionLiteralBracesAndArrow = true
|
||||
var isRainbowifyKotlinLabel = true
|
||||
var isOverrideMatchedBraceAttributes = true
|
||||
|
||||
var lightRoundBracketsColors = arrayOf(
|
||||
"0xE66A01",
|
||||
|
@ -4,7 +4,7 @@
|
||||
<vendor email="izhangzhihao@hotmail.com" url="https://github.com/izhangzhihao">izhangzhihao</vendor>
|
||||
|
||||
<description><![CDATA[
|
||||
<strong>Rainbow Brackets / Rainbow Parentheses for IntelliJ IDEA-based IDEs</strong>
|
||||
<strong>Rainbow Brackets / Rainbow Parentheses for IntelliJ based IDEs</strong>
|
||||
<br/>
|
||||
<p>Supported languages:</p>
|
||||
<p>Java, Scala, Clojure, Kotlin, Python, Haskell, Agda, Rust, JavaScript, TypeScript, Erlang, Go, Groovy, Ruby, Elixir, ObjectiveC, PHP, HTML, XML, SQL, Apex language ...</p>
|
||||
@ -12,10 +12,11 @@
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-java.png" border="0" width="500" height="205" alt="with-java"/></p>
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-material-theme-ui.png" border="0" width="500" height="167" alt="with-material-theme-ui.png"/></p>
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-scala.png" border="0" width="500" height="250" alt="with-scala"/></p>
|
||||
<p><img src="https://user-images.githubusercontent.com/12044174/40778403-9d9165f0-6503-11e8-8ee2-b3d0262d9fd6.png" border="0" width="500" height="191" alt="with-kotlin"/></p>
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-Clojure.png" border="0" width="500" height="200" alt="with-Clojure.png"/></p>
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-kotlin.png" border="0" width="500" height="191" alt="with-kotlin"/></p>
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-Clojure.png" border="0" width="500" height="190" alt="with-Clojure.png"/></p>
|
||||
<p><img src="https://raw.githubusercontent.com/izhangzhihao/intellij-rainbow-brackets/IC-2017.2/screenshots/with-HTML.png" border="0" width="500" height="112" alt="with-HTML.png"/></p>
|
||||
<p><img src="https://user-images.githubusercontent.com/10737066/39988979-5df3f05e-579b-11e8-8d19-7d9e95c7a0b5.gif" border="0" width="500" height="206" alt="Highlight current scope.gif"/></p>
|
||||
<p><img src="https://user-images.githubusercontent.com/10737066/40234968-46593fe2-5adb-11e8-8ea8-0026fad86ca9.gif" border="0" width="500" height="206" alt="Highlight current scope.gif"/></p>
|
||||
<p><img src="https://user-images.githubusercontent.com/10737066/40235004-642dfe54-5adb-11e8-9fd7-648b92fab8f5.gif" border="0" width="500" height="206" alt="Highlight current scope.gif"/></p>
|
||||
]]></description>
|
||||
|
||||
<change-notes><![CDATA[
|
||||
|
Loading…
Reference in New Issue
Block a user