TextInputMethodComposition
struct · ferroui-base · v0.5.0
struct TextInputMethodComposition
A platform composition bound to one connection and one accepted client state. Clones refer to the same session. Late callbacks fail after reset, focus handoff, external edits, or a newer native composition.
Members
is_current
fn is_current(self: &Self) -> bool
update
fn update(self: &Self, text: &str, cursor: Option<i32>) -> Result<(), TextInputMethodError>
apply_edit
fn apply_edit(self: &Self, edit: &TextInputMethodEdit) -> Result<bool, TextInputMethodError>
Applies the platform's delta to the current preview without committing history. The resulting selection is part of this operation.
select_exact
fn select_exact(self: &Self, selection: super::TextSelection) -> Result<(), TextInputMethodError>
complete
fn complete(self: &Self, timestamp: u64) -> Result<bool, TextInputMethodError>
Commits exactly the accepted preview, including empty deletions and arbitrary directed selection, as one undo transaction.
commit
fn commit(self: &Self, text: &str, timestamp: u64) -> Result<bool, TextInputMethodError>
cancel
fn cancel(self: &Self) -> Result<bool, TextInputMethodError>
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeClassDefaultsBorrow<T>BorrowMut<T>CloneToUninitInto<U>From<T>TryInto<U>TryFrom<U>AnyToOwnedErasedDestructorIntoEitherClone
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.