Emil Ernerfeldt
89937bf636
[egui_web] Auto-save app state to Local Storage every 30 seconds
2020-12-19 20:50:00 +01:00
Emil Ernerfeldt
01c65b0dcb
Replace Arc<Context> with struct CtxRef
2020-12-19 14:48:04 +01:00
Emil Ernerfeldt
b0e17638df
trait App now has fn name() for specifying egui_glium window title
2020-12-18 22:30:59 +01:00
Emil Ernerfeldt
6ff39d88bf
Demo App: Add ability to close the Backend window
2020-12-13 00:30:54 +01:00
Emil Ernerfeldt
48a8553661
Sprinkle demo app with emojis
2020-12-12 19:43:12 +01:00
Emil Ernerfeldt
2bb99213c8
Use extremely explicit names like available_rect_before_wrap
2020-12-10 23:25:23 +01:00
Emil Ernerfeldt
5fcc64dc85
Always start off painting two frames to allow things to settle
2020-12-08 22:38:20 +01:00
Emil Ernerfeldt
8de74e4250
[egui_web] respect the native zoom/scale of the browser
...
Remove all complexity with own scale slider.
Closes https://github.com/emilk/egui/issues/53
2020-11-28 10:46:31 +01:00
Emil Ernerfeldt
83444af862
Create mod util
2020-11-15 16:20:51 +01:00
Emil Ernerfeldt
496fdb52b4
[demo] add [DEBUG BUILD] warning text
2020-10-31 09:15:20 +01:00
Emil Ernerfeldt
7638ca9962
[app] Simplify interface to egui::app::App
2020-10-24 19:23:16 +02:00
Emil Ernerfeldt
44a7cac046
Context::begin_frame()
no longer returns anything.
...
Put your widgets into a `SidePanel`, `TopPanel`,
`Window` or into `ctx.background_ui()`.
2020-10-24 10:56:23 +02:00
Emil Ernerfeldt
8b51ae5dea
Panels: Added Context::panel_left and panel_top
...
Context will keep track of the avilable space left after panels.
Windows will be constrained to that available space.
So add panels first, THEN add windows.
2020-10-21 18:26:28 +02:00
Emil Ernerfeldt
6bbdf08482
[refactor] Split DemoWindows out of demos::DemoApp
2020-10-19 23:06:11 +02:00
Emil Ernerfeldt
a4e19d7207
[app] Add demo app slider to change scale of all of Egui
2020-10-17 23:54:46 +02:00
Emil Ernerfeldt
251cde60f0
[app] Refactor egui::app::App interface to be more data oriented
2020-10-17 16:13:20 +02:00
Emil Ernerfeldt
12afc356ee
Misc code cleanup: use more ui.checkbox, ui.label, ui.button etc
2020-10-10 13:04:40 +02:00
Emil Ernerfeldt
5c469551df
Switch argument order of ui.checkbox
and ui.radio
...
`bool, text` is the more logical order, as it
* matches the visuals: `[x] text`
* puts the important part first
* more natually allows us to extend to checkboxes without a text
2020-10-10 12:49:02 +02:00
Emil Ernerfeldt
7a71ac1a95
Rename tooltip_text to on_hover_text
2020-10-01 22:53:11 +02:00
Emil Ernerfeldt
5cba44eaa8
Clean up various small TODOs
2020-10-01 22:40:49 +02:00
Emil Ernerfeldt
6fcfb52aa0
[demo] add frame time graph to demo app
2020-10-01 22:25:44 +02:00
Emil Ernerfeldt
43bb670c0c
[layout] correct handling of cursor position w.r.t. reversed layouts
2020-09-26 10:06:06 +02:00
Emil Ernerfeldt
aad0391fef
remove Ui::set_layout
2020-09-26 07:52:24 +02:00
Emil Ernerfeldt
b77151fb64
remove seconds_from_midnight from core egui input
...
It is only used by demo app, and so does not belong to egui proper.
Instead it is now passed as part of a DemoEnvironment
2020-09-23 08:57:23 +02:00
Emil Ernerfeldt
5856cded95
refactor RunMode: move it from backend to the demo App ( #23 )
...
This simplifies the egui_glium and egui_web backends substantially,
reduces the scope of RunMode to a single file, and
removes duplicated code.
Basically: this is how I should have written it from the beginning.
2020-09-16 08:03:40 +02:00
Emil Ernerfeldt
f8bc4d38e8
[refactor] break up demo code into smaller files
2020-09-13 21:54:31 +02:00
Emil Ernerfeldt
6904938594
Compilation fix
2020-09-13 15:41:16 +02:00
Emil Ernerfeldt
1069ad8496
add color test window to troubleshoot your Egui painter backend
...
egui_glium passes the test, but the egui_web WebGL painter fails it.
2020-09-13 09:28:54 +02:00
Emil Ernerfeldt
bb367752cf
[text] support non-latin characters by dynamically adding them to atlas
2020-09-09 14:33:30 +02:00
Emil Ernerfeldt
bc0d6baefb
[color-picker] edit your own (s)RGBA arrays
...
Both with and without premultiplied alpha
2020-09-09 11:24:37 +02:00
Emil Ernerfeldt
d8e0b3bff6
[color] add HSV-based color picker for struct Srgba
2020-09-06 21:30:52 +02:00
Emil Ernerfeldt
9d4021d703
[refactor] rename LineStyle to Stroke
2020-09-01 23:54:21 +02:00
Emil Ernerfeldt
62b1a2658f
[tesselator] hide Path from view and improve thin rounded rectangles
2020-09-01 20:03:50 +02:00
Emil Ernerfeldt
96153a86e5
[refactor] Remove Option wrappers around colors and line styles
...
Just use transparency instead of None
2020-08-31 22:56:24 +02:00
Emil Ernerfeldt
413ed6999e
[refactor] break up Style into Spacing, Interaction and Visuals
...
Also make sliders fixed-width
2020-08-31 22:27:31 +02:00
Emil Ernerfeldt
fe50f39590
[demo] toggle_switch.rs source demo for how to create your own widget
2020-08-31 07:55:31 +02:00
Emil Ernerfeldt
c23dfd155c
[refactor] unify InteractInfo
and GuiResponse
to Response
2020-08-30 08:52:42 +02:00
Emil Ernerfeldt
1d350ad15b
[painter] add helper functions for drawing lines, circles and rectangles
2020-08-29 17:30:06 +02:00
Emil Ernerfeldt
c27e53a7b2
[color] Rename Color to Srgba + sRGBA correct fading of thin lines
...
Also remove the extra large `aa_size` hack,
so everything now looks slightly crispier.
I also took the opportunity to tweak some colors.
2020-08-29 16:58:59 +02:00
Emil Ernerfeldt
2465e689fb
[demo] additional window resize demo with embedded scroll
2020-08-29 15:32:17 +02:00
Emil Ernerfeldt
3d3b93da8b
Force user to explicitly select a max height for a ScrollArea
2020-08-29 15:14:44 +02:00
Emil Ernerfeldt
5df9bfd514
Add ui.drag_angle helper
2020-08-29 15:10:59 +02:00
Emil Ernerfeldt
d4c0197752
add ui.horizontal_centered helper
2020-08-29 15:10:59 +02:00
Emil Ernerfeldt
d07132cc13
[demo] bug fix: add back clock in upper right corner
2020-08-29 12:12:16 +02:00
Emil Ernerfeldt
d5a1385870
[demo] disable name clash demo, since it is not working anyway
2020-08-28 16:43:24 +02:00
Emil Ernerfeldt
b8938e01c4
[demo] add menu option to auto-reorganize windows
2020-08-28 16:24:20 +02:00
Emil Ernerfeldt
559b026b87
[demo] add windows that demonstrates auto-size, resize and scrolling
2020-08-28 16:24:20 +02:00
Emil Ernerfeldt
0bbf7edaee
[window] increase default width of windows and resize areas
2020-08-28 16:24:20 +02:00
Emil Ernerfeldt
03bc4ea2e2
[window] make scroll bars in windows opt-in
2020-08-28 16:24:20 +02:00
Emil Ernerfeldt
f3bbb210c0
[slider] click value to edit it with keyboard
2020-08-28 10:37:44 +02:00