Comments (6)
How are you using egui and epaint? Via eframe
? What is your reproduce for this?
What the error message is trying to say is that the pixels_per_point
passed to tessellate
must match the pixels_per_point
of the Fonts
used during the frame.
from egui.
At the very least that error message should be fixed. It's extremely unhelpful.
We do not use eframe, it's a custom integration on top of a Vulkan renderer using winit
. The only workaround I found is to do this:
let mut raw_input = self.egui_winit.take_egui_input(window);
raw_input.viewports.iter_mut().for_each(|viewport| {
// Hack around bug with scale factor causing egui to crash in fonts lookup
viewport.1.native_pixels_per_point = Some(1.0);
});
let egui::FullOutput { platform_output, textures_delta, shapes, pixels_per_point: _, viewport_output: _ } =
self.egui_winit.egui_ctx().run(raw_input, run_ui);
That doesn't seem very nice.
from egui.
You should be using pixels_per_point
returned in FullOutput
: https://docs.rs/egui/latest/egui/struct.FullOutput.html#structfield.pixels_per_point
from egui.
@emilk That would give me >1x scaling which is not what I want.
from egui.
If you don't want egui scaling, then call ctx.set_zoom_factor(1.0);
and turn off the zoom_with_keyboard
option.
from egui.
Doesn't work. egui_winit forces the scale from the OS.
from egui.
Related Issues (20)
- Possible missing feature gate `winuser` for `winapi` needed by eframe HOT 2
- `set_clip_rect` draws over `SidePanel` when children widgets exceed the available space HOT 2
- FontBook demo doesn't scale HOT 4
- Add `Response::context_menu_with_id` API HOT 4
- Ui::dnd_drop_zone() swallows the inner Response HOT 2
- TextAgent assumes canvas is aligned to the top HOT 4
- [eframe native-windows] Entire program crashes when eframe viewport is resized from a corner HOT 12
- Items are not clickable when inside a row of a `TableBuilder` HOT 2
- Ctrl+X, C, V events get cut out HOT 4
- Remove `id_source` parameter for ui.indent HOT 1
- error: no such command: `cranky` HOT 2
- The program screen flickers (shakes) when resizing.
- Suggest enabling the Viewport to be built on a user-specified monitor at launch time
- Issue with number key mapping part #2
- Universal clipboard shortcuts (`Ctrl`+`C`/`V`/`X`) don't work with non-Latin keyboard layouts
- Display parent viewport id Issues
- rfd 0.14 conflicts with eframe on macOS HOT 6
- error: implementation of `Deserialize` is not general enough HOT 1
- ViewportCommand::Visible(false) doesn't appear to do anything
- Immediate viewport would crash with ViewportBuilder settings `fullscreen` + `transparent` + `always_on_top` HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from egui.