Emil Ernerfeldt
2058dcb881
Improve text sharpness ( #5838 )
...
This improves the sharpness of text slightly, thanks to
<https://hikogui.org/2022/10/24/the-trouble-with-anti-aliasing.html > by
@hikogui (🙏 ).
The difference is very small, but in dark mode (bright text on dark
background) text is sometimes significantly sharper, and also slightly
brighter.
The difference in light mode (dark text on light background) is much
smaller (barely perceptable).
To compare the before/after I suggest you open both in new tabs, then
quickly change between them.
### Low-DPI
#### Before

#### After

#### Before

#### After

### High-DPI
The difference is starkest on low-DPI screens (like the above
screenshots). On high-DPI screens, the difference is much smaller
#### Before

#### After

2025-03-21 12:56:47 +01:00
lucasmerlin
ad14bf2490
Add Harness::new_ui, Harness::fit_contents ( #5301 )
...
This adds a `Harness::new_ui`, which accepts a Ui closure and shows the
ui in a central panel. One big benefit is that this allows us to add a
fit_contents method that can run the ui closure with a sizing pass and
resize the "screen" based on the content size.
I also used this to add a snapshot test for the rendering_test at
different scales.
2024-11-01 18:30:40 +01:00