Sublime Forum

Brackets color?

#1

Hello,

I can’t find any information about this how can turn on color auto brackets, squares, etc for syntax (php etc.)?
Until last week i used N++ where syntax works like that:

or another example:

i tried with Brackethighlighter but there is only underline or outline (or i cant find it?).
It is possible with any option ST3 or with any another plugin?

0 Likes

#2

Not at the moment.

ST provides an auto match feature for brackets, quotes, … but it underlines them only in a very subtle and hard to realize way. BracketHighlighter is the best option at the moment.

I would appreciate ST’s auto matching feature to change foreground colors like Notepad++ as well.

0 Likes

#3

If I’m understanding correctly, you can set the foreground:

This would set the foreground yellow (old sublime text color scheme):


                <!-- Brackets -->
                <!-- It's not possible to set the background for brackets.
                See https://github.com/SublimeTextIssues/Core/issues/2123. -->
                <key>bracketsOptions</key>              <string>foreground</string>
                <key>bracketsForeground</key>           <string>#e6db74</string>
                <key>bracketContentsOptions</key>       <string>foreground</string>
                <key>bracketContentsForeground</key>    <string>#e6db74</string>

In newer versions of Sublime Text you can use overrides, for example install MonokaiFree and create a custom override with:

{
    "globals":
    {
        "brackets_options": "foreground",
        "bracket_contents_foreground": "foreground"
    },
    "rules":
    [
    ]
}

That will make the foreground of brackets yellow. See https://github.com/gerardroche/sublime-monokai-free/pull/4#issuecomment-418126044 for details on creating overrides.

2 Likes

#4

Works like a charm. Can i do the same with single and double quote? I cant find quote_options and any information about that

1 Like

#5

No, not to my knowledge.

1 Like