就这么看json等配置文件,太难了,我们需要括号匹配插件BracketHighlighter,但是装完以后只有下划线提示不明显,需要配置

 

 

Bracket Settings-Default 文件不能修改,只能修改Bracket Settings-User,复制以下设置:

"bracket_styles": {

// "default" and "unmatched" styles are special

// styles. If they are not defined here,

// they will be generated internally with

// internal defaults.

 

// "default" style defines attributes that

// will be used for any style that does not

// explicitly define that attribute. So if

// a style does not define a color, it will

// use the color from the "default" style.

"default": {

"icon": "dot",

// BH1's original default color for reference

//"color": "entity.name.class",

"color": "brackethighlighter.default",

"style": "highlight"

},

 

// This particular style is used to highlight

// unmatched bracket pairs. It is a special

// style.

"unmatched": {

"icon": "question",

"color": "brackethighlighter.unmatched",

"style": "highlight"

},

 

"curly": {

"icon": "curly_bracket",

"color": "brackethighlighter.curly",

"style": "highlight"

},

"round": {

"icon": "round_bracket",

"color": "brackethighlighter.round",

"style": "highlight"

},

"square": {

"icon": "square_bracket",

"color": "brackethighlighter.square",

"style": "highlight"

},

"angle": {

"icon": "angle_bracket",

"color": "brackethighlighter.angle",

"style": "highlight"

},

"tag": {

"icon": "tag",

"color": "brackethighlighter.tag",

"style": "highlight"

},

"c_define": {

"icon": "hash",

"color": "brackethighlighter.c_define",

"style": "highlight"

},

"single_quote": {

"icon": "single_quote",

"color": "brackethighlighter.quote",

"style": "highlight"

},

"double_quote": {

"icon": "double_quote",

"color": "brackethighlighter.quote",

"style": "highlight"

},

"regex": {

"icon": "regex",

"color": "brackethighlighter.quote",

"style": "highlight"

}

}

 

设置好了以后,就是白色的高亮提示,并不好看,并不直观,我要设置的是代码包围效果

就像这样的效果

设置

"high_visibility_enabled_by_default": true,

"high_visibility_style": "outline"

 

但是这样的框框是白色的不是蓝色的,要设置成蓝色的,看官方文档

 

https://facelessuser.github.io/BracketHighlighter/customize/#configuring-highlight-style

 

high_visibility_color

Modifies the high visibility color. There are three types of settings you can use:

  • __default__ is a special reserved value which will use the color set in bracket_styles. SeeConfiguring Highlight Style for more info.
  • __bracket__ is a special reserved value which will inherit the defined color of the highlighted bracket.
  • Any valid scope found in your color scheme.

// Color for high visibility mode

"high_visibility_color":
"__bracket__",

 

There are two special style definitions whose names are reserved: default and unmatched, but you can configure them.

 

Add this to your color scheme:

<dict>

<key>name</key>

<string>Bracket Curly</string>

<key>scope</key>

<string>brackethighlighter.curly</string>

<key>settings</key>

<dict>

<key>foreground</key>

<string>#CC99CC</string>

</dict>

</dict>

And then use the scope:

"curly": {

"icon": "curly_bracket"

"color": "brackethighlighter.curly",

// "style": "underline"

},

所以如果把"high_visibility_color": "__default__",设为default ,它就会用

我在color scheme里brackethighlighter.default定义的值

<dict>

<key>name</key>

<string>Bracket Default</string>

<key>scope</key>

<string>brackethighlighter.default</string>

用这个值

 

但是我怎么能打开传说中的color scheme . tmTheme 文件?搜索也搜不到只有.tmTheme.cache文件,ST3里的文件都被压缩了起来,可以直接从压缩包运行,想要看可以安装 PackageResourceViewer 插件

网页
https://github.com/skuroda/PackageResourceViewer

 

装好以后,open-resource

 

 

找到color Scheme-Default

 

找到自己的Theme

 

在</ array >上面加上

<dict>

<key>name</key>

<string>Bracket Default</string>

<key>scope</key>

<string>brackethighlighter.default</string>

<key>settings</key>

<dict>

<key>foreground</key>

<string>#6495ED</string>

</dict>

</dict>

 

就有了蓝色代码包围效果

更多颜色设置见

http://www.tuicool.com/articles/EV3eEzA

 

效果如下:

 

 

解决问题五大法宝

  1. 谷歌
  2. 百度
  3. 官方文档
  4. 官方论坛
  5. stackOverflow

最新文章

  1. 两千行PHP学习笔记
  2. 通过dataGridView控件中的checkBox控件对数据库进行批量删除
  3. python之优雅处理套接字错误
  4. python中的类中属性元素加self.和不加self.的区别
  5. 转: utf16编码格式(unicode与utf16联系)
  6. HW4.39
  7. PC-删除共享[绝对够狠的方法]
  8. h.264 Mode Decision
  9. HTML5 标签元素的一些注意事项
  10. linux之线程之互斥
  11. js取整
  12. OpenCV编程-&amp;gt;Windows7下调用iPhnoe摄像头
  13. Windows线程同步(上)
  14. Java线程中的同步
  15. File类中的一些属性 添加删除文件夹
  16. 使用java开发spark的wordcount程序(多种实现)
  17. 各数据库连接maven配置
  18. hihocoder 1341 Constraint Checker【string】
  19. linux临时网络配置
  20. HttpClient--使用HttpClient进行Get Post请求访问

热门文章

  1. c语言中#和##的用法
  2. 两个MATLAB在线工具,画图啥的都不用安装了
  3. Lightoj1080 【线段树】
  4. 51nod 1068【简单博弈】
  5. MyBatist庖丁解牛(四)
  6. luoguP3796[模板]AC自动机(加强版)
  7. web项目数据存入mysql数据库中文乱码问题
  8. A - Beautiful numbers
  9. JVM加载类的原理机制
  10. OSPF-1-OSPF的数据库交换(1)