* Update the wgsl syntax used in egui-wgpu
* Updates for the latest version of wgpu
* Update the wgpu version
* get_preffered_format -> get_supported_formats
* Just use an array access for compatible formats
* Use the naga cli to validate the egui demo app custom wgpu shader
* Run cargo check on the custom3d wgpu app
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
* Don't call scroll if TextEdit is fully in view
* Explain why the new logic was added
* cargo fmt
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
* code hotkey to N, move superscript hotkey to Y
ctrl A S D F G H are all taken, CTRL Q is traditionally to remove formatting and should be reserved for that. CTRL W E R T are also all taken. CTRL Z X C V are taken so all of the first 4/5 keys of each row except Q are inaccessible.
* strike through conflict, update text
* fixed underline command
* added ALTSHIFT, browser documentation
* underline ALTSHIFT Q
it leaves the Q character which is considered a bug but before this pull underline was not working entirely so this is progress
* update text
* ALTSHIFT is treated as a command
* added eighth command, ALTSHIFT+W adds two spaces
* CTRL+Y to toggle case on text_edit demo
* better code
* Revised Menu
* fix dead link
* Update lib.rs
* Update easy_mark_editor.rs
* Update egui/src/data/input.rs
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
* update
* reverted variables used for debugging
* fixed labels hotkey conflict
* comments
* fmt
* cargo fmt
* Nice hotkey menu
Co-authored-by: Emil Ernerfeldt <emil.ernerfeldt@gmail.com>
* Use dark-light on Mac and Windows
dark-light has a nasty problem on Linux: https://github.com/frewsxcv/rust-dark-light/issues/17
So we made dark-light opt-in in https://github.com/emilk/egui/pull/1437
This PR makes dark-light a default dependency again,
but only use it on Max and Windows.
This is controlled with the new NativeOptions::follow_system_theme.
If this isn't enabled, then NativeOptions::default_theme is used.
* Add eframe::WebOptions
* Expose egui WGPU Textures and Limit Exposed API
This allows paint callbacks to access textures allocated by egui, and
also hides the functions on the `RenderPass` that users should not need
to call.
* Fix WGPU Rendering Bug When Using Paint Callbacks
Depending on the order custom paint callbacks were rendered, some of the
egui meshes would previously not be rendered at all in a seemingly random
fashion.
* Make egui_wgpu::Renderer Functions Public Again
This is a fix for the behaviour on macOS platforms where any egui app would use the dedicated GPU and consume more power than needed. Not all apps might have dedicated GPU requirements.
* Re-implement PaintCallbacks With Support for WGPU
This makes breaking changes to the PaintCallback system, but makes it
flexible enough to support both the WGPU and glow backends with custom
rendering.
Also adds a WGPU equivalent to the glow demo for custom painting.
* egui-winit: don't assume window available at init
On Android in particular we can only initialize render state once we
have a native window, after a 'Resumed' lifecycle event. It's still
practical to be able to initialize an egui_winit::State early on
so this adds setters for the max_texture_side and pixels_per_point
that can be called once we have a valid Window and have initialized
a graphics context.
On Wayland, where we need to access the Display for clipboard handling
we now get the Display from the event loop instead of a window.
* egui-wgpu: lazily initialize render + surface state
Enable the renderer and surface state initialization to be deferred
until we know that any winit window we created has a valid native window
and enable the surface state to be updated in case the native window
changes.
In particular these changes help with running on Android where winit
windows will only have a valid native window associated with them
between Resumed and Paused lifecycle events, and so surface creation
(and render state initialization) needs to wait until the first
Resumed event, and the surface needs to be dropped/recreated based on
Paused/Resumed events.