1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-30 13:20:05 -04:00

Implement window resizing

This commit is contained in:
Emil Ernerfeldt
2020-04-19 23:34:34 +02:00
parent 1be828bbe3
commit 388132ba93
8 changed files with 202 additions and 31 deletions

View File

@@ -2,7 +2,7 @@ use crate::{
color::Color,
fonts::TextStyle,
math::{Pos2, Rect, Vec2},
mesher::Mesh,
mesher::{Mesh, Path},
};
// ----------------------------------------------------------------------------
@@ -100,8 +100,7 @@ impl Outline {
}
}
#[derive(Clone, Debug, Serialize)]
#[serde(rename_all = "snake_case", tag = "kind")]
#[derive(Clone, Debug)]
pub enum PaintCmd {
Circle {
center: Pos2,
@@ -114,6 +113,12 @@ pub enum PaintCmd {
color: Color,
width: f32,
},
Path {
path: Path,
closed: bool,
fill_color: Option<Color>,
outline: Option<Outline>,
},
Rect {
corner_radius: f32,
fill_color: Option<Color>,