We had code on the window to reset the default-font-size property to the
default from the renderer.
For the Qt backend, the PopupWindow being their own Window, this code
was activated also for the PopupWindow's hidden default-font-size
property, which caused all PopupWindow's font to not follow the
default-font-size
Fixes#8855
- Use a version of FemtoVG that uses WGPU 25
- Rename the unstable-wgpu-24 feature and wgpu_24 module
- Fetch bevy from a revision on master branch that switches to WGPU 25
- Move the bevy example out of the common workspace: That way users of the repo don't get bevy pulled from git, unless they want to build the bevy example.
Keep the error message in one line.
Error such as
```
Error: Error creating OpenGL display (Ok(
DisplayHandle(
Wayland(
WaylandDisplayHandle {
display: 0x00005641c528e590,
},
),
),
)) with glutin: not found
```
Are not easy to parse because of all the new lines
Python is missing, otherwise this builds windows arm64 binaries for the
tools, C++ packages, slint-compiler, npm binaries, and lsp binaries for
the VS code extension.
Replace ios specific cfgs with "apple but not macOS", dubbed
ios_and_friends, so that we also cover iPadOS, etc.. What those have in
common is that they don't have user-resizable windows. (We might want to
add visionOs in the future)
Also, simplify a few macos or ios cfgs with just target_vendor =
"apple", for what applies to all the operating systems.
The `require_wgpu_24` function accepts either a fully setup WGPU, or one
can configure individual aspects such as features/limits.
The wgpu_texture example uses this to add push constants to the required
features and thus eliminates the need for uniform buffers.
This adds a `unstable-wgpu-24` feature that exposes WGPU types in the
GraphicsAPI enum, adds `require_wgpu_24()` to the backend selector,
and adds a conversion from `wgpu::Texture` to `slint::Image`.
The `require_wgpu_24()` function in the selector will be extended in the
future (before the next release) to permit specifying additional aspects
of the WGPU configuration.
Co-Authored-By: Olivier Goffart <olivier.goffart@slint.dev>
... by changing the resolution for the `WindowItem` to traverse the
item tree from the current item, instead of going to the window.
This doesn't quite fix#4298 because `rem` resolution is still missing.
That requires the built-in default font size function to be fixed as
well, which is non-trivial.
cc #4298
Commit cd6f2e2 reformated the .toml, but the 80 char width column is
judged too small to be practical
Add a .taplo.toml file
Also do not split feature array
... using taplo with default settings
I tried this with 4 spaces indentation, but the patch is almost as
big as this one, so I went with default settings instead as that
is just easier:-)
We've had some reports like #7641 . Now that we enable partial rendering by default, let's default to software rendering for Skia on Windows, until perhaps the Skia dawn backend arrives.
Closes#7641
Co-authored-by: Olivier Goffart <olivier.goffart@slint.dev>
See https://rust-lang.github.io/rust-clippy/master/index.html#useless_format
```
__CARGO_FIX_YOLO=1 cargo clippy --fix --all-targets --workspace --exclude gstreamer-player --exclude i-slint-backend-linuxkms --exclude uefi-demo --exclude ffmpeg -- -A clippy::all -W clippy::useless_format
cargo fmt --all
```
`__CARGO_FIX_YOLO=1` is a hack, but it does help a lot with the tedious fixes where the result is fairly clear.
`__CARGO_FIX_YOLO=1` is a hack, but it does help a lot with the tedious fixes where the result is fairly clear.
See https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
```
__CARGO_FIX_YOLO=1 cargo clippy --fix --all-targets --workspace --exclude gstreamer-player --exclude i-slint-backend-linuxkms --exclude uefi-demo --exclude ffmpeg -- -A clippy::all -W clippy::needless_lifetimes
cargo fmt --all
```
`__CARGO_FIX_YOLO=1` is a hack, but it does help a lot with the tedious fixes where the result is fairly clear.
See https://rust-lang.github.io/rust-clippy/master/index.html#/needless_borrow
```
__CARGO_FIX_YOLO=1 cargo clippy --fix --all-targets --workspace --exclude gstreamer-player --exclude i-slint-backend-linuxkms --exclude uefi-demo --exclude ffmpeg -- -A clippy::all -W clippy::needless_borrow
cargo fmt --all
```
Remove the geometry field and merely store the offset/transform. This brings the size down from 40 to 32 bytes on aarch64.
Related, filter_item() now respects the item's bounding rect for the decision whether to draw the item or not.
If CAMetalLayer decides to do double buffering for a long time, we'll keep increasing the age of the third buffer that we may have seen. We store that as u8, and this can overflow. Handle that case gracefully.
(This was introduced with commit d9404d4063)
If we want to enable partial rendering by default in the future, then we need to do this instead of disabling rendering notifiers. We don't know where the application renders to.
This regressed with commit 3cb4bd174d, which introduced the draw_rect() hook in ItemRenderer, but unfortunately
it wasn't in the `impl ItemRenderer` section
in the FemtoVG and Skia renderers.
ChangeLog: Fix panic when using gradient backgrounds with `Window`.
The use of the rotation-* properties creates a hidden Rotate item,
which applyes a rotation to the renderer. This rotation (and translation
by rotation origin) is now also applied when the partial renderer
computes the dirty regions.
This makes it possible to debug partial rendering with macOS easily.
Also, disable triple buffering when partial rendering is enabled,
as the partial renderer only supports two buffers.
This enables working around bugs in GPU drivers. Especially the GC7000UL
plus its driver on imx8mp has been observed to sometimes horribly degrade in
performance when Skia renders anti-aliased paths (when a function like
`gcoSURF_BlitCPU` shows up at the top of `perf` that's a bad sign).
If the effectively drop shadow size would be zero, the FemtoVG and Skia item renderers would panic. The following test-case reproduces this:
```slint
export component Test inherits Window {
Rectangle {
drop-shadow-color: black;
drop-shadow-offset-x: 1px;
drop-shadow-blur: -0.5px;
width: 0.5px;
height: 0.5px;
background: blue;
}
}
```
ChangeLog: [Renderers] Fix panic with FemtoVG and Skia renderers for certain drop shadows.
On macOS we should default to the Meta renderer, similar `renderer-skia` defaults to D3D on Windows. Unfortunately commit 0d36f88152 broke this by forgetting
that None with the requested graphics API means: Go for with what we have, nothing special requested.
This also fixes the terminal output "Failed to initialize Skia GPU renderer: Requested non-Metal rendering with Metal renderer . Falling back to software rendering" (and similar on Windows).