1
0
mirror of https://github.com/emilk/egui.git synced 2026-08-31 05:40:03 -04:00

Add time as input to emigui to enable animations

This commit is contained in:
Emil Ernerfeldt
2020-04-21 14:46:42 +02:00
parent 11cd1bdca3
commit 0ed578341b
4 changed files with 18 additions and 0 deletions

View File

@@ -26,6 +26,10 @@ pub struct Style {
/// For stuff like check marks in check boxes.
pub line_width: f32,
// TODO: add ability to disable animations!
/// How many seconds a typical animation should last
pub animation_time: f32,
pub window: Window,
}
@@ -44,6 +48,7 @@ impl Default for Style {
clickable_diameter: 34.0,
start_icon_width: 20.0,
line_width: 1.0,
animation_time: 1.0 / 20.0,
window: Window::default(),
}
}