feat(render): logical style metrics with a UI scale, so chrome has a consistent physical size
This commit is contained in:
1 parent
1f03631e98
commit
7500fc90d2
21 files changed
+708
-82
No files matched your search
@@ -48,7 +48,10 @@ using FrameFn = std::function<void(plot::Plot&, f64 dt)>;
|
||||
/// `glfwGetWindowSize()` disagree. The host calls `begin_frame` with the
|
||||
/// framebuffer size and scales every pointer coordinate by the ratio
|
||||
/// `framebuffer / window`, so a gesture lands on the pixels the plot was laid out
|
||||
/// in. On an unscaled display the ratio is 1.0 and nothing changes.
|
||||
/// in. The same ratio states the display to the renderer
|
||||
/// (`Style::ui_scale`), which is what makes the chrome -- labels, strokes, paddings
|
||||
/// -- one physical size at any scale. On an unscaled display the ratio is 1.0 and
|
||||
/// nothing changes.
|
||||
///
|
||||
/// Headless smoke mode, read once per `run()`:
|
||||
///
|
||||
|
||||
Reference in new issue
Block a user