pub struct SplitPaneSpec { /* private fields */ }Expand description
One leaf of a SplitLayout: a named place the caller puts content.
Implementations§
Source§impl SplitPaneSpec
impl SplitPaneSpec
pub fn new(id: impl Into<SharedString>) -> Self
Sourcepub fn min(self, min: f32) -> Self
pub fn min(self, min: f32) -> Self
The smallest this pane may be drawn at on either axis, in pixels.
A pane that only cares about one axis states that axis instead: a file tree that needs 180px of width does not thereby need 180px of height, and saying so would stop a divider it has nothing to do with.
pub fn min_width(self, min: f32) -> Self
pub fn min_height(self, min: f32) -> Self
Sourcepub fn rail(self, rail: f32) -> Self
pub fn rail(self, rail: f32) -> Self
How wide the pane is while collapsed. A rail of zero removes the pane from the drawing entirely.
Sourcepub fn collapsed(self, collapsed: bool) -> Self
pub fn collapsed(self, collapsed: bool) -> Self
Whether the caller says this pane is collapsed. A collapsed pane is drawn at its rail extent and its divider is not offered, because there is nothing to drag it between.
pub fn id(&self) -> &SharedString
Sourcepub fn min_size(&self, axis: SplitAxis) -> f32
pub fn min_size(&self, axis: SplitAxis) -> f32
The smallest this pane may be drawn at along axis, in pixels.
pub fn rail_size(&self) -> f32
pub fn is_collapsed(&self) -> bool
Trait Implementations§
Source§impl Clone for SplitPaneSpec
impl Clone for SplitPaneSpec
Source§fn clone(&self) -> SplitPaneSpec
fn clone(&self) -> SplitPaneSpec
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 SplitPaneSpec
impl Debug for SplitPaneSpec
Source§impl PartialEq for SplitPaneSpec
impl PartialEq for SplitPaneSpec
impl StructuralPartialEq for SplitPaneSpec
Auto Trait Implementations§
impl Freeze for SplitPaneSpec
impl RefUnwindSafe for SplitPaneSpec
impl Send for SplitPaneSpec
impl Sync for SplitPaneSpec
impl Unpin for SplitPaneSpec
impl UnsafeUnpin for SplitPaneSpec
impl UnwindSafe for SplitPaneSpec
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§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 more