Struct nvim_oxi_api::opts::SetExtmarkOptsBuilder
source · pub struct SetExtmarkOptsBuilder(/* private fields */);Implementations§
source§impl SetExtmarkOptsBuilder
impl SetExtmarkOptsBuilder
sourcepub fn conceal(&mut self, conceal: Option<char>) -> &mut Self
pub fn conceal(&mut self, conceal: Option<char>) -> &mut Self
Enable concealing symilar to :syn-conceal. If a character is supplied
it is used as :syn-cchar.
hl_group is used to highlight the
character if provided, otherwise it defaults to hl-Conceal.
sourcepub fn cursorline_hl_group(&mut self, cursorline_hl_group: &str) -> &mut Self
pub fn cursorline_hl_group(&mut self, cursorline_hl_group: &str) -> &mut Self
Name of the highlight group used to highlight the line when the cursor
is on the same line as the mark and cursorline is enabled.
sourcepub fn end_col(&mut self, end_col: usize) -> &mut Self
pub fn end_col(&mut self, end_col: usize) -> &mut Self
Ending line of the mark. 0-indexed and exclusive.
sourcepub fn end_right_gravity(&mut self, end_right_gravity: bool) -> &mut Self
pub fn end_right_gravity(&mut self, end_right_gravity: bool) -> &mut Self
Indicates the direction the extmark’s end position (if it exists) will
be shifted in when new text is inserted (true for right, false for
left). Defaults to left.
sourcepub fn end_row(&mut self, end_row: usize) -> &mut Self
pub fn end_row(&mut self, end_row: usize) -> &mut Self
Ending line of the mark. 0-indexed and inclusive.
sourcepub fn ephemeral(&mut self, ephemeral: bool) -> &mut Self
pub fn ephemeral(&mut self, ephemeral: bool) -> &mut Self
For use with
set_decoration_provider()
callbacks. The mark will only be used for the current redraw cycle, and
not be permanently stored in the buffer.
sourcepub fn hl_eol(&mut self, hl_eol: bool) -> &mut Self
pub fn hl_eol(&mut self, hl_eol: bool) -> &mut Self
Whether to continue the highlight for the rest of the screen line for multiline highlights covering the EOL of a line.
sourcepub fn hl_group(&mut self, hl_group: &str) -> &mut Self
pub fn hl_group(&mut self, hl_group: &str) -> &mut Self
Name of the highlight group used to highlight this mark.
sourcepub fn hl_mode(&mut self, hl_mode: ExtmarkHlMode) -> &mut Self
pub fn hl_mode(&mut self, hl_mode: ExtmarkHlMode) -> &mut Self
Controls how highlights are combined with the highlights of the text.
sourcepub fn line_hl_group(&mut self, line_hl_group: &str) -> &mut Self
pub fn line_hl_group(&mut self, line_hl_group: &str) -> &mut Self
Name of the highlight group used to highlight the whole line.
sourcepub fn number_hl_group(&mut self, number_hl_group: &str) -> &mut Self
pub fn number_hl_group(&mut self, number_hl_group: &str) -> &mut Self
Name of the highlight group used to highlight the number column.
sourcepub fn priority(&mut self, priority: u32) -> &mut Self
pub fn priority(&mut self, priority: u32) -> &mut Self
A priority value for the highlight group. For example, treesitter highlights use a value of 100.
sourcepub fn right_gravity(&mut self, right_gravity: bool) -> &mut Self
pub fn right_gravity(&mut self, right_gravity: bool) -> &mut Self
Indicates the direction the extmark will be shifted in when new text is
inserted (true for right, false for left). Defaults to right.
sourcepub fn sign_hl_group(&mut self, sign_hl_group: &str) -> &mut Self
pub fn sign_hl_group(&mut self, sign_hl_group: &str) -> &mut Self
Name of the highlight group used to highlight the sign column text.
sourcepub fn sign_text(&mut self, sign_text: &str) -> &mut Self
pub fn sign_text(&mut self, sign_text: &str) -> &mut Self
Text to display in the sign column. Should take up 1-2 display cells.
sourcepub fn strict(&mut self, strict: bool) -> &mut Self
pub fn strict(&mut self, strict: bool) -> &mut Self
Whether the extmark should not be placed if the line or column value is
past the end of the buffer or end of the line, respectively. Defaults
to true.
sourcepub fn ui_watched(&mut self, ui_watched: bool) -> &mut Self
pub fn ui_watched(&mut self, ui_watched: bool) -> &mut Self
Whether the mark should be drawn by an external UI. When true the UI
will receive win_extmark events.
sourcepub fn virt_lines<Txt, Hl, Cnk, ChunkyCnk>(
&mut self,
virt_lines: ChunkyCnk
) -> &mut Selfwhere
ChunkyCnk: IntoIterator<Item = Cnk>,
Cnk: IntoIterator<Item = (Txt, Hl)>,
Txt: Into<String>,
Hl: StringOrListOfStrings,
pub fn virt_lines<Txt, Hl, Cnk, ChunkyCnk>(
&mut self,
virt_lines: ChunkyCnk
) -> &mut Selfwhere
ChunkyCnk: IntoIterator<Item = Cnk>,
Cnk: IntoIterator<Item = (Txt, Hl)>,
Txt: Into<String>,
Hl: StringOrListOfStrings,
Virtual lines to add next to the mark.
sourcepub fn virt_lines_above(&mut self, virt_lines_above: bool) -> &mut Self
pub fn virt_lines_above(&mut self, virt_lines_above: bool) -> &mut Self
Whether to place virtual lines above the buffer line containing the mark.
sourcepub fn virt_lines_leftcol(&mut self, virt_lines_leftcol: bool) -> &mut Self
pub fn virt_lines_leftcol(&mut self, virt_lines_leftcol: bool) -> &mut Self
Whether to place extmarks in the leftmost column of the ewindow, bypassing sign and number columns.
sourcepub fn virt_text<Txt, Hl, Cnk>(&mut self, virt_text: Cnk) -> &mut Self
pub fn virt_text<Txt, Hl, Cnk>(&mut self, virt_text: Cnk) -> &mut Self
Virtual text to link to this mark. Every (text, highlights) tuple
represents a text chunk with a specified highlight. The highlights
specified in highlights will be combined together, with the highest
priority highlight beign applied last. Each highlight group can either
be a string or an integer, the latter obtained using
get_hl_id_by_name().
sourcepub fn virt_text_hide(&mut self, virt_text_hide: bool) -> &mut Self
pub fn virt_text_hide(&mut self, virt_text_hide: bool) -> &mut Self
Whether to hide the virtual text when the background text is selected or hidden due to horizontal scroll.
sourcepub fn virt_text_pos(
&mut self,
virt_text_pos: ExtmarkVirtTextPosition
) -> &mut Self
pub fn virt_text_pos( &mut self, virt_text_pos: ExtmarkVirtTextPosition ) -> &mut Self
Position of the virtual text.
sourcepub fn virt_text_win_col(&mut self, virt_text_win_col: u32) -> &mut Self
pub fn virt_text_win_col(&mut self, virt_text_win_col: u32) -> &mut Self
Position the virtual text at a fixed window column (starting from the first text column).
pub fn build(&mut self) -> SetExtmarkOpts
Trait Implementations§
source§impl Clone for SetExtmarkOptsBuilder
impl Clone for SetExtmarkOptsBuilder
source§fn clone(&self) -> SetExtmarkOptsBuilder
fn clone(&self) -> SetExtmarkOptsBuilder
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Default for SetExtmarkOptsBuilder
impl Default for SetExtmarkOptsBuilder
source§fn default() -> SetExtmarkOptsBuilder
fn default() -> SetExtmarkOptsBuilder
Auto Trait Implementations§
impl Freeze for SetExtmarkOptsBuilder
impl RefUnwindSafe for SetExtmarkOptsBuilder
impl !Send for SetExtmarkOptsBuilder
impl !Sync for SetExtmarkOptsBuilder
impl Unpin for SetExtmarkOptsBuilder
impl UnwindSafe for SetExtmarkOptsBuilder
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
§type Error = Infallible
type Error = Infallible
Result.source§fn into_result(self) -> Result<T, <T as IntoResult<T>>::Error>
fn into_result(self) -> Result<T, <T as IntoResult<T>>::Error>
Result.