pub struct TextInputState {
pub revision: u32,
pub text: String,
pub selection: TextSelection,
pub composing: TextRange,
}
Expand description
The current text, selection, and composing state for editing a run of text.
Fields§
§revision: u32
Current state revision to avoid race conditions.
text: String
The current text being edited.
selection: TextSelection
The range of text that is currently selected.
composing: TextRange
The range of text that is still being composed.
Trait Implementations§
Source§impl Clone for TextInputState
impl Clone for TextInputState
Source§fn clone(&self) -> TextInputState
fn clone(&self) -> TextInputState
Returns a copy of the value. Read more
1.0.0 · 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 TextInputState
impl Debug for TextInputState
Source§impl<D: ResourceDialect> Decode<TextInputState, D> for TextInputState
impl<D: ResourceDialect> Decode<TextInputState, D> for TextInputState
Source§impl<D: ResourceDialect> Encode<TextInputState, D> for &TextInputState
impl<D: ResourceDialect> Encode<TextInputState, D> for &TextInputState
Source§impl<D: ResourceDialect, T0: Encode<u32, D>, T1: Encode<UnboundedString, D>, T2: Encode<TextSelection, D>, T3: Encode<TextRange, D>> Encode<TextInputState, D> for (T0, T1, T2, T3)
impl<D: ResourceDialect, T0: Encode<u32, D>, T1: Encode<UnboundedString, D>, T2: Encode<TextSelection, D>, T3: Encode<TextRange, D>> Encode<TextInputState, D> for (T0, T1, T2, T3)
Source§impl Hash for TextInputState
impl Hash for TextInputState
Source§impl Ord for TextInputState
impl Ord for TextInputState
Source§fn cmp(&self, other: &TextInputState) -> Ordering
fn cmp(&self, other: &TextInputState) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for TextInputState
impl PartialEq for TextInputState
Source§impl PartialOrd for TextInputState
impl PartialOrd for TextInputState
Source§impl TypeMarker for TextInputState
impl TypeMarker for TextInputState
Source§type Owned = TextInputState
type Owned = TextInputState
The owned Rust type which this FIDL type decodes into.
Source§fn inline_align(_context: Context) -> usize
fn inline_align(_context: Context) -> usize
Returns the minimum required alignment of the inline portion of the
encoded object. It must be a (nonzero) power of two.
Source§fn inline_size(_context: Context) -> usize
fn inline_size(_context: Context) -> usize
Returns the size of the inline portion of the encoded object, including
padding for alignment. Must be a multiple of
inline_align
.§fn encode_is_copy() -> bool
fn encode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and encoding requires no validation. When true, we can optimize
encoding arrays and vectors of Self::Owned
to a single memcpy. Read more§fn decode_is_copy() -> bool
fn decode_is_copy() -> bool
Returns true if the memory layout of
Self::Owned
matches the FIDL wire
format and decoding requires no validation. When true, we can optimize
decoding arrays and vectors of Self::Owned
to a single memcpy.Source§impl ValueTypeMarker for TextInputState
impl ValueTypeMarker for TextInputState
Source§type Borrowed<'a> = &'a TextInputState
type Borrowed<'a> = &'a TextInputState
The Rust type to use for encoding. This is a particular
Encode<Self>
type cheaply obtainable from &Self::Owned
. There are three cases: Read moreimpl Eq for TextInputState
impl Persistable for TextInputState
impl StructuralPartialEq for TextInputState
Auto Trait Implementations§
impl Freeze for TextInputState
impl RefUnwindSafe for TextInputState
impl Send for TextInputState
impl Sync for TextInputState
impl Unpin for TextInputState
impl UnwindSafe for TextInputState
Blanket Implementations§
§impl<T> Body for Twhere
T: Persistable,
impl<T> Body for Twhere
T: Persistable,
§type MarkerAtTopLevel = T
type MarkerAtTopLevel = T
The marker type to use when the body is at the top-level.
§type MarkerInResultUnion = T
type MarkerInResultUnion = T
The marker type to use when the body is nested in a result union.
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)