egui/crates/egui_glow
Alexander Nadeau 6c922f72a8
Fix text distortion on mobile devices/browsers with `glow` backend (#6893)
<!--
Please read the "Making a PR" section of
[`CONTRIBUTING.md`](https://github.com/emilk/egui/blob/master/CONTRIBUTING.md)
before opening a Pull Request!

* Keep your PR:s small and focused.
* The PR title is what ends up in the changelog, so make it descriptive!
* If applicable, add a screenshot or gif.
* If it is a non-trivial addition, consider adding a demo for it to
`egui_demo_lib`, or a new example.
* Do NOT open PR:s from your `master` branch, as that makes it hard for
maintainers to test and add commits to your PR.
* Remember to run `cargo fmt` and `cargo clippy`.
* Open the PR as a draft until you have self-reviewed it and run
`./scripts/check.sh`.
* When you have addressed a PR comment, mark it as resolved.

Please be patient! I will review your PR, but my time is limited!
-->

Did not test on platforms other than my phone, but I can't imagine it
causing problems. AFAIK if highp isn't supported then `precision highp
float;` needs to still not cause the program to fail to link/compile or
anything; it should just silently use some other precision.

* Fixes https://github.com/emilk/egui/issues/4268 for me but I only
tested it on a native Android app and I don't know whether backends
other than glow are affected.
* [x] I have followed the instructions in the PR template (but the
change is trivial so I'm just doing it from the master branch)

Before:

![image](https://github.com/user-attachments/assets/9f449749-5a48-4e9c-aef0-7a8ac3912eb6)

After:

![image](https://github.com/user-attachments/assets/544e5977-13e0-411a-bccf-b15a15289e28)
2025-04-30 14:12:08 +02:00
..
examples Enable more clippy lints (#6853) 2025-04-24 17:32:50 +02:00
src Fix text distortion on mobile devices/browsers with `glow` backend (#6893) 2025-04-30 14:12:08 +02:00
CHANGELOG.md Release 0.31.1 - text_edit and kittest fixes 2025-03-05 08:37:34 +01:00
Cargo.toml Revert "Revert "forward x11 and wayland features to glutin" (#5391)" (#5490) 2024-12-17 09:36:03 +01:00
README.md Fix typo in `crates/egui_glow/README.md` (#2956) 2024-01-07 16:31:34 +01:00

README.md

egui_glow

Latest version Documentation MIT Apache

This crates provides bindings between egui and glow which allows you to:

  • Render egui using glow on both native and web.
  • Write cross platform native egui apps (with the winit feature).

To write web apps using glow you can use eframe (which uses egui_glow for rendering).

To use on Linux, first run:

sudo apt-get install libxcb-render0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxkbcommon-dev libssl-dev

This crate optionally depends on egui-winit.

Test the example with:

cargo run -p egui_glow --example pure_glow --features=winit,egui/default_fonts