Commit Graph

299 Commits

Author SHA1 Message Date
Emil Ernerfeldt a7e7826d2c Release 0.4.0 of egui, egui_web and egui_glium 2020-11-28 13:47:00 +01:00
Emil Ernerfeldt 861573c497 Text editing: improve double-click to select word 2020-11-28 12:50:18 +01:00
Emil Ernerfeldt ab61f98a13 Bug fix: make sure child Ui:s have own Id 2020-11-28 12:50:18 +01:00
Emil Ernerfeldt 8163f912d3 Bug fix: stop using AHasher for Id:s
AHasher does not produce same hashes efter e.g. restarting an app
2020-11-28 12:50:18 +01:00
Emil Ernerfeldt 8e6c8ce50e Update ahash to 0.6 2020-11-28 11:05:55 +01:00
Emil Ernerfeldt aec97c74b9 [egui] Enable a bunch of clippy warnings 2020-11-28 10:58:08 +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 b1b34de4ee [style] Tweak clip_rect_margin to allow frames around ScrollArea:s 2020-11-27 15:46:16 +01:00
Emil Ernerfeldt 201586d512 REVERT: clip frame contents to frame border
can't do that quite as simply as I tried to :'(
2020-11-27 15:42:24 +01:00
Emil Ernerfeldt d8aeaa4b49 Clip frame contents to frame border 2020-11-27 15:33:14 +01:00
Patrik Höglund c7e199c8ac Fix the accessor for desired rows. 2020-11-26 13:52:06 +01:00
Emil Ernerfeldt aab1b351ab Fixed incorrect text wrapping width on radio buttons 2020-11-23 20:01:13 +01:00
Emil Ernerfeldt 56715a1dcd Improve ability to inspect why a widget is as wide as it is 2020-11-23 17:08:55 +01:00
Emil Ernerfeldt 633b19ee99 [egui_web] Repaint on finished fetch in example app 2020-11-20 20:35:16 +01:00
Emil Ernerfeldt 99a2a52510 Code cleanup 2020-11-20 20:32:38 +01:00
Emil Ernerfeldt 15b0214dff clippy fixes 2020-11-20 12:29:23 +01:00
Emil Ernerfeldt c6ce0b9e8c [example_web] show loading of an image
Required some redesign of `TextureAllocator` as well as
some improvements to the fetch API.
2020-11-18 22:16:01 +01:00
Emil Ernerfeldt 552104429d Remove accidentally commited test code 2020-11-18 19:02:29 +01:00
Emil Ernerfeldt fad0029119 egui_web: Add simple fetch API and demostrate it in example_web 2020-11-18 00:43:58 +01:00
Emil Ernerfeldt 7e9b5de250 Fix: id clash for TextEdit 2020-11-17 10:57:14 +01:00
Emil Ernerfeldt e7fd11f1aa Move focus between text fields with tab and shift-tab 2020-11-15 18:10:38 +01:00
Emil Ernerfeldt b17e6b3260 Implement undo for TextEdit 2020-11-15 17:36:15 +01:00
Emil Ernerfeldt 83444af862 Create `mod util` 2020-11-15 16:20:51 +01:00
Emil Ernerfeldt fe0d159324 Support Cmd+A ^W ^U ^K and shift-click 2020-11-15 14:21:21 +01:00
Emil Ernerfeldt b920822b6b fix: text selection when mouse goes out of the TextEdit area 2020-11-15 11:48:41 +01:00
Emil Ernerfeldt 13666755e1 Implement text selection 2020-11-15 04:44:55 +01:00
Emil Ernerfeldt 96befb0736 Galley: Return Rect when asking for cursor position 2020-11-14 23:07:16 +01:00
Emil Ernerfeldt 220f48a159 Remove unused cursor_blink_hz 2020-11-14 22:38:55 +01:00
Emil Ernerfeldt c4ed507d63 Add modifier keys and implement moving cursors one word at a time 2020-11-14 21:01:21 +01:00
Emil Ernerfeldt 7494026139 Fix some edge cases for the cursor movement 2020-11-14 18:21:06 +01:00
Emil Ernerfeldt c84431e473 Rename "row" to "line"
We now have "paragraphs" separated by \n,
which are word-wrapped onto one or more rows.
2020-11-14 18:21:06 +01:00
Emil Ernerfeldt 9ab00b8e50 Introduce meticulous cursors for text galleys 2020-11-14 18:21:06 +01:00
Emil Ernerfeldt e1077c98b7 Refactor, clarify and improve text layout 2020-11-14 18:21:06 +01:00
Emil Ernerfeldt 03eb9151c4 Improve automatic Id generation to make Id clashes less likely 2020-11-14 18:20:56 +01:00
Emil Ernerfeldt ee3f269d93 Fix numeric underflow when text editing 2020-11-13 12:51:52 +01:00
Emil Ernerfeldt 9057eaec7e Fix: you can again click slider values to edit them 2020-11-13 12:50:05 +01:00
Emil Ernerfeldt b3fa533ac5 Fix doctest 2020-11-13 11:31:01 +01:00
Emil Ernerfeldt 0340e2e6de TextEdit: You must explicitly choose singleline or multiline.
Multiline TextEdit now has a default height of 4 rows.
Added `ui.text_edit_singleline` and `ui.text_edit_multiline`.
2020-11-13 11:22:00 +01:00
Alexandre Rousseau 08bdbd3cb7
Rename menues to menus (#41)
Co-authored-by: Alexandre Rousseau <alexandre.rousseau@quebecormedia.com>
2020-11-10 22:56:35 +01:00
Emil Ernerfeldt d2b5730784 Check if TextEdit lost keyboard focus with response.lost_kb_focus 2020-11-09 18:42:54 +01:00
Emil Ernerfeldt c999ed038a Hexadecimal Debug format of Id 2020-11-09 18:41:19 +01:00
Emil Ernerfeldt e55b59256e Press enter in single line `TextEdit` to surrender keyboard focus 2020-11-09 18:40:23 +01:00
Emil Ernerfeldt 796def4bcb Fixed bug where a lost widget could still retain keyboard focus. 2020-11-09 13:19:22 +01:00
Emil Ernerfeldt 7cc5218630 [refactor] Move `used_ids` from `Context` to `Memory` 2020-11-09 13:04:05 +01:00
Emil Ernerfeldt b6dcae4651 Update versions to 0.3.0 2020-11-07 14:47:22 +01:00
Emil Ernerfeldt f46aa92eba Revert to aHash 0.4 again to allow Egui to be used inside of wasmtime 2020-11-07 14:35:42 +01:00
Emil Ernerfeldt 4b8a65268c Turn off anti-aliasing in debug builds by default 2020-11-07 14:06:14 +01:00
Emil Ernerfeldt af11d766fc Split out tesselation from Context::end_frame() 2020-11-07 11:44:32 +01:00
Emil Ernerfeldt 8393d1df47 Upgrade ahash from 0.4 to 0.5 2020-11-06 09:33:36 +01:00
Emil Ernerfeldt 94db5bb3a1 build fix 2020-11-03 22:14:21 +01:00