Compare commits
3 commits
dfcca170ef
...
12c4d507b4
| Author | SHA1 | Date | |
|---|---|---|---|
| 12c4d507b4 | |||
| bf8b2d6bcd | |||
| cb189e3936 |
2 changed files with 5 additions and 3 deletions
|
|
@ -47,7 +47,7 @@ bottom_bar: []const u8 = "mode file log selection diagnostics keybind branch lin
|
|||
show_scrollbars: bool = true,
|
||||
show_fileicons: bool = true,
|
||||
show_local_diagnostics_in_panel: bool = false,
|
||||
scrollbar_auto_hide: bool = false,
|
||||
scrollbar_auto_hide: bool = true,
|
||||
|
||||
start_debugger_on_crash: bool = false,
|
||||
|
||||
|
|
|
|||
|
|
@ -6264,11 +6264,11 @@ pub const Editor = struct {
|
|||
pub const highlight_references_meta: Meta = .{ .description = "Language: Highlight references" };
|
||||
|
||||
pub fn add_highlight_reference(self: *Self, match_: Match) void {
|
||||
self.match_type = .highlight_references;
|
||||
if (self.highlight_references_state == .done) {
|
||||
self.highlight_references_state = .adding;
|
||||
self.cancel_all_matches();
|
||||
}
|
||||
self.match_type = .highlight_references;
|
||||
const root = self.buf_root() catch return;
|
||||
var match = match_;
|
||||
match.begin.row -|= 1;
|
||||
|
|
@ -6954,7 +6954,9 @@ pub const EditorWidget = struct {
|
|||
switch (self.editor.match_type) {
|
||||
.find, .auto_find => return,
|
||||
.highlight_references => {
|
||||
if (self.editor.match_at_cursor(primary.cursor) == null) {
|
||||
if (self.editor.match_at_cursor(primary.cursor)) |_| {
|
||||
return;
|
||||
} else {
|
||||
self.editor.cancel_all_matches();
|
||||
tui.need_render();
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue