pub struct TextareaExtras { /* private fields */ }Expand description
What a textarea and a single-line input add: one layer of text decorations, such as inline marks. Their ranges follow edits like an editor’s decoration collections.
Trait Implementations§
Source§impl Default for TextareaExtras
impl Default for TextareaExtras
Source§impl InputExtras for TextareaExtras
impl InputExtras for TextareaExtras
Source§fn decoration_layers(&self) -> Vec<&[TextDecoration]>
fn decoration_layers(&self) -> Vec<&[TextDecoration]>
Decoration ranges to paint, innermost collection first.
Source§fn decorations_revision(&self) -> u64
fn decorations_revision(&self) -> u64
Changes whenever
Self::decoration_layers are set again. Edits that only move
their ranges leave it as it is.Source§fn range_decorations(&self, _ranges: &[Range<usize>]) -> Vec<&RangeDecoration>
fn range_decorations(&self, _ranges: &[Range<usize>]) -> Vec<&RangeDecoration>
Geometric decorations intersecting visible, non-folded buffer spans.
Source§fn gutter_decorations_width(&self) -> Option<Pixels>
fn gutter_decorations_width(&self) -> Option<Pixels>
Return the gutter decoration strip width, or
None when no gutter
collection exists.Source§fn gutter_decorations(&self, _range: Range<usize>) -> Vec<&GutterDecoration>
fn gutter_decorations(&self, _range: Range<usize>) -> Vec<&GutterDecoration>
Return the gutter decorations that touch a UTF-8 byte range, in paint
order. An empty decoration touches the range when it lies inside it.
Source§fn overview_ruler_decorations(&self) -> Vec<&OverviewRulerDecoration>
fn overview_ruler_decorations(&self) -> Vec<&OverviewRulerDecoration>
Return all overview ruler decorations in paint order.
Source§fn overview_ruler_revision(&self) -> u64
fn overview_ruler_revision(&self) -> u64
A number that changes whenever an overview ruler collection is created,
replaced, extended, cleared or released.
Source§fn line_decorations(
&self,
_rows: Range<usize>,
_cx: &App,
) -> Vec<LineDecoration>
fn line_decorations( &self, _rows: Range<usize>, _cx: &App, ) -> Vec<LineDecoration>
Line decorations for the visible buffer rows, in collection order.
Source§fn has_line_decorations(&self) -> bool
fn has_line_decorations(&self) -> bool
Whether any line decoration collection has a provider.
Source§fn has_gutter_icons(&self) -> bool
fn has_gutter_icons(&self) -> bool
Whether any line decoration collection’s provider has gutter icons.
Source§fn spacer_provider(&self) -> Option<Rc<dyn SpacerProvider>>
fn spacer_provider(&self) -> Option<Rc<dyn SpacerProvider>>
The provider of the spacers, if one is set.
Source§fn semantic_token_styles(
&self,
_text: &Rope,
_range: &Range<usize>,
_resolver: &dyn HighlightStyleResolver,
) -> Vec<(Range<usize>, HighlightStyle)>
fn semantic_token_styles( &self, _text: &Rope, _range: &Range<usize>, _resolver: &dyn HighlightStyleResolver, ) -> Vec<(Range<usize>, HighlightStyle)>
Semantic-token styles for a visible range, when an LSP supplies them.
Source§fn document_color_swatches(
&self,
_text: &Rope,
_range: &Range<usize>,
) -> Vec<(Range<usize>, Hsla)>
fn document_color_swatches( &self, _text: &Rope, _range: &Range<usize>, ) -> Vec<(Range<usize>, Hsla)>
Document colours to paint as swatches, when an LSP supplies them.
Source§fn hover_symbol_range(&self) -> Option<Range<usize>>
fn hover_symbol_range(&self) -> Option<Range<usize>>
The symbol range the hover popover is anchored to.
Source§fn inline_completion_item(&self) -> Option<&InlineCompletionItem>
fn inline_completion_item(&self) -> Option<&InlineCompletionItem>
The inline completion to paint as ghost text.
What this mode can offer its context menu: go-to-definition, code actions.
Auto Trait Implementations§
impl Forget for TextareaExtras
impl Freeze for TextareaExtras
impl Move for TextareaExtras
impl RefUnwindSafe for TextareaExtras
impl Send for TextareaExtraswhere
RawVecInner: Send,
impl Sync for TextareaExtraswhere
RawVecInner: Sync,
impl Unpin for TextareaExtras
impl UnsafeUnpin for TextareaExtras
impl UnwindSafe for TextareaExtraswhere
RawVecInner: UnwindSafe,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().