This doesn't require a windowing system, just Linux and Vulkan drivers
that supports the display extensions.
It's called linuxkms as soon this will go beyond Vulkan and also support
EGL and perhaps dumb buffers for software rendering.
```
warning: private item shadows public glob re-export
--> internal/interpreter/api.rs:9:37
|
9 | use i_slint_core::{Brush, PathData, SharedString, SharedVector};
| ^^^^^^^^^^^^
|
note: the name `SharedString` in the type namespace is supposed to be publicly re-exported here
--> internal/interpreter/api.rs:19:9
|
19 | pub use i_slint_core::api::*;
| ^^^^^^^^^^^^^^^^^^^^
note: but the private item here shadows it
--> internal/interpreter/api.rs:9:37
|
9 | use i_slint_core::{Brush, PathData, SharedString, SharedVector};
| ^^^^^^^^^^^^
= note: `#[warn(hidden_glob_reexports)]` on by default
```
This doesn't seem to be needed anymore with newer rust version.
As long as one symbol from the crate is used, all exported function
from the crate are available.
The reason why some symbols in some module were gone was a bug in rust
that has been fixed, it seems
* Configure clippy to not report about type complexity until *much*
later
* Configure clippy to only complain about more than 10 function
arguments
* Properly format safety sections
* Allow unnecessary main functions in doctests in the slint API crate
* AccessKit: Move big block of code before if condition
The alignment of a HashMap within a Struct is 8 bytes because of the
RandomState.
This is important because the C++ allocated `interpreter::Struct` could
be mis-aligned
The main change is that the window adapter is not copied into
sub-components anymore - instead it is accessed through the root. This
is especially important for globals.
In order to add the root, a little extra dance had to be performance on
instantiation: The self_rc/self_weak is created first and the
ComponentExtraData's fields are populated via once_cells.
Consume the Rc in the function signature where the implementation would clone it anyway.
This is also needed in preparation for InstanceRef::window_adapter()
walking up the tree of components,
by which it's not possible to return a reference anymore as
parent_instance() returns a new lifetime that's shorter than &self
inside window_adapter().
Replace all call sites that call unwrap() on window_adapter_ref() with a call
that returns a &Rc<dyn WindowAdapter> and use an Option variant for register/unregister component.
For the former, in the future, we want to create the adapter if it doesn't exist.
For the latter we don't want to do that.
Replace `fn window_ref(component) -> Option<& WindowInner)` with
`component.access_window(cb: impl FnOnce(&WindowInner))` as
all call sites unconditionally called unwrap() on them and by using the
pattern with a closure, we can in the future get the WindowInner from an
Rc<dyn Adapter> instead of an &Rc<dyn WindowAdapter>.
This will be needed for embedding - to avoid creating two window
adapters - and it will be needed for the API to allow creating a
component from an existing window.
This includes slint-viewer, slint-interpreter (when loading path, not
string), slint-compiler.
(This would also include internal things such as
`import { Xxx } from "foo.rs"`, if we didn't check for .slint or .60
extension before)
But that doesn't include anything that's not opening the source by path
(so not the lsp which use its own representation coming from the editor,
or varius tools like the updater and fmt which also open the files
themselves)