vim: Fix clipping when navigating over inlay hints (#22813)
This fixes the issue described in this comment: https://github.com/zed-industries/zed/pull/22439#issuecomment-2563896422 Essentially, we'd clip in the wrong direction when there were multi-line inlay hints. It also fixes inline completions for non-Zeta-providers showing up in normal mode. Release Notes: - N/A
This commit is contained in:
@@ -21,6 +21,7 @@ pub trait InlineCompletionProvider: 'static + Sized {
|
||||
fn name() -> &'static str;
|
||||
fn display_name() -> &'static str;
|
||||
fn show_completions_in_menu() -> bool;
|
||||
fn show_completions_in_normal_mode() -> bool;
|
||||
fn is_enabled(
|
||||
&self,
|
||||
buffer: &Model<Buffer>,
|
||||
@@ -61,6 +62,7 @@ pub trait InlineCompletionProviderHandle {
|
||||
cx: &AppContext,
|
||||
) -> bool;
|
||||
fn show_completions_in_menu(&self) -> bool;
|
||||
fn show_completions_in_normal_mode(&self) -> bool;
|
||||
fn refresh(
|
||||
&self,
|
||||
buffer: Model<Buffer>,
|
||||
@@ -101,6 +103,10 @@ where
|
||||
T::show_completions_in_menu()
|
||||
}
|
||||
|
||||
fn show_completions_in_normal_mode(&self) -> bool {
|
||||
T::show_completions_in_normal_mode()
|
||||
}
|
||||
|
||||
fn is_enabled(
|
||||
&self,
|
||||
buffer: &Model<Buffer>,
|
||||
|
||||
Reference in New Issue
Block a user