pub struct Title { /* private fields */ }Expand description
How a terminal’s window title is taken, and given back.
One value carrying both halves, which is the entire point of the type. A title is a
piece of the reader’s terminal that this run borrows, and the rule for everything borrowed
here is that it has to be returnable. No terminal will tell an application what its title
currently is — there is no query to ask — so the only way to put one back is to have asked
the terminal to remember it first, which is what xterm’s title stack is for.
A terminal with no stack ignores the push, ignores the pop, and keeps whatever this run last
set: pristine — freed 41.2 GiB in a tab bar for the rest of that terminal’s life. That is
not a decoration degrading to nothing, it is a decoration that never leaves. So the two
sequences are held together as one capability, and a terminal that is not known to have it
is never sent a title at all — the setting cannot be switched on without the putting back.
Trait Implementations§
impl Copy for Title
impl Eq for Title
impl StructuralPartialEq for Title
Auto Trait Implementations§
impl Freeze for Title
impl RefUnwindSafe for Title
impl Send for Title
impl Sync for Title
impl Unpin for Title
impl UnsafeUnpin for Title
impl UnwindSafe for Title
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more