mirror of
https://github.com/slint-ui/slint.git
synced 2025-10-29 03:02:06 +00:00
Fix rem support
After commit e04f028c91, the
default-font-size property on WindowItem isn't set anymore by default,
so BuiltinFunction::GetWindowDefaultFontSize, which reads it, would
return zero.
Instead, delegate to a run-time function where we can fall back to the
default from the renderer.
This patch changes rem.slint to use the newer syntax. The main change to
the test case though is to removal of the explicit default-font-size
property setting, so that we fall back to the value provided by the
renderer. This test relies on being run with the testing backend.
Fixes #8961
This commit is contained in:
parent
007cfd26b9
commit
18740aa826
14 changed files with 57 additions and 23 deletions
|
|
@ -230,9 +230,9 @@ public:
|
|||
cbindgen_private::slint_register_bitmap_font(&inner, &font);
|
||||
}
|
||||
|
||||
inline float default_font_size() const
|
||||
inline float resolved_default_font_size() const
|
||||
{
|
||||
return cbindgen_private::slint_windowrc_default_font_size(&inner);
|
||||
return cbindgen_private::slint_windowrc_resolved_default_font_size(&inner);
|
||||
}
|
||||
|
||||
/// \private
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue