Prelude Displayable filltype

This commit is contained in:
hodasemi 2024-04-24 14:41:28 +02:00
parent be011c467e
commit 142ff7ae3a
2 changed files with 7 additions and 1 deletions

View file

@ -24,6 +24,12 @@ impl From<(Color, DisplayableFillType)> for FillTypeInfo {
} }
} }
impl From<Color> for FillTypeInfo {
fn from(color: Color) -> Self {
Self::Color(color, DisplayableFillType::Expand)
}
}
impl From<String> for FillTypeInfo { impl From<String> for FillTypeInfo {
fn from(s: String) -> Self { fn from(s: String) -> Self {
Self::Image(AssetPath::from(s)) Self::Image(AssetPath::from(s))

View file

@ -2,7 +2,7 @@
pub use super::gui::{ pub use super::gui::{
clickable::Clickable, clickable::Clickable,
colorable::Colorable, colorable::Colorable,
displayable::Displayable, displayable::{Displayable, DisplayableFillType},
executable::Executable, executable::Executable,
framable::*, framable::*,
hoverable::Hoverable, hoverable::Hoverable,