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