pub struct TerminalWidth { /* private fields */ }Expand description
A nonzero terminal width in columns.
Implementations§
Source§impl TerminalWidth
impl TerminalWidth
Sourcepub const fn new(columns: u16) -> Result<TerminalWidth, TerminalDimensionError>
pub const fn new(columns: u16) -> Result<TerminalWidth, TerminalDimensionError>
Trait Implementations§
Source§impl Clone for TerminalWidth
impl Clone for TerminalWidth
Source§fn clone(&self) -> TerminalWidth
fn clone(&self) -> TerminalWidth
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 TerminalWidth
impl Debug for TerminalWidth
Source§impl Hash for TerminalWidth
impl Hash for TerminalWidth
Source§impl Ord for TerminalWidth
impl Ord for TerminalWidth
Source§fn cmp(&self, other: &TerminalWidth) -> Ordering
fn cmp(&self, other: &TerminalWidth) -> Ordering
1.21.0 (const: unstable) · 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 TerminalWidth
impl PartialEq for TerminalWidth
Source§fn eq(&self, other: &TerminalWidth) -> bool
fn eq(&self, other: &TerminalWidth) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for TerminalWidth
impl PartialOrd for TerminalWidth
impl Copy for TerminalWidth
impl Eq for TerminalWidth
impl StructuralPartialEq for TerminalWidth
Auto Trait Implementations§
impl Freeze for TerminalWidth
impl RefUnwindSafe for TerminalWidth
impl Send for TerminalWidth
impl Sync for TerminalWidth
impl Unpin for TerminalWidth
impl UnsafeUnpin for TerminalWidth
impl UnwindSafe for TerminalWidth
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