Commit graph

56 commits

Author SHA1 Message Date
Emil Ernerfeldt
63fa3aec10 Update example screenshots 2023-02-08 19:04:04 +01:00
Emil Ernerfeldt
449dd1c23c
cargo update (#2697)
* cargo update

    Updating anyhow v1.0.68 -> v1.0.69
    Updating bindgen v0.63.0 -> v0.64.0
    Removing cocoa v0.24.1
    Updating glutin v0.30.3 -> v0.30.4
    Updating glutin_egl_sys v0.3.1 -> v0.4.0
    Updating glutin_glx_sys v0.3.0 -> v0.4.0
    Updating glutin_wgl_sys v0.3.0 -> v0.4.0
    Updating proc-macro2 v1.0.50 -> v1.0.51
    Updating rgb v0.8.34 -> v0.8.35
    Updating serde_json v1.0.91 -> v1.0.92
    Updating tiny-skia v0.8.2 -> v0.8.3
    Updating tiny-skia-path v0.8.2 -> v0.8.3
    Removing windows-sys v0.36.1
    Removing windows_aarch64_msvc v0.36.1
    Removing windows_i686_gnu v0.36.1
    Removing windows_i686_msvc v0.36.1
    Removing windows_x86_64_gnu v0.36.1
    Removing windows_x86_64_msvc v0.36.1
    Updating zbus v3.8.0 -> v3.9.0
    Updating zbus_macros v3.8.0 -> v3.9.0

* Update wasm-bindgen to 0.2.84

* cargo update

    Updating js-sys v0.3.60 -> v0.3.61
    Updating wasm-bindgen-futures v0.4.33 -> v0.4.34
    Updating web-sys v0.3.60 -> v0.3.61

* Update pollster to 0.3

* Update rfd to 0.11

* Make sure we never depend on cmake
2023-02-08 18:11:34 +01:00
Emil Ernerfeldt
e4eaf99072
Remove native screen reader support (#2669)
* Remove native screen reader support

Use the "accesskit" feature flag to `eframe` instead.
[AccessKit](https://github.com/AccessKit/accesskit) is the future.

`tts` was a mess to compile on many platforms, so I no longer want
the native `tts` dependency.

* Update tts to 0.25

* Update changelogs

* Turn on all feature flags for package.metadata.docs.rs

* remove tts from deny.toml skip-tree

* Update web build scripts

* Update deny.toml
2023-02-04 11:47:36 +01:00
Emil Ernerfeldt
1353a5733f
Deprecate egui_glium - looking for new maintainer (#2668)
* Deprecate egui_glium - looking for new maintainer

egui_glium was the first backend of egui, and it served us well for
a long time, but we have long since moved on to glow and wgpu.

Not egui_glium is holding back an update to latest winit.

Since development on glium has long since been discontinued I will
therefore deprecate egui_glium with this PR.

The code is still there in the repository for a while longer,
but is no longer compiled.

If there is any interest in maintaining egui_glium, then fork it and
make a PR to remove the last egui_glium from this repository.
I will give you publish rights on crates.io.

* update glutin 0.30.2 -> 0.30.3

* cargo update -p backtrace

    Updating crates.io index
    Updating addr2line v0.17.0 -> v0.19.0
    Updating backtrace v0.3.66 -> v0.3.67
    Updating gimli v0.26.2 -> v0.27.1
    Removing miniz_oxide v0.5.4
    Updating object v0.29.0 -> v0.30.3

* cargo deny: allow duplicates of windows-sys, wayland-sys, and nix

* cargo-deny whitelist tiny-skia
2023-02-04 11:21:02 +01:00
Emil Ernerfeldt
d7fa40ebba
cargo update (#2386)
* Better cargo deny check in check.sh

* cargo update

    Updating ab_glyph v0.2.16 -> v0.2.18
    Updating ab_glyph_rasterizer v0.1.5 -> v0.1.7
    Removing adler32 v1.2.0
    Removing ahash v0.4.7
    Removing ahash v0.8.1
      Adding ahash v0.8.2
    Updating aho-corasick v0.7.18 -> v0.7.20
    Updating android_system_properties v0.1.4 -> v0.1.5
    Removing ansi_term v0.12.1
    Updating anyhow v1.0.62 -> v1.0.66
    Updating ash v0.37.0+1.3.209 -> v0.37.1+1.3.235
    Updating async-channel v1.7.1 -> v1.8.0
    Updating async-executor v1.4.1 -> v1.5.0
    Updating async-io v1.8.0 -> v1.12.0
    Updating async-lock v2.5.0 -> v2.6.0
    Updating async-recursion v0.3.2 -> v1.0.0
    Updating async-trait v0.1.57 -> v0.1.59
    Updating base64 v0.13.0 -> v0.13.1
    Updating bindgen v0.61.0 -> v0.63.0
      Adding block-buffer v0.10.3
    Updating bumpalo v3.11.0 -> v3.11.1
    Updating bytemuck v1.12.1 -> v1.12.3
    Updating bytemuck_derive v1.2.1 -> v1.3.0
    Updating bytes v1.2.1 -> v1.3.0
    Removing cache-padded v1.2.0
    Updating calloop v0.10.1 -> v0.10.3
    Updating cc v1.0.73 -> v1.0.77
    Updating cfg-expr v0.10.3 -> v0.11.0
    Updating chrono v0.4.22 -> v0.4.23
    Updating clang-sys v1.3.3 -> v1.4.0
    Updating clap v3.2.17 -> v3.2.23
    Updating cmake v0.1.48 -> v0.1.49
    Updating cocoa v0.24.0 -> v0.24.1
    Updating concurrent-queue v1.2.4 -> v2.0.0
      Adding cpufeatures v0.2.5
    Updating crossbeam-utils v0.8.11 -> v0.8.14
    Updating crossfont v0.5.0 -> v0.5.1
      Adding crypto-common v0.1.6
      Adding cxx v1.0.83
      Adding cxx-build v1.0.83
      Adding cxxbridge-flags v1.0.83
      Adding cxxbridge-macro v1.0.83
    Updating dark-light v0.2.2 -> v0.2.3
    Removing deflate v1.0.0
      Adding digest v0.10.6
    Updating dlv-list v0.2.3 -> v0.3.0
    Updating document-features v0.2.3 -> v0.2.6
    Updating flate2 v1.0.24 -> v1.0.25
    Updating fontconfig-parser v0.5.0 -> v0.5.1
    Updating fontdb v0.9.1 -> v0.9.3
    Updating form_urlencoded v1.0.1 -> v1.1.0
    Updating futures-core v0.3.23 -> v0.3.25
    Updating futures-io v0.3.23 -> v0.3.25
    Updating futures-sink v0.3.23 -> v0.3.25
    Updating futures-task v0.3.23 -> v0.3.25
    Updating futures-util v0.3.23 -> v0.3.25
      Adding generic-array v0.14.6
    Updating getrandom v0.2.7 -> v0.2.8
    Removing hashbrown v0.9.1
    Updating iana-time-zone v0.1.46 -> v0.1.53
      Adding iana-time-zone-haiku v0.1.1
    Updating idna v0.2.3 -> v0.3.0
    Updating image v0.24.3 -> v0.24.5
    Updating indexmap v1.9.1 -> v1.9.2
    Updating itertools v0.10.3 -> v0.10.5
    Updating itoa v1.0.3 -> v1.0.4
      Adding jni v0.20.0
    Updating jobserver v0.1.24 -> v0.1.25
      Adding jpeg-decoder v0.3.0
    Updating libc v0.2.132 -> v0.2.138
    Updating libloading v0.7.3 -> v0.7.4
    Updating libm v0.2.5 -> v0.2.6
      Adding link-cplusplus v1.0.7
      Adding litrs v0.2.3
    Updating lock_api v0.4.7 -> v0.4.9
    Updating memmap2 v0.5.7 -> v0.5.8
    Removing miniz_oxide v0.5.3
      Adding miniz_oxide v0.5.4
      Adding miniz_oxide v0.6.2
    Updating mio v0.8.4 -> v0.8.5
    Removing nix v0.22.3
    Removing nix v0.23.1
    Removing nix v0.24.2
      Adding nix v0.24.3
      Adding nix v0.25.1
      Adding nu-ansi-term v0.46.0
    Removing num_threads v0.1.6
    Updating once_cell v1.13.1 -> v1.16.0
    Updating ordered-multimap v0.3.1 -> v0.4.3
    Updating ordered-stream v0.0.1 -> v0.1.2
    Updating os_str_bytes v6.3.0 -> v6.4.1
      Adding overload v0.1.1
    Updating owned_ttf_parser v0.15.1 -> v0.17.1
    Updating parking_lot_core v0.9.3 -> v0.9.5
    Updating percent-encoding v2.1.0 -> v2.2.0
    Updating pkg-config v0.3.25 -> v0.3.26
    Updating png v0.17.5 -> v0.17.7
    Updating polling v2.2.0 -> v2.5.1
    Updating ppv-lite86 v0.2.16 -> v0.2.17
    Updating proc-macro2 v1.0.43 -> v1.0.47
    Updating profiling v1.0.6 -> v1.0.7
    Updating rand_core v0.6.3 -> v0.6.4
    Updating regex v1.6.0 -> v1.7.0
    Updating regex-syntax v0.6.27 -> v0.6.28
    Updating rgb v0.8.33 -> v0.8.34
      Adding roxmltree v0.15.1
    Updating rust-ini v0.17.0 -> v0.18.0
    Updating rustls v0.20.6 -> v0.20.7
    Updating scoped-tls v1.0.0 -> v1.0.1
      Adding scratch v1.0.2
    Updating sctk-adwaita v0.4.2 -> v0.4.3
    Updating serde v1.0.143 -> v1.0.149
    Updating serde_derive v1.0.143 -> v1.0.149
    Updating serde_json v1.0.83 -> v1.0.89
    Updating sha1 v0.6.1 -> v0.10.5
    Removing sha1_smol v1.0.0
    Updating smallvec v1.9.0 -> v1.10.0
    Updating socket2 v0.4.4 -> v0.4.7
    Updating svgtypes v0.8.1 -> v0.8.2
    Updating syn v1.0.99 -> v1.0.105
    Removing synstructure v0.12.6
    Updating system-deps v6.0.2 -> v6.0.3
    Updating textwrap v0.15.0 -> v0.16.0
    Updating thiserror v1.0.32 -> v1.0.37
    Updating thiserror-impl v1.0.32 -> v1.0.37
    Removing time v0.1.44
    Removing time v0.3.13
      Adding time v0.1.45
      Adding time v0.3.17
      Adding time-core v0.1.0
      Adding time-macros v0.2.6
    Updating tracing v0.1.36 -> v0.1.37
    Updating tracing-attributes v0.1.22 -> v0.1.23
    Updating tracing-core v0.1.29 -> v0.1.30
    Updating tracing-subscriber v0.3.15 -> v0.3.16
      Adding ttf-parser v0.17.1
      Adding typenum v1.15.0
    Updating unicode-ident v1.0.3 -> v1.0.5
    Updating unicode-normalization v0.1.21 -> v0.1.22
    Updating unicode-script v0.5.4 -> v0.5.5
    Updating unicode-width v0.1.9 -> v0.1.10
    Updating unicode-xid v0.2.3 -> v0.2.4
    Updating url v2.2.2 -> v2.3.1
    Updating version-compare v0.1.0 -> v0.1.1
    Updating wayland-client v0.29.4 -> v0.29.5
    Updating wayland-commons v0.29.4 -> v0.29.5
    Updating wayland-cursor v0.29.4 -> v0.29.5
    Updating wayland-egl v0.29.4 -> v0.29.5
    Updating wayland-protocols v0.29.4 -> v0.29.5
    Updating wayland-scanner v0.29.4 -> v0.29.5
    Updating wayland-sys v0.29.4 -> v0.29.5
    Updating webbrowser v0.8.0 -> v0.8.2
    Updating webpki-roots v0.22.4 -> v0.22.5
    Updating wgpu v0.14.0 -> v0.14.2
    Updating wgpu-core v0.14.0 -> v0.14.2
    Updating wgpu-hal v0.14.0 -> v0.14.1
    Updating wgpu-types v0.14.0 -> v0.14.1
    Updating which v4.2.5 -> v4.3.0
    Updating widestring v0.5.1 -> v1.0.2
      Adding windows-sys v0.42.0
    Updating winreg v0.8.0 -> v0.10.1
    Updating x11-dl v2.20.0 -> v2.20.1
    Updating xmlparser v0.13.3 -> v0.13.5
    Updating zbus v2.3.2 -> v3.6.0
    Updating zbus_macros v2.3.2 -> v3.6.0
    Updating zbus_names v2.2.0 -> v2.4.0
    Updating zerocopy-derive v0.3.1 -> v0.3.2
    Updating zstd-sys v2.0.1+zstd.1.5.2 -> v2.0.4+zstd.1.5.2
    Updating zvariant v3.6.0 -> v3.9.0
    Updating zvariant_derive v3.6.0 -> v3.9.0

* downgrade image, webbrowser and fontconfig-parser to pass cargo deny

avoiding duplicate crate

* Remove unused dependency on egui_extras from screenshot demo

* Downgrade `chrono` to avoid having to fix egui-extras now
2022-12-05 12:12:51 +01:00
Emil Ernerfeldt
48666e1d7a
Automatically generate screenshots for all examples (#2379) 2022-12-04 17:27:40 +01:00
Emil Ernerfeldt
2b1341095d
CI: Run cargo clippy for wasm32-unknown-unknown (#2200)
* CI: Run cargo clippy for wasm32-unknown-unknown

* wasm32 clippy fixes

* Document when AppRunner::new can fail
2022-10-30 20:55:07 +01:00
Andreas Reich
c2a37f4bd8
eframe support for wgpu on the web (#2107)
* basic working wgpu @ webgl on websys

* fix glow compile error

* introduced WebPainter trait, provide wgpu renderstate

* WebPainterWgpu destroy implemented

* make custom3d demo work on wgpu backend

* changelog entry for wgpu support eframe wasm

* remove temporary logging hack

* stop using pollster for web
we're actually not allowed to block - this only worked because wgpu on webgl doesn't actually cause anything blocking. However, when trying webgpu this became an issue

* revert cargo update

* compile error if neither glow nor wgpu features are enabled

* code cleanup

* Error handling

* Update changelog with link

* Make sure --all-features work

* Select best framebuffer format from the available ones

* update to wasm-bindgen 0.2.83

* Fix typo

* Clean up Cargo.toml

* Log about using the wgpu painter

* fixup wgpu labels

* fix custom3d_wgpu_shader ub padding

* remove duplicated uniforms struct in wgsl shader for custom3d

* Update docs: add async/await to the web 'start' function

Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
2022-10-05 20:14:18 +02:00
Koute
be9f363c53
egui_winit: support winit with default features disabled (#1971)
* egui_winit: support winit with default features disabled

* Link to the PR in the changelog
2022-08-30 08:49:32 +02:00
Emil Ernerfeldt
3142c52b94
Minor wgpu-web releated stuff (#1977)
* egui_demo_app: remove wgpu and pollster as direct dependencies

* eframe: use same web-sys version as wgpu crate

* Make note that web_sys_unstable_apis is required by the wgpu crate

* Rename the glow web painter in eframe

* Remove trait DummyWebGLConstructor from web_glow_painter.rs

* cargo fmt

* Fix check.sh
2022-08-28 10:58:58 +02:00
Emil Ernerfeldt
b978b06159
Simplify, clean up and speed up CI (#1970)
Use https://github.com/Swatinem/rust-cache
2022-08-27 09:54:47 +02:00
Emil Ernerfeldt
8737933101 Improve documentation and logging 2022-08-20 15:06:43 +02:00
Emil Ernerfeldt
041f2e64ba
Move all crates into a crates directory (#1940) 2022-08-20 10:41:49 +02:00
Emil Ernerfeldt
5d8ef5326b Change build_demo_web.sh option from --fast to --optimize 2022-08-02 09:56:38 +02:00
Emil Ernerfeldt
2500a60062 Code cleanup and improved docs 2022-07-30 18:40:49 +02:00
Emil Ernerfeldt
4e8a6e3370 misc code cleanup 2022-07-29 16:07:26 +02:00
Emil Ernerfeldt
a7012cf8a6
Use pinned version of wasm-bindgen-cli (#1855)
* Use pinned version of wasm-bindgen-cli

* Update wasm-bindgen to 0.2.82

* Call setup_web.sh from scripts that depends on it
2022-07-25 23:02:10 +02:00
Emil Ernerfeldt
bf15bb6e19
Use cargo cranky instead of cargo clippy (#1820)
* Use cargo cranky instead of cargo clippy

cargo cranky (https://github.com/ericseppanen/cargo-cranky)
is a new tool that passes lints specified in a Cranky.toml
to cargo clippy.

This is a possible solution to
https://github.com/rust-lang/cargo/issues/5034

* Remove `-W clippy::all` from `check.sh` (rely on `Cranky.toml` instead)
2022-07-20 12:34:19 +02:00
Emil Ernerfeldt
083e20474b
deny warnings on CI and check.sh with -D warnings (#1710) 2022-06-02 21:06:12 +02:00
Emil Ernerfeldt
f3e305a646 Replace TODO: with TODO(emilk): and update code guidelines 2022-05-21 16:53:25 +02:00
Emil Ernerfeldt
931e716b97
Add egui_wgpu crate (#1564)
Based on https://github.com/hasenbanck/egui_wgpu_backend

`egui-wgpu` is now an official backend for `eframe` (opt-in).

Use the `wgpu` feature flag on `eframe` and the `NativeOptions::renderer` settings to pick it.

Co-authored-by: Nils Hasenbanck <nils@hasenbanck.de>
Co-authored-by: Sven Niederberger <niederberger@embotech.com>
Co-authored-by: Sven Niederberger <73159570+s-nie@users.noreply.github.com>
2022-05-12 09:02:28 +02:00
Emil Ernerfeldt
e82b87ca73
Remove calls to gl.getError in release builds (#1583)
This slows down the web version a lot, especially on some browsers

Publish new web demo
2022-05-05 23:17:33 +02:00
Emil Ernerfeldt
e5ccfedd61 Escape some strings in build_demo_web.sh 2022-04-30 17:18:31 +02:00
Emil Ernerfeldt
9b9c5005d3 CI and check.sh: run cargo doc for all crates 2022-04-30 15:51:46 +02:00
Emil Ernerfeldt
bb421c7e8a
Remove egui_web and epi (#1545)
* Remove integration name (it is always eframe)

* Remove egui_web crate

* Move egui_web/CHANGELOG.md into eframe/CHANGELOG.md

* Remove all mentions of egui_web

* Remove epi crate and absorb into eframe

* egui_glow: only use puffin on native

* Remove WASM doc from CI (we don't generate it anyways!)

* Remove eframe::epi and improve eframe docs
2022-04-30 10:44:35 +02:00
Emil Ernerfeldt
ed002acc68
Refactor: move things into eframe (#1542)
* Move all epi-related code from egui_glow into eframe

* Move epi stuff from egui-winit into eframe

* Remove mention of epi in egui

* Remove mention of epi in egui_glium

* Remove trait epi::NativeTexture

* Remove confusing mentions of epi

* Refactor egui_web: break up into smaller files

* Clean up feature flags further, and update changelogs

* Clean up check.sh

* Small cleanup of egui_web/Cargo.toml

* Fix dependencies for pure_glow example

* Fix clippy false positive
2022-04-29 08:17:49 +02:00
Emil Ernerfeldt
917f9e1768 Refactor and simplify feature flags 2022-04-11 10:53:16 +02:00
Emil Ernerfeldt
8cf196a34b Use proper shebang for all bash scripts: #!/usr/bin/env bash 2022-04-07 17:34:34 +02:00
Emil Ernerfeldt
7cd285ecbc misc clippy fixes from 1.60.0 2022-04-07 17:03:19 +02:00
Emil Ernerfeldt
bd25526a4f check.sh: fail on rustdoc failure
Same as https://github.com/emilk/egui/pull/1454
2022-04-05 08:07:57 +02:00
Emil Ernerfeldt
15254f8235
Remove the single_threaded/multi_threaded feature flags (#1390)
Always use parking_lot for mutexes, i.e. always be multi-threaded.

Closes #1379
2022-03-21 22:20:37 +01:00
Emil Ernerfeldt
50539bd31a
egui_web: always use the glow painter, and remove the old WebGL code. (#1356)
* egui_web: always use the glow painter, and remove the old WebGL code.
* Clean up the WebPainter trait
* Clarify WebGL1 warning text in color test

The glow painter became standard in egui 0.17, and I've heard no complaints! So let's simplify and go all in on glow.

Part of https://github.com/emilk/egui/issues/1198
2022-03-11 19:15:06 +01:00
Emil Ernerfeldt
52b4ab4e18
Remove egui_glium as a backend for eframe (#1357)
eframe will now always use egui_glow as a native backend.

Part of https://github.com/emilk/egui/issues/1198
2022-03-11 19:14:27 +01:00
Emil Ernerfeldt
d8300037ad
Fix cargo run -p egui_demo_app (#1343)
Broken by https://github.com/emilk/egui/pull/1303
2022-03-08 08:26:43 +01:00
Emil Ernerfeldt
a05520b9d3 Release 0.17.0 - Improved font selection and image handling 2022-02-22 19:32:30 +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
c3fc8997d6
Introduce egui_extras with RetainedImage for loading svg,png,jpeg,… (#1282) 2022-02-21 15:26:26 +01:00
Emil Ernerfeldt
89d19860b8 Misc code cleanup, docs fixes, etc 2022-02-19 20:58:28 +01:00
Emil Ernerfeldt
712d8c9a2b
Run cargo deny in CI (#1205)
* Run cargo deny in CI
* Use patched fork of ureq to avoid copy-left license
* Use patched fork of tts to avoid LGPL license

More:
* https://github.com/ndarilek/tts-rs/pull/21
* https://github.com/algesten/ureq/pull/479
2022-02-04 22:08:15 +01:00
Emil Ernerfeldt
b5aaa5fa6f Improve some feature flags 2022-01-31 19:24:56 +01:00
Emil Ernerfeldt
199bbef77b Add misc documentation 2022-01-22 09:07:41 +01:00
Emil Ernerfeldt
9df0c68a38 Small improvements to check.sh 2022-01-17 19:57:32 +01:00
Emil Ernerfeldt
b1fd6a44e8
Switch to using glow as the default renderer both on native and the web (#1020)
* Switch to using glow as the default renderer both on native and the web
* Simplify code to find WebGL context for glow
* egui_web: make webgl an opt-in feature
* Stop using deprecated WEBGL_debug_renderer_info
2021-12-31 15:17:55 +01:00
Emil Ernerfeldt
0146c7e7fc Release 0.16.0 - Context menus and rich text 2021-12-29 12:07:05 +01:00
Emil Ernerfeldt
d0a47bf8e8 setup_web.sh: don't force-install wasm-bindgen-cli 2021-12-28 21:30:36 +01:00
Emil Ernerfeldt
da09a5c69c Fix compilation with "serialize" feature without "persistence" feature 2021-10-23 15:12:39 +02:00
Emil Ernerfeldt
39c6c7e5c9 Small code cleanup 2021-10-23 06:03:45 +02:00
Emil Ernerfeldt
2a9037cd90 Clean up epaint mutex code 2021-10-20 22:24:34 +02:00
Emil Ernerfeldt
8178d23d19
Deduplicate code found in both egui_glium and egui_glow (#819)
* Move window building to egui-winit

* Move icon loading to egui-winit

* `use glow::HasContext;` -> `use glow::HasContext as _;`

* Move FileStorage into epi behind a feature flag

* De-duplicate screen_size_in_pixels and native_pixels_per_point

* Move creation of FileStorage to epi

* Handle epi app output (window size changes etc) in egui-winit

* Move app and memory persistence and autosave logic to egui-winit

* fix check.sh

* Make the epi backend opt-in for egui_glium and egui_glow

* Fix persistence

* Add integration name to epi::IntegrationInfo and the demo

* Clean up Cargo.toml files and fix making egui_glium optional

* fix typo

* Make egui_glium compile without the `epi` feature
2021-10-19 21:40:55 +02:00
Emil Ernerfeldt
cdd4dccf5f
Add egui_glow as an opt-in backend to eframe (#817)
* Make egui_glow and opt-in backend for eframe

* Add egui_glow to Cargo.toml and to CI

* Reference egui_glow where egui_glium is mentioned

* Remove path-patches from root Cargo.toml

* Add instructions on how to enable the glow backend of eframe
2021-10-19 15:32:23 +02:00