pub enum InsertTextMode {
AsIs,
AdjustIndentation,
}Expand description
How whitespace and indentation is handled during completion item insertion.
@since 3.16.0
Variants§
AsIs
The insertion or replace strings is taken as it is. If the value is multi line the lines below the cursor will be inserted using the indentation defined in the string value. The client will not apply any kind of adjustments to the string.
AdjustIndentation
The editor adjusts leading whitespace of new lines so that they match the indentation up to the cursor of the line for which the item is accepted.
Consider a line like this: <2tabs>
Trait Implementations§
Source§impl Clone for InsertTextMode
impl Clone for InsertTextMode
Source§fn clone(&self) -> InsertTextMode
fn clone(&self) -> InsertTextMode
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for InsertTextMode
impl Debug for InsertTextMode
Source§impl<'de> Deserialize<'de> for InsertTextMode
impl<'de> Deserialize<'de> for InsertTextMode
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<InsertTextMode> for u32
impl From<InsertTextMode> for u32
Source§fn from(e: InsertTextMode) -> Self
fn from(e: InsertTextMode) -> Self
Converts to this type from the input type.
Source§impl Hash for InsertTextMode
impl Hash for InsertTextMode
Source§impl PartialEq for InsertTextMode
impl PartialEq for InsertTextMode
Source§fn eq(&self, other: &InsertTextMode) -> bool
fn eq(&self, other: &InsertTextMode) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for InsertTextMode
impl Serialize for InsertTextMode
Source§impl TryFrom<u32> for InsertTextMode
impl TryFrom<u32> for InsertTextMode
impl Copy for InsertTextMode
impl Eq for InsertTextMode
impl StructuralPartialEq for InsertTextMode
Auto Trait Implementations§
impl Freeze for InsertTextMode
impl RefUnwindSafe for InsertTextMode
impl Send for InsertTextMode
impl Sync for InsertTextMode
impl Unpin for InsertTextMode
impl UnsafeUnpin for InsertTextMode
impl UnwindSafe for InsertTextMode
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
Mutably borrows from an owned value. Read more