kud1ing
214d2b5d4f
Changlog: mention `menu::menu(ui, ...)` => `ui.menu_button(...)` ( #956 )
3 years ago
Jan Haller
5ec14867c8
OrderedFloat refactor ( #918 )
* Move egui/util/float_ord.rs -> epaint/util/ordered_float.rs
* Implement Hash on OrderedFloat
* Generic OrderedFloat<T>; impl Hash; documentation
3 years ago
Emil Ernerfeldt
c85eca6eaa
Update changelog
3 years ago
Jan Haller
1088d950e9
Add bar charts and box plots ( #863 )
Changes:
* New `BarChart` and `BoxPlot` diagrams
* New `FloatOrd` trait for total ordering of float types
* Refactoring of existing plot items
Co-authored-by: niladic <git@nil.choron.cc>
3 years ago
Alexander Chaplin Braz
224d4d6d26
eframe: don't prettify presisted ron strings ( #902 )
What ultimately ends up stored into a file is the
HashMap<String, String>, which when prettified only nets three
(depending on the settings) lines of "string": "long prettified
string that's really hard to read because of the extra indentation and
literal \n characters that are all just on one single line".
Not prettifying the values in the first place makes it somewhat easier
to read and also saves a bit of space.
3 years ago
Sven Niederberger
9d56bce592
Improved plot interaction methods ( #892 )
ctx plot_bounds plot_hovered screen_from_plot plot_from_screen etc
3 years ago
Henrique Penteado Kujawski Périgo
6b5c4b9aec
Disable glow scissor test after painting ( #905 )
3 years ago
Emil Ernerfeldt
5fee6b7bc5
Anti-alias path ends ( #893 )
Closes https://github.com/emilk/egui/issues/876
3 years ago
Emil Ernerfeldt
a0b635dc21
Add `Button::image_and_text` to changelog
following https://github.com/emilk/egui/pull/832
3 years ago
d10sfan
90757ca221
Add Button::image_and_text ( #832 )
* Support image button with text
* Add example (`cargo run --example native_texture`)
3 years ago
Emil Ernerfeldt
8896243146
Fix egui_web integration link in demo app
3 years ago
Emil Ernerfeldt
89700dfbbb
Improve egui_glow debug prints
3 years ago
Emil Ernerfeldt
105cb57050
Clean up glsl code
3 years ago
Emil Ernerfeldt
b5cb2b2c0d
Some code cleanup following https://github.com/emilk/egui/pull/888
3 years ago
triangle drawer
008a971e73
Fix wrong gamma in WebkitGTK ( #888 )
Closes https://github.com/emilk/egui/issues/794
Also refactor and improve VAO support detection
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
3 years ago
Emil Ernerfeldt
4d4c75c6f1
Fix vertical slider up/down keys and add a line in the changelog
Follow-up to https://github.com/emilk/egui/pull/875
3 years ago
Bruce Reif (Buswolley)
491739b580
implement vertical slider orientation ( #875 )
3 years ago
Sven Niederberger
0bad1d0c99
Plot interaction methods ( #766 )
* move to a basic plot builder with callback
* add some interaction methods
* move interaction demo to its own panel
3 years ago
Emil Ernerfeldt
6018c0e194
Area: automatically request a repaint when showing up for the first time ( #866 )
3 years ago
Emil Ernerfeldt
951ee4e142
Improve color picker cache ( #886 )
* colorpicker: try to maintain hue even when saturation goes to zero
* More consistent arguments to color types
* implement `Hash` for `Rgba`.
3 years ago
Emil Ernerfeldt
ddd5f6f4f6
winit: don't explicitly handle Cmd-Q and Alt-F4 ( #881 )
Closes https://github.com/emilk/egui/issues/877
Still a problem: https://github.com/rust-windowing/winit/issues/1998
3 years ago
Emil Ernerfeldt
19d24bbebe
Don't clip popups to the parent cliprect ( #885 )
Closes https://github.com/emilk/egui/issues/825
3 years ago
Emil Ernerfeldt
878eddd546
When using a custom font you can now specify a font index ( #873 )
When using a custom font you can now specify a font index
Closes https://github.com/emilk/egui/issues/853
3 years ago
sumibi-yakitori
10c8ffa543
Fix to limit X position of text agent to client width ( #870 )
3 years ago
Emil Ernerfeldt
83e490fb6a
Remove egui::math & egui::paint, replace with egui::emath & egui::epaint
3 years ago
Emil Ernerfeldt
0ab93576da
Remove references to the old begin_frame
3 years ago
Emil Ernerfeldt
6d33beabb1
Replace `scroll_delta` and `zoom_delta` in `RawInput` with events
Part of https://github.com/emilk/egui/issues/843
3 years ago
Emil Ernerfeldt
49e43885ff
Replace `Context::begin_frame/end_frame` with `fn run` taking a closure ( #872 )
* Replace Context begin_frame/end_frame with `fn run` taking a closure
* Create `egui::__run_test_ui` to replace `Ui::__test`
* Add helper `egui::__run_test_ctx` for doctests
3 years ago
Emil Ernerfeldt
e54106e950
Extend contributor list
3 years ago
Emil Ernerfeldt
c71090473b
glow-vs-web cleanup following https://github.com/emilk/egui/pull/868
3 years ago
triangle drawer
804722a1ba
Make egui_glow painter to work on web ( #868 )
Add WebGL1 and WebGL2 support to glow painter.
Add "glow" feature to egui_web to use the glow painter there.
Make winit an optional part of egui_glow
3 years ago
Emil Ernerfeldt
1dbe608e73
Refactor integrations ( #871 )
* Unify code in egui_glium and egui_glow into egui_winit::EpiIntegration
* Simplify `EguiGlium` interface
* Simplify `EguiGlow` interface
* egui_web refactor: merge `WebBackend` into `AppRunner`
3 years ago
sumibi-yakitori
b1716be745
egui_web: constrain the IME text agent to the canvas ( #830 )
limit the position of the text agent to the height of the client area
3 years ago
Emil Ernerfeldt
eda1d91654
Add culling of the painting for most widgets
This is a good early-out for widgets in `ScrollAreas`, but
also prepares for speeding up the first pass of a possible two-pass
version of egui: https://github.com/emilk/egui/issues/843
3 years ago
5225225
461f380a24
egui-winit: Fix shift key getting stuck with shift:both_capslock X11 option set ( #849 )
Listen for modifiers using ModifiersChanged
3 years ago
Emil Ernerfeldt
09b8269326
Rich text for all widgets ( #855 )
Introduce `RichText` and `WidgetText`
3 years ago
Emil Ernerfeldt
9378cd5c6e
ScrollArea: add methods to control horizontal scroll offset
Closes https://github.com/emilk/egui/issues/864
3 years ago
Linus Behrbohm
b9368aba13
Fix Response::context_menu return type ( #857 )
3 years ago
Emil Ernerfeldt
78dfde40b2
Remove deprecated functions
3 years ago
Emil Ernerfeldt
b551dfec81
fix broken docstring link
3 years ago
Emil Ernerfeldt
081485bcaf
Make it cheaper to clone `Memory` if there are a lot of persisted values
3 years ago
Emil Ernerfeldt
3819ec6fc7
Update "password" demo (storing widget state) after #836 refactor
https://github.com/emilk/egui/pull/836
3 years ago
Emil Ernerfeldt
c7638ca7f5
Add read/write of TextEdit cursor state ( #848 )
* Rename `CursorPair` to `CursorRange`
* Easymark editor: add keyboard shortcuts to toggle bold, italics etc
* Split up TextEdit into separate files
* Add TextEdit::show that returns a rich TextEditOutput object with response, galley and cursor
* Rename text_edit::State to TextEditState
3 years ago
Emil Ernerfeldt
ddd52f47c5
Add tessellation option to toggle rounding text to pixel coordinates
On by default and only there for testing
3 years ago
Emil Ernerfeldt
8e4fd942a9
Refactor memory data ( #836 )
This refactors the widget state storage introduced by @optozorax in https://github.com/emilk/egui/pull/257
* Unify the four buckets (`data`, `data_temp`, `id_data` and `id_data_temp`) into a single `data`.
* Less complexity, and also less chance of error (storing in one bucket, reading from another).
* Store data by `Id` and `TypeId`.
* Users can thus reuse the same `Id` to store many types.
* Uses a simple xor of id and typeid, which is fast and good since both id and typeid are already high-entropy hashes.
* Use different suffixes on the functions to pick if you want the data persisted or not (`get_temp`, `insert_persisted`, etc).
* Writing with one suffix and reading with the other works.
* To store state not bound to a specific `Id` (i.e. only based on type), use the new `Id::null` as the key.
3 years ago
Emil Ernerfeldt
bbe0f6089c
Context-menu: fix right-click edge-case
response.hovered() checks a larger rect which includes the item spacing,
and it always matches the hover effect.
3 years ago
Emil Ernerfeldt
41f77ba7d7
Clean up some of the new context menus
Follow-up to https://github.com/emilk/egui/pull/543
* Add entry to CHANGELOG.md
* Add entry to contributors in README.md
* Improve documentation
* Simplify demo
3 years ago
Linus Behrbohm
46fb9ff09b
Context menus ( #543 )
Main usage: `response.context_menu(…)` and `ui.menu_button`
3 years ago
Emil Ernerfeldt
b31ca7efc9
PR template: remind people to run `cargo fmt` and `cargo clippy`
3 years ago
Emil Ernerfeldt
445488755f
Point contributors to the new egui Discord
3 years ago