pub enum Drawn {
Map,
Nothing,
Cannot(Maps),
}Expand description
What a call to Screen::show left on the terminal.
An answer rather than Ok(()), because “there is no picture” and “the picture is already
right” are the same silence otherwise — which is exactly how #656 went unreported for as
long as it did. The caller can see which it got, and say so.
Variants§
Map
A map is on the terminal: written by this call, or still right from an earlier one.
Nothing
None, because there is nothing under the cursor worth dividing into rectangles — an empty directory, or one whose whole subtree the lens hides. Not a fault in anything.
Cannot(Maps)
None, because this terminal cannot have one — and which of the two reasons it is.
The layout should never have reserved a pane, and this is how the caller finds out
that it did. A run that reaches this has Maps and the pane it was handed
disagreeing, which is #656’s shape returning; the caller’s job is to believe the
screen, which has actually tried, over the layout, which has only asked.
The reason travels with it rather than being assumed at the other end, because the caller assuming would be the wrong sentence under the pane on the terminal where the other reason was the true one.
Trait Implementations§
impl Copy for Drawn
impl Eq for Drawn
impl StructuralPartialEq for Drawn
Auto Trait Implementations§
impl Freeze for Drawn
impl RefUnwindSafe for Drawn
impl Send for Drawn
impl Sync for Drawn
impl Unpin for Drawn
impl UnsafeUnpin for Drawn
impl UnwindSafe for Drawn
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