Implicitly register the component if not found. This makes the API easier to use. In another patch I called encode_item_node_id() in some other place before the component happened to be registered, and then it would return
None and each call site would then register the same pre-registration as in build_node_for_item_recursively.
In `winit`, it is not possible to instantiate a new window without access to the `winit` event loop, which Slint manages. With this change, there is now a `create_winit_window` call on Slint's winit` back end that will enable creating `winit` windows using existing functionality.
Of course, the utility of these windows is limited without access to `winit` event handling, but there are applications for which simply creating a window and instructing an external program to write into it (by passing the `HWND` on Windows or the `XId` on X11) is useful.
The previously used dark-light crate is going to switch to ashpd, so we
might as well use it directly. This is using an older version to match the
zbus version used with accesskit.
This could be extended in the future to use spawn_local and use the stream
provided by ashpd to listen to theme changes.
Fixes#4392
Based on API review, PlatformBuilder becomes BackendSelector with
a slightly smaller API surface but more options, such as selecting
Metal or Vulkan rendering.
Make it possible to programatically to switch to full-screen mode
via a new property in the Windows item.
The SLINT_FULLSCREEN environment variable will default set this
property to true. However settings this property in the slint code
will override the SLINT_FULLSCREEN.
Fixes#6665
- Rename `accessible-selectable` and `accessible-selected` to `accessible-item-{selectable,selected}`.
Because the property is for items in list rather than eg Text
- Rename `accessible-position-in-set` to `accessible-item-index`.
- Rename `accessible-size-of-set` to `accessible-item-count` and move
the property to the container element rather than the item itself
ChangeLog: Added function to set the XDG app id on Wayland/X11. This needs to be added with respective function names in the language sections.
Fixes#1332
Create the window adapter first without a window, and then resume. This deduplicates code and means that there's now only one single place where we resume/create the renderer and
accesskit adapters.
I am getting this warning:
```
[INFO]: 🎯 Checking for the Wasm target...
[INFO]: 🌀 Compiling to Wasm...
warning: missing documentation for a function
--> internal/backends/winit/lib.rs:83:1
|
83 | / pub fn create_gl_window_with_canvas_id(
84 | | canvas_id: &str,
85 | | ) -> Result<Rc<dyn WindowAdapter>, PlatformError> {
| |_________________________________________________^
|
note: the lint level is defined here
--> internal/backends/winit/lib.rs:6:9
|
6 | #![warn(missing_docs)]
| ^^^^^^^^^^^^
```
Fix this by adding a tiny bit of documentation