Fix bug in recursive region highlighting
This commit is contained in:
parent
3c2e7e13c6
commit
63d7984b89
|
@ -1722,8 +1722,7 @@ struct RegionMatches
|
||||||
|
|
||||||
if (beg_pos != end_it->end_coord())
|
if (beg_pos != end_it->end_coord())
|
||||||
beg_pos = end_it->end_coord();
|
beg_pos = end_it->end_coord();
|
||||||
else
|
++end_it;
|
||||||
++end_it;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
1
test/highlight/regions-recurse/cmd
Normal file
1
test/highlight/regions-recurse/cmd
Normal file
|
@ -0,0 +1 @@
|
||||||
|
|
1
test/highlight/regions-recurse/in
Normal file
1
test/highlight/regions-recurse/in
Normal file
|
@ -0,0 +1 @@
|
||||||
|
foo(bar '()')
|
3
test/highlight/regions-recurse/rc
Normal file
3
test/highlight/regions-recurse/rc
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
add-highlighter window/regions_test regions
|
||||||
|
add-highlighter window/regions_test/code default-region fill yellow
|
||||||
|
add-highlighter window/regions_test/argument region '\w+\h*\(\K' '(?=\))' '\(' fill red
|
7
test/highlight/regions-recurse/ui-out
Normal file
7
test/highlight/regions-recurse/ui-out
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
{ "jsonrpc": "2.0", "method": "set_ui_options", "params": [{}] }
|
||||||
|
{ "jsonrpc": "2.0", "method": "draw", "params": [[[{ "face": { "fg": "black", "bg": "white", "attributes": [] }, "contents": "f" }, { "face": { "fg": "yellow", "bg": "default", "attributes": [] }, "contents": "oo(" }, { "face": { "fg": "red", "bg": "default", "attributes": [] }, "contents": "bar '()'" }, { "face": { "fg": "yellow", "bg": "default", "attributes": [] }, "contents": ")\u000a" }]], { "fg": "default", "bg": "default", "attributes": [] }, { "fg": "blue", "bg": "default", "attributes": [] }] }
|
||||||
|
{ "jsonrpc": "2.0", "method": "menu_hide", "params": [] }
|
||||||
|
{ "jsonrpc": "2.0", "method": "info_hide", "params": [] }
|
||||||
|
{ "jsonrpc": "2.0", "method": "draw_status", "params": [[], [{ "face": { "fg": "default", "bg": "default", "attributes": [] }, "contents": "out 1:1 " }, { "face": { "fg": "black", "bg": "yellow", "attributes": [] }, "contents": "" }, { "face": { "fg": "default", "bg": "default", "attributes": [] }, "contents": " " }, { "face": { "fg": "blue", "bg": "default", "attributes": [] }, "contents": "1 sel" }, { "face": { "fg": "default", "bg": "default", "attributes": [] }, "contents": " - client0@[kak-tests]" }], { "fg": "cyan", "bg": "default", "attributes": [] }] }
|
||||||
|
{ "jsonrpc": "2.0", "method": "set_cursor", "params": ["buffer", { "line": 0, "column": 0 }] }
|
||||||
|
{ "jsonrpc": "2.0", "method": "refresh", "params": [true] }
|
Loading…
Reference in New Issue
Block a user