Struct conrod::widget::canvas::Style
[−]
[src]
pub struct Style {
pub color: Option<Color>,
pub border: Option<Scalar>,
pub border_color: Option<Color>,
pub length: Option<Length>,
pub pad_left: Option<Scalar>,
pub pad_right: Option<Scalar>,
pub pad_bottom: Option<Scalar>,
pub pad_top: Option<Scalar>,
pub title_bar_color: Option<Option<Color>>,
pub title_bar_text_color: Option<Color>,
pub title_bar_font_size: Option<FontSize>,
pub title_bar_maybe_wrap: Option<Option<Wrap>>,
pub title_bar_line_spacing: Option<Scalar>,
pub title_bar_text_align: Option<Align>,
}Unique styling for the Canvas.
Fields
color: Option<Color>
The color of the Canvas' rectangle surface.
border: Option<Scalar>
The width of the border surrounding the Canvas' rectangle.
border_color: Option<Color>
The color of the Canvas' border.
length: Option<Length>
If this Canvas is a split of some parent Canvas, this is the length of the split.
pad_left: Option<Scalar>
Padding for the left edge of the Canvas' kid area.
pad_right: Option<Scalar>
Padding for the right edge of the Canvas' kid area.
pad_bottom: Option<Scalar>
Padding for the bottom edge of the Canvas' kid area.
pad_top: Option<Scalar>
Padding for the top edge of the Canvas' kid area.
title_bar_color: Option<Option<Color>>
The color of the title bar. Defaults to the color of the Canvas.
title_bar_text_color: Option<Color>
The color of the title bar's text.
title_bar_font_size: Option<FontSize>
The font size for the title bar's text.
title_bar_maybe_wrap: Option<Option<Wrap>>
The way in which the title bar's text should wrap.
title_bar_line_spacing: Option<Scalar>
The distance between lines for multi-line title bar text.
title_bar_text_align: Option<Align>
The horizontal alignment of the title bar text.
Methods
impl Style[src]
impl Style[src]
pub fn color(&self, theme: &Theme) -> Color[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn border(&self, theme: &Theme) -> Scalar[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn border_color(&self, theme: &Theme) -> Color[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn length(&self, theme: &Theme) -> Length[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn pad_left(&self, theme: &Theme) -> Scalar[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn pad_right(&self, theme: &Theme) -> Scalar[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn pad_bottom(&self, theme: &Theme) -> Scalar[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn pad_top(&self, theme: &Theme) -> Scalar[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn title_bar_color(&self, theme: &Theme) -> Option<Color>[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn title_bar_text_color(&self, theme: &Theme) -> Color[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn title_bar_font_size(&self, theme: &Theme) -> FontSize[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn title_bar_maybe_wrap(&self, theme: &Theme) -> Option<Wrap>[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn title_bar_line_spacing(&self, theme: &Theme) -> Scalar[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
pub fn title_bar_text_align(&self, theme: &Theme) -> Align[src]
Retrieves the value from the Style.
If the Style's field is None, falls back to default specified within the Theme.
impl Style[src]
Trait Implementations
impl Copy for Style[src]
impl Clone for Style[src]
fn clone(&self) -> Style[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
Performs copy-assignment from source. Read more
impl Debug for Style[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result[src]
Formats the value using the given formatter. Read more