mirror of
https://github.com/emilk/egui.git
synced 2026-08-31 13:50:04 -04:00
Some visual tweaks
This commit is contained in:
@@ -3,6 +3,13 @@ This is the core library crate Emigui. It is fully platform independent without
|
||||
|
||||
## TODO:
|
||||
### Widgets
|
||||
* [x] Label
|
||||
* [x] Button
|
||||
* [x] Checkbox
|
||||
* [x] Radiobutton
|
||||
* [x] Slider
|
||||
* [x] Foldable region
|
||||
* [x] Tooltip
|
||||
* [x] Movable/resizable windows
|
||||
* [ ] Kinetic windows
|
||||
* [ ] Scroll areas
|
||||
@@ -13,15 +20,25 @@ This is the core library crate Emigui. It is fully platform independent without
|
||||
|
||||
### Animations
|
||||
Add extremely quick animations for some things, maybe 2-3 frames. For instance:
|
||||
* [ ] Animate foldables with clip_rect
|
||||
* [x] Animate foldables with clip_rect
|
||||
|
||||
### Clip rects
|
||||
* [x] Separate Region::clip_rect from Region::rect
|
||||
* [x] Use clip rectangles when painting
|
||||
* [ ] Use clip rectangles when interacting
|
||||
|
||||
When drawing children, they are drawn just on the edge of the clip rect.
|
||||
This means e.g. the leftmost side of a button or slider handle is clipped.
|
||||
We can fix this in three ways:
|
||||
|
||||
* A) Each component minds its bounds, so button offset their position by their outline width + one pixel for AA
|
||||
* B) Each region enlarges the clip_rect slightly to handle inner children
|
||||
* C) Each region shrinks its rect slightly so children move further in in child regions (creates unintentional indentation. ugh)
|
||||
|
||||
I think A) is the correct solution, but might be tedious to get right for every component. For instance, the outline may grow on mouse-over, but we don't want to move the component as a consequence.
|
||||
|
||||
### Other
|
||||
* [ ] Create Layout so we can greater grid layouts etc
|
||||
* [ ] Generalize Layout so we can create grid layouts etc
|
||||
* [ ] Persist UI state in external storage
|
||||
* [ ] Build in a profiler which tracks which region in which window takes up CPU.
|
||||
* [ ] Draw as flame graph
|
||||
|
||||
Reference in New Issue
Block a user