Skip to main content

PanelStyleProvider

Trait PanelStyleProvider 

Source
pub trait PanelStyleProvider {
    // Required methods
    fn default_style(&self) -> Style;
    fn accent_style(&self) -> Style;
    fn border_style(&self) -> Style;
}
Expand description

Trait for providing panel styles. Decouples Panel from any specific session or theme type.

Implementors provide the three core styles needed to render a panel:

  • default_style: the base style for the panel background
  • accent_style: the style for active/focused borders
  • border_style: the style for inactive borders

Required Methods§

Source

fn default_style(&self) -> Style

Base style for the panel background.

Source

fn accent_style(&self) -> Style

Style for active/focused borders and titles.

Source

fn border_style(&self) -> Style

Style for inactive borders.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§