pub struct HeaderTitles {
pub title: Option<&'static str>,
pub subtitle: Option<&'static str>,
}Expand description
Title band drawn above a layout. The title slot renders
larger / brighter on the left of the band; the subtitle slot
renders smaller / dimmer on the right. Each slot is independently
optional - set either, both, or neither.
Use HeaderTitles::title / HeaderTitles::subtitle /
HeaderTitles::pair for the common cases; build the struct
directly only when you want to set a non-default combination
(e.g. via .. syntax over an existing instance).
Fields§
§title: Option<&'static str>§subtitle: Option<&'static str>Implementations§
Source§impl HeaderTitles
impl HeaderTitles
Sourcepub const fn none() -> HeaderTitles
pub const fn none() -> HeaderTitles
Both slots empty - no header band is drawn.
Sourcepub const fn title(s: &'static str) -> HeaderTitles
pub const fn title(s: &'static str) -> HeaderTitles
Title only; subtitle slot stays empty.
Sourcepub const fn subtitle(s: &'static str) -> HeaderTitles
pub const fn subtitle(s: &'static str) -> HeaderTitles
Subtitle only; title slot stays empty.
Sourcepub const fn pair(title: &'static str, subtitle: &'static str) -> HeaderTitles
pub const fn pair(title: &'static str, subtitle: &'static str) -> HeaderTitles
Both slots set.
Trait Implementations§
Source§impl Clone for HeaderTitles
impl Clone for HeaderTitles
Source§fn clone(&self) -> HeaderTitles
fn clone(&self) -> HeaderTitles
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 HeaderTitles
impl Debug for HeaderTitles
Source§impl Default for HeaderTitles
impl Default for HeaderTitles
Source§fn default() -> HeaderTitles
fn default() -> HeaderTitles
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for HeaderTitles
impl RefUnwindSafe for HeaderTitles
impl Send for HeaderTitles
impl Sync for HeaderTitles
impl Unpin for HeaderTitles
impl UnsafeUnpin for HeaderTitles
impl UnwindSafe for HeaderTitles
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