mirror of
https://github.com/emilk/egui.git
synced 2026-08-30 13:20:05 -04:00
Make it easier to create an Outline
This commit is contained in:
@@ -91,6 +91,15 @@ pub struct Outline {
|
||||
pub color: Color,
|
||||
}
|
||||
|
||||
impl Outline {
|
||||
pub fn new(width: impl Into<f32>, color: impl Into<Color>) -> Self {
|
||||
Self {
|
||||
width: width.into(),
|
||||
color: color.into(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Serialize)]
|
||||
#[serde(rename_all = "snake_case", tag = "kind")]
|
||||
pub enum PaintCmd {
|
||||
|
||||
Reference in New Issue
Block a user