Commit graph

2008 commits

Author SHA1 Message Date
Emil Ernerfeldt
83225f46ad Make Bézier demo more compact 2022-02-22 19:12:21 +01:00
Emil Ernerfeldt
31d324932c
Introduce egui::FullOutput, returned from Context::run (#1292)
* Introduce `egui::FullOutput`, returned from `Context::run`
* Rename `Output` to `PlatformOutput`
2022-02-22 17:13:53 +01:00
Emil Ernerfeldt
c5a9421dbd
Run wasm-bindgen in CI and update parking_lot (#1293)
* Run wasm-bindgen in CI
* Update parking_lot 0.11 -> 0.12
2022-02-22 16:30:42 +01:00
Emil Ernerfeldt
2e1a4cf08a impl std::fmt::Debug for TexturesDelta 2022-02-22 13:21:41 +01:00
Emil Ernerfeldt
745f209c61 Make RawInput.max_texture_side an Option 2022-02-22 13:21:28 +01:00
Emil Ernerfeldt
76f564428b Implement Serialize/Deserialize for TextShape 2022-02-22 13:20:46 +01:00
Emil Ernerfeldt
a90379ac8d Ignore characters that are wrong in emoji-icon-font.ttf
Closes https://github.com/emilk/egui/issues/1284
2022-02-22 09:47:31 +01:00
Emil Ernerfeldt
2af1dda4c3 Add TexturesDelta::clear 2022-02-21 21:51:21 +01:00
Emil Ernerfeldt
0a46634c13 Simplify backends by adding fn paint_and_update_textures helper 2022-02-21 21:49:52 +01:00
Emil Ernerfeldt
8f887e2ebd Add Shape::visual_bounding_rect() 2022-02-21 21:46:30 +01:00
Emil Ernerfeldt
fd3fb726c1 Fix bugs in consume_key and improve Modifiers API
Improvements and fixes following https://github.com/emilk/egui/pull/1212
2022-02-21 16:53:41 +01:00
Emil Ernerfeldt
476a3057b0 egui_demo_lib: make egui_extras an optional dependency 2022-02-21 16:10:16 +01:00
Emil Ernerfeldt
6d68838821 Clean up changelogs 2022-02-21 16:10:05 +01:00
Emil Ernerfeldt
ddf914b517
Update crates (#1283)
* Update rfd 0.8 -> 0.8

* Update webbrowser 0.5 -> 0.6

* Update unicode_names2 0.4 -> 0.5

* cargo update

    Updating crates.io index
      Adding arrayvec v0.7.2
    Updating async-lock v2.4.0 -> v2.5.0
    Updating autocfg v1.0.1 -> v1.1.0
    Updating cc v1.0.72 -> v1.0.73
    Updating cfg-expr v0.9.1 -> v0.10.1
    Updating core-foundation v0.9.2 -> v0.9.3
    Updating crc32fast v1.3.1 -> v1.3.2
    Updating crossbeam-epoch v0.9.6 -> v0.9.7
    Updating crossbeam-utils v0.8.6 -> v0.8.7
    Updating deflate v0.9.1 -> v1.0.0
    Removing encoding v0.2.33
    Removing encoding-index-japanese v1.20141219.5
    Removing encoding-index-korean v1.20141219.5
    Removing encoding-index-simpchinese v1.20141219.5
    Removing encoding-index-singlebyte v1.20141219.5
    Removing encoding-index-tradchinese v1.20141219.5
    Removing encoding_index_tests v0.1.4
    Updating enum-map v2.0.1 -> v2.0.2
    Updating futures-core v0.3.19 -> v0.3.21
    Updating futures-io v0.3.19 -> v0.3.21
    Updating futures-sink v0.3.19 -> v0.3.21
    Updating futures-task v0.3.19 -> v0.3.21
    Updating futures-util v0.3.19 -> v0.3.21
    Updating gio-sys v0.15.4 -> v0.15.6
    Updating glib-sys v0.15.4 -> v0.15.6
    Updating gobject-sys v0.15.1 -> v0.15.5
    Updating image v0.24.0 -> v0.24.1
    Updating kurbo v0.8.0 -> v0.8.3
    Updating libc v0.2.117 -> v0.2.119
    Updating memmap2 v0.5.2 -> v0.5.3
      Adding miniz_oxide v0.5.1
      Adding ndk-context v0.1.0
    Removing ndk-glue v0.5.0
    Removing ndk-glue v0.6.0
      Adding ndk-glue v0.5.1
      Adding ndk-glue v0.6.1
    Updating ntapi v0.3.6 -> v0.3.7
    Updating png v0.17.2 -> v0.17.3
    Updating proc-macro-crate v1.1.0 -> v1.1.2
    Updating rand v0.8.4 -> v0.8.5
    Removing rand_hc v0.3.1
    Updating rustls v0.20.2 -> v0.20.4
    Updating semver v1.0.4 -> v1.0.5
    Updating serde_json v1.0.78 -> v1.0.79
    Updating system-deps v6.0.1 -> v6.0.2
    Updating tracing v0.1.30 -> v0.1.31
    Updating tracing-subscriber v0.3.7 -> v0.3.9
    Updating tts v0.20.2 -> v0.20.3
    Removing windows v0.30.0
    Removing windows_aarch64_msvc v0.30.0
    Removing windows_i686_gnu v0.30.0
    Removing windows_i686_msvc v0.30.0
    Removing windows_x86_64_gnu v0.30.0
    Removing windows_x86_64_msvc v0.30.0
2022-02-21 15:40:25 +01:00
Emil Ernerfeldt
b8f427ddd6 Add a Code of Conduct, based on the Contributor Covenant
Taken verbatim (with an added mention of the egui Discord) from
https://www.contributor-covenant.org/version/2/1/code_of_conduct.html
2022-02-21 15:30:53 +01:00
Emil Ernerfeldt
b360dffdbf Demo app: handle the case of wrong selected anchor 2022-02-21 15:29:18 +01:00
Emil Ernerfeldt
c3fc8997d6
Introduce egui_extras with RetainedImage for loading svg,png,jpeg,… (#1282) 2022-02-21 15:26:26 +01:00
Emil Ernerfeldt
713917e481 refactor egui_web (break up lib.rs) 2022-02-21 09:28:12 +01:00
Emil Ernerfeldt
89d19860b8 Misc code cleanup, docs fixes, etc 2022-02-19 20:58:28 +01:00
Emil Ernerfeldt
e49245fae5 Improve the anti-aliasing of filled paths with sharp corners
This comes at the cost of these corners sometimes becoming badly
extruded instead. The sharper the corner, the bigger the problem.

A proper fix will have to wait for later.

Part of https://github.com/emilk/egui/issues/1226
2022-02-19 20:46:44 +01:00
Emil Ernerfeldt
b8fbbf7d62 Fix anti-aliasing of filled paths with counter-clockwise winding order
Part of https://github.com/emilk/egui/issues/1226
2022-02-19 20:46:44 +01:00
Emil Ernerfeldt
10634fc344 Improve the Bézier demo: drag control points and simplify code
Follow-up to https://github.com/emilk/egui/pull/1178
2022-02-19 20:46:44 +01:00
Emil Ernerfeldt
3a5ec4733f Fix bug when debug-painting clip rectangles 2022-02-19 20:46:40 +01:00
Emil Ernerfeldt
aa53522179
Slider event fixes (#1270)
* Slider: return drag_started,dragged,drag_released if value was dragged

Closes https://github.com/emilk/egui/issues/1269

* Fix: DragValue correctly reports gained_focus

* Make `Slider` report gained_focus,has_focus,lost_focus from DragValue

Closes https://github.com/emilk/egui/issues/1268
2022-02-19 19:56:12 +01:00
Emil Ernerfeldt
3ed68274b0 Make Slider report gained_focus,has_focus,lost_focus from DragValue
Closes https://github.com/emilk/egui/issues/1268
2022-02-19 11:12:09 +01:00
Emil Ernerfeldt
0d21405855 Fix: DragValue correctly reports gained_focus 2022-02-19 11:05:02 +01:00
Emil Ernerfeldt
989a6d202f Slider: return drag_started,dragged,drag_released if value was dragged
Closes https://github.com/emilk/egui/issues/1269
2022-02-19 10:58:07 +01:00
Benedikt Terhechte
8e62b382fd
Add some macOS emacs keybindings (#1243)
Move cursor left: ^B
    Move cursor right: ^F
    Beginning of line: ^A
    End of line: ^E
    Line up: ^P
    Line down: ^N
2022-02-19 10:42:43 +01:00
Tulio Leao
e746e3a58b
Light edits on README.md (#1246) 2022-02-19 10:41:31 +01:00
Urho Laukkarinen
6abdde0334
Add more source code links to demos (#1260) 2022-02-17 17:08:13 +01:00
Emil Ernerfeldt
3d754e3a16
Prevent ScrollArea:s from becoming tiny (#1255)
Closes https://github.com/emilk/egui/issues/1097
2022-02-17 17:08:05 +01:00
Emil Ernerfeldt
b5c8f034e7
Add web location info to egui_web/epi (#1258)
This adds all parts of the web "location" (URL) to frame.info().web_info, included a HashMap of the query parameters, percent-decoded and ready to go.

This lets you easily pass key-value pairs to your eframe web app.
2022-02-17 16:46:43 +01:00
Emil Ernerfeldt
4e316d32e5 Fix scroll_to with align
Broke in https://github.com/emilk/egui/pull/1252
2022-02-17 16:45:42 +01:00
Emil Ernerfeldt
4af3cae26d
Scroll so that text cursor remains visible (#1252)
Closes https://github.com/emilk/egui/issues/165
2022-02-16 21:34:47 +01:00
cat-state
c1569ed0d7
Add Ui.input_mut & InputState.ignore_key (#1212) 2022-02-15 17:14:24 +01:00
Friz64
c8c871fcd1
Add move_to_top and top_most_layer (#1242) 2022-02-15 17:13:08 +01:00
Sven Niederberger
8f8eb5d4a9
Customize Plot label and cursor texts (#1235)
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
2022-02-15 17:12:29 +01:00
BctfN0HUK7Yg
cfad28936d
Color picker now always pops up next to the button (#1237) 2022-02-15 16:55:43 +01:00
Juan Campa
635c65773d
Allow scroll into view without specifying an alignment (#1247)
* Allow scroll into view without specifying an alignment
* Handle case of UI being too big to fit in the scroll view
2022-02-15 16:52:29 +01:00
Emil Ernerfeldt
c1cd47e3a7 README: Add section to FAQ about how to work with async code 2022-02-13 23:04:08 +01:00
Emil Ernerfeldt
f92df7db56 README: Add screenshot to demonstrate the skin-ability of egui 2022-02-13 23:04:08 +01:00
Alexander
62504fface
Slider: Add step parameter (#1225)
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
2022-02-13 21:55:51 +01:00
Juan Campa
c4528beb72
Make non interactable layers not interact (#1240)
* Make non interactable layers not interact
* Make menus interactable
* Fix area interactable not being updated each frame
2022-02-13 21:09:25 +01:00
4JX
14e985a894
Expose FontTweak through egui::FontTweak (#1244) 2022-02-13 10:10:39 +01:00
Emil Ernerfeldt
69626296f1
Make v-align and scale of user fonts tweakable (#1241)
* Add ability to "tweak" the scale and y-offsets of individual fonts
* Change default font tweak

This help vertically center large text.
2022-02-12 18:22:42 +01:00
Emil Ernerfeldt
3f8ba3a542
Improve the contrast of the default light mode style (#1238)
Makes backgrounds brighter and foregrounds darker.
2022-02-11 13:58:50 +01:00
Emil Ernerfeldt
815598a842 .vscode/settings.json: insertFinalNewline and trimTrailingWhitespace
For when people make PR:s touching .toml, .md files
2022-02-10 19:34:07 +01:00
Yusuf Bera Ertan
1ebb5ccabf
Don't install console panic hook and tracing wasm subscriber in egui_web (#1230)
Do so in egui_demo_app instead
2022-02-10 15:44:41 +01:00
4JX
2f042ababd
Make Margin pub and move to style.rs (#1236) 2022-02-10 15:26:57 +01:00
Emil Ernerfeldt
b2323bd13e Add VSCode settings with {"editor.formatOnSave": true}
Hopefully this will increase the number of PR:s with correct formatting.
2022-02-09 18:14:55 +01:00