pub enum VBoxInfo<ET: EngineTypes> {
VBox {
scaled: ToOrSpread<ET::Dim>,
assigned_width: Option<ET::Dim>,
assigned_height: Option<ET::Dim>,
assigned_depth: Option<ET::Dim>,
moved_left: Option<ET::Dim>,
raised: Option<ET::Dim>,
computed_width: OnceLock<ET::Dim>,
computed_height: OnceLock<ET::Dim>,
computed_depth: OnceLock<ET::Dim>,
},
VTop {
scaled: ToOrSpread<ET::Dim>,
assigned_width: Option<ET::Dim>,
assigned_height: Option<ET::Dim>,
assigned_depth: Option<ET::Dim>,
moved_left: Option<ET::Dim>,
raised: Option<ET::Dim>,
computed_width: OnceLock<ET::Dim>,
computed_height: OnceLock<ET::Dim>,
computed_depth: OnceLock<ET::Dim>,
},
VAlignColumn,
VAlignCell {
to: Option<ET::Dim>,
spans: u8,
},
}Expand description
“Metadata” of a vertical box
Variants§
VBox
A “normal” \vbox
Fields
§
scaled: ToOrSpread<ET::Dim>scaling factor
VTop
A \vtop box
Fields
§
scaled: ToOrSpread<ET::Dim>scaling factor
VAlignColumn
A column in a \valign; should only contain VBoxInfo::VAlignCells
VAlignCell
A cell in a \valign
Implementations§
Source§impl<ET: EngineTypes> VBoxInfo<ET>
impl<ET: EngineTypes> VBoxInfo<ET>
Sourcepub fn new_box(scaled: ToOrSpread<ET::Dim>) -> Self
pub fn new_box(scaled: ToOrSpread<ET::Dim>) -> Self
Create a new \vbox box info with the given scaling factor
Sourcepub fn new_top(scaled: ToOrSpread<ET::Dim>) -> Self
pub fn new_top(scaled: ToOrSpread<ET::Dim>) -> Self
Create a new \vtop box info with the given scaling factor
Sourcepub fn open_list(self, start: SourceRef<ET>) -> NodeList<ET>
pub fn open_list(self, start: SourceRef<ET>) -> NodeList<ET>
Turns this box info into the corresponding NodeList
Sourcepub fn clone_for_split(&mut self) -> Self
pub fn clone_for_split(&mut self) -> Self
Clone this box info for use in a split box (i.e. \vsplit)
Source§impl<ET: EngineTypes> VBoxInfo<ET>
impl<ET: EngineTypes> VBoxInfo<ET>
pub fn assigned_height(&self) -> Option<ET::Dim>
pub fn assigned_width(&self) -> Option<ET::Dim>
pub fn assigned_depth(&self) -> Option<ET::Dim>
pub fn computed_height(&self) -> Option<ET::Dim>
pub fn computed_width(&self) -> Option<ET::Dim>
pub fn computed_depth(&self) -> Option<ET::Dim>
pub fn raised(&self) -> Option<ET::Dim>
pub fn moved_left(&self) -> Option<ET::Dim>
pub fn to_or_scaled(&self) -> Option<ToOrSpread<ET::Dim>>
Trait Implementations§
Source§impl<ET: EngineTypes> Display for VBoxInfo<ET>
impl<ET: EngineTypes> Display for VBoxInfo<ET>
impl<ET: Eq + EngineTypes> Eq for VBoxInfo<ET>
impl<ET: EngineTypes> StructuralPartialEq for VBoxInfo<ET>
Auto Trait Implementations§
impl<ET> !Freeze for VBoxInfo<ET>
impl<ET> RefUnwindSafe for VBoxInfo<ET>
impl<ET> Send for VBoxInfo<ET>
impl<ET> Sync for VBoxInfo<ET>
impl<ET> Unpin for VBoxInfo<ET>
impl<ET> UnsafeUnpin for VBoxInfo<ET>
impl<ET> UnwindSafe for VBoxInfo<ET>
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
Converts
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>
Converts
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 moreSource§impl<ET, Err, A> IntoErr<ET, Err> for Awhere
ET: EngineTypes,
Err: From<A>,
impl<ET, Err, A> IntoErr<ET, Err> for Awhere
ET: EngineTypes,
Err: From<A>,
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.