pub enum TextPurpose {
Normal,
Password,
Pin,
}Expand description
Cross-seam vocabulary from crcbl-core: the input-event clock, the key
names, and the one sanctioned platform leak.
What a text field taking typing is for, as an input method needs to know
it.
Here rather than in crcbl-shell for the reason CursorIcon is: a UI
names it for its field, and a UI crate depends on this one, not on the
shell.
Exhaustive on purpose, as CursorIcon is: a purpose added later
must fail to compile in every backend’s mapping rather than fall to
Normal through a wildcard arm, because a password read
as ordinary text is one an input method may learn and suggest back.
Variants§
Normal
Ordinary text: the input method may complete, correct and remember.
Password
A password: hidden as typed, and nothing typed may be stored, learned or offered back as a suggestion.
Pin
A PIN: digits, hidden, and not stored, as a password.
Implementations§
Source§impl TextPurpose
impl TextPurpose
Sourcepub const fn is_sensitive(self) -> bool
pub const fn is_sensitive(self) -> bool
Whether what is typed must not be stored, learned or suggested.
Trait Implementations§
Source§impl Clone for TextPurpose
impl Clone for TextPurpose
Source§fn clone(&self) -> TextPurpose
fn clone(&self) -> TextPurpose
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more