pub struct TextInputResponse {
pub changed: bool,
pub text: String,
pub supported: bool,
pub focused: bool,
}Expand description
Result of a text_input widget.
Fields§
§changed: boolWhether the text changed this frame.
text: StringThe current text contents.
supported: boolWhether the active adapter actually rendered this widget.
focused: boolWhether this text input currently has keyboard focus.
§Headless-approximate note
This field is a best-effort approximation. Backends that lack a real
focus mechanism (e.g. headless state-machine contexts) always report
false. Backends that wire iced focus events may set this accurately
in a future milestone.
Implementations§
Source§impl TextInputResponse
impl TextInputResponse
Sourcepub fn unsupported() -> Self
pub fn unsupported() -> Self
The “not implemented by this adapter” response: empty text, not changed,
supported = false.
Trait Implementations§
Source§impl Clone for TextInputResponse
impl Clone for TextInputResponse
Source§fn clone(&self) -> TextInputResponse
fn clone(&self) -> TextInputResponse
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 TextInputResponse
impl Debug for TextInputResponse
Source§impl Default for TextInputResponse
impl Default for TextInputResponse
Source§fn default() -> TextInputResponse
fn default() -> TextInputResponse
Returns the “default value” for a type. Read more
Source§impl PartialEq for TextInputResponse
impl PartialEq for TextInputResponse
Source§fn eq(&self, other: &TextInputResponse) -> bool
fn eq(&self, other: &TextInputResponse) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TextInputResponse
Auto Trait Implementations§
impl Freeze for TextInputResponse
impl RefUnwindSafe for TextInputResponse
impl Send for TextInputResponse
impl Sync for TextInputResponse
impl Unpin for TextInputResponse
impl UnsafeUnpin for TextInputResponse
impl UnwindSafe for TextInputResponse
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