use super::style::{
CompactScrollbarStyle, ScrollbarStyle, SignalScrollbarStyle, StandardScrollbarStyle,
};
use super::theme::{DefaultScrollbarTheme, LightScrollbarTheme, ScrollbarTheme};
pub struct ScrollbarSettings {
pub theme: Box<dyn ScrollbarTheme>,
pub style: Box<dyn ScrollbarStyle>,
}
impl Default for ScrollbarSettings {
fn default() -> Self {
Self::standard()
}
}
impl ScrollbarSettings {
pub fn standard() -> Self {
Self {
theme: Box::<DefaultScrollbarTheme>::default(),
style: Box::new(StandardScrollbarStyle),
}
}
pub fn compact() -> Self {
Self {
theme: Box::<DefaultScrollbarTheme>::default(),
style: Box::new(CompactScrollbarStyle),
}
}
pub fn signal() -> Self {
Self {
theme: Box::<DefaultScrollbarTheme>::default(),
style: Box::new(SignalScrollbarStyle),
}
}
pub fn standard_light() -> Self {
Self {
theme: Box::<LightScrollbarTheme>::default(),
style: Box::new(StandardScrollbarStyle),
}
}
}