Skip to main content

Mode

Struct Mode 

Source
pub struct Mode(pub Mode);
Expand description

A terminal mode consisting of its value and its kind (DEC/ANSI).

Tuple Fields§

§0: Mode

Implementations§

Source§

impl Mode

Source

pub const KAM: Self

Source

pub const INSERT: Self

Source

pub const SRM: Self

Source

pub const LINEFEED: Self

Source

pub const DECCKM: Self

Source

pub const _132_COLUMN: Self

Source

pub const SLOW_SCROLL: Self

Source

pub const REVERSE_COLORS: Self

Source

pub const ORIGIN: Self

Source

pub const WRAPAROUND: Self

Source

pub const AUTOREPEAT: Self

Source

pub const X10_MOUSE: Self

Source

pub const CURSOR_BLINKING: Self

Source

pub const CURSOR_VISIBLE: Self

Source

pub const ENABLE_MODE3: Self

Source

pub const REVERSE_WRAP: Self

Source

pub const ALT_SCREEN_LEGACY: Self

Source

pub const KEYPAD_KEYS: Self

Source

pub const LEFT_RIGHT_MARGIN: Self

Source

pub const NORMAL_MOUSE: Self

Source

pub const BUTTON_MOUSE: Self

Source

pub const ANY_MOUSE: Self

Source

pub const FOCUS_EVENT: Self

Source

pub const UTF8_MOUSE: Self

Source

pub const SGR_MOUSE: Self

Source

pub const ALT_SCROLL: Self

Source

pub const URXVT_MOUSE: Self

Source

pub const SGR_PIXELS_MOUSE: Self

Source

pub const NUMLOCK_KEYPAD: Self

Source

pub const ALT_ESC_PREFIX: Self

Source

pub const ALT_SENDS_ESC: Self

Source

pub const REVERSE_WRAP_EXT: Self

Source

pub const ALT_SCREEN: Self

Source

pub const SAVE_CURSOR: Self

Source

pub const ALT_SCREEN_SAVE: Self

Source

pub const BRACKETED_PASTE: Self

Source

pub const SYNC_OUTPUT: Self

Source

pub const GRAPHEME_CLUSTER: Self

Source

pub const COLOR_SCHEME_REPORT: Self

Source

pub const IN_BAND_RESIZE: Self

Source

pub const fn new(v: u16, kind: ModeKind) -> Self

Create a new mode from its numeric value and its kind.

Source

pub const fn value(self) -> u16

The numeric value of the mode.

Source

pub const fn kind(self) -> ModeKind

The kind of the mode (DEC/ANSI).

Trait Implementations§

Source§

impl Clone for Mode

Source§

fn clone(&self) -> Mode

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for Mode

Source§

impl Debug for Mode

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Eq for Mode

Source§

impl From<Mode> for Mode

Source§

fn from(value: Mode) -> Self

Converts to this type from the input type.
Source§

impl Hash for Mode

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
1.3.0 · Source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
Source§

impl PartialEq for Mode

Source§

fn eq(&self, other: &Mode) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl StructuralPartialEq for Mode

Auto Trait Implementations§

§

impl Freeze for Mode

§

impl RefUnwindSafe for Mode

§

impl Send for Mode

§

impl Sync for Mode

§

impl Unpin for Mode

§

impl UnsafeUnpin for Mode

§

impl UnwindSafe for Mode

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.