Skip to content

Commit

Permalink
字符串的语法高亮中添加空颜色设定的高亮
Browse files Browse the repository at this point in the history
  • Loading branch information
A4-Tacks committed Jan 27, 2024
1 parent 7c4d9d0 commit ee3f9ea
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion syntax/MT-Manager/MindustryLogicBangLang.mtsx
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
1: "error"
}
{ // string color
match: /\[(?:#[\da-fA-F]{6,8}|(?:c(?:lear|yan|oral)|b(?:l(?:ack|ue)|r(?:own|ick))|white|li(?:ghtgray|me)|g(?:r(?:ay|een)|old(?:enrod)?)|darkgray|navy|r(?:oyal|ed)|s(?:late|ky|carlet|almon)|t(?:eal|an)|acid|forest|o(?:live|range)|yellow|p(?:ink|urple)|ma(?:genta|roon)|violet))\]/
match: /\[(?:#[\da-fA-F]{6,8}|(?:c(?:lear|yan|oral)|b(?:l(?:ack|ue)|r(?:own|ick))|white|li(?:ghtgray|me)|g(?:r(?:ay|een)|old(?:enrod)?)|darkgray|navy|r(?:oyal|ed)|s(?:late|ky|carlet|almon)|t(?:eal|an)|acid|forest|o(?:live|range)|yellow|p(?:ink|urple)|ma(?:genta|roon)|violet))?\]/
0: "strEscape"
}
]
Expand Down
2 changes: 1 addition & 1 deletion syntax/vim/mdtlbl.vim
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ setlocal formatoptions+=rq

" 值(Var) {{{1
syn match mdtlblStringFailedEscape /\\\%("\@=\|.\)/ contained
syn match mdtlblStringColor /\[\v%(#\x{6,8}|%(c%(lear|yan|oral)|b%(l%(ack|ue)|r%(own|ick))|white|li%(ghtgray|me)|g%(r%(ay|een)|old%(enrod)?)|darkgray|navy|r%(oyal|ed)|s%(late|ky|carlet|almon)|t%(eal|an)|acid|forest|o%(live|range)|yellow|p%(ink|urple)|ma%(genta|roon)|violet))\]/ contained
syn match mdtlblStringColor /\[\v%(#\x{6,8}|%(c%(lear|yan|oral)|b%(l%(ack|ue)|r%(own|ick))|white|li%(ghtgray|me)|g%(r%(ay|een)|old%(enrod)?)|darkgray|navy|r%(oyal|ed)|s%(late|ky|carlet|almon)|t%(eal|an)|acid|forest|o%(live|range)|yellow|p%(ink|urple)|ma%(genta|roon)|violet))=\]/ contained
syn match mdtlblSpecialChar /^ *\\ \|\\\%([n\\[]\|$\)/ contained
syn region mdtlblString start=/"/ end=/"/ contains=mdtlblSpecialChar,mdtlblStringFailedEscape,mdtlblStringColor

Expand Down

0 comments on commit ee3f9ea

Please sign in to comment.