Olivier Goffart
643512f60a
C++: rename slint_intepreter.h to slint-interpreter.h
2023-07-27 15:42:11 +02:00
Olivier Goffart
a1bf77383f
C++: Add a mechanism to #define features that are enabled ( #3103 )
2023-07-18 11:49:00 +02:00
Simon Hausmann
a8c07d64c5
doc: Fix grammar of slint_interpreter::ComponentDefinition::properties() C++ docs
2023-07-17 15:52:42 +02:00
Aurindam Jana
5a4a7fee63
Update royalty free license to 1.1 ( #2994 )
2023-07-10 10:12:11 +02:00
Olivier Goffart
11dea135f7
Domain: slint-ui.com -> slint.dev
2023-06-16 10:55:08 +02:00
Aurindam Jana
039e54a5de
Add royalty free license to files except examples and docs ( #2888 )
2023-06-15 11:20:50 +02:00
Olivier Goffart
fd3f974d7e
Don't use old syntax in docs
2023-04-06 17:06:46 +02:00
Olivier Goffart
eaa9db4911
C++: use size_t everywhere as index in our models
...
cc #2024
2023-02-07 15:25:44 +01:00
Olivier Goffart
63cc68ea0c
C++: Use concepts for the invokables
2023-01-26 11:35:16 +01:00
Olivier Goffart
a3ec320bfb
Remove some deprecated stuff
...
CC #2024
2023-01-26 11:19:21 +01:00
Olivier Goffart
629a64ba89
C++ interpreter: do the renaming invoke_callback -> invoke
2023-01-02 23:55:47 +01:00
Florian Blasius
61c39b5fa1
Add support for dispatching key events through the public platform API
...
This change adds `KeyPress` and `KeyRelease` variants to the
`WindowEvent` enum, along with the new `slint::Key` enum, that allows
encoding keys.
2022-11-15 10:34:17 +01:00
Simon Hausmann
41e3e27bff
doc: Fix rendering of slint::interpreter::ComponentInstance::set_global_callback
...
Don't use a preview for the Slint snippet that just shows a global. There's
nothing to render.
2022-11-02 09:51:12 +01:00
Simon Hausmann
56983482b9
Rename C++'s internal AbstractRepeaterView to ModelChangeListener
...
For consistency with the Rust model implementation.
2022-09-27 10:26:55 +02:00
Tobias Hunger
1e6ffeaa0f
API cleanup: Rename PlatformWindow to WindowAdapter
2022-08-29 16:53:47 +02:00
Simon Hausmann
98e1befd0d
Port the C++ generator and C++ API to the new window ownership model
...
One key difference to the Rust way is what `slint::Window` means. In
Rust that holds the `WindowInner` and `slint::Window` is only exposed as
`&slint::Window`. This is possible because the component owns the
`Rc<dyn PlatformWindow>`, which has a function to return the
`&slint::Window`.
In C++ `slint::Window` is also exposed as `slint::Window&` in the
`window()` getter, but there's no way to get a reference to a C++
wrapper for the Rust `&slint::Window` that the `PlatformWindow` trait
returns. Therefore in C++ `slint::Window` wraps `Rc<dyn
PlatformWindow>`.
2022-08-19 15:07:27 +02:00
Simon Hausmann
af86f36157
Invert slint: 🪟 :WindowInner and PlatformWindow ownership
...
Previously: Window is an Rc<WindowInner>, which has an Rc<dyn
PLatformWindow> - and weak references the other way around.
Now: Rc<dyn PlatformWindow> is the root of window ownership. The impl
PlatformWindow has a slint::api::Window, which just holds a WindowInner.
This change is incomplete on a few levels, mainly that neither of the
code generators nor the interpreter is ported.
2022-08-19 15:07:27 +02:00
Olivier Goffart
ca6dfc0cb5
Run clang-format over C++ files
2022-08-17 07:44:22 +02:00
Olivier Goffart
48f818df62
C++ VBox: make the destructor delete the content in C++
2022-05-30 13:54:35 +02:00
Olivier Goffart
f5030cff06
Add a reset function to the model notifier
2022-04-14 14:06:34 +02:00
Olivier Goffart
15781411de
C++ interpreter: Cast the pointer, not the reference
...
May result in warnings otherwise
```
slint_interpreter.h:426:79: error: dereferencing type-punned pointer will break strict-aliasing rules [-Werror=strict-aliasing]
426 | &inner, &reinterpret_cast<slint::SharedVector<ValueOpaque> &>(array))) {
| ^~~~~
```
2022-03-09 13:11:05 +01:00
Olivier Goffart
350f0d0d6a
C++ interpreter API: add a Value::Value(int)
constructor ( #974 )
2022-02-21 14:00:51 +01:00
Olivier Goffart
3d209287c2
Docs: add a note that only exported global from the main file are exposed
2022-02-09 14:49:20 +01:00
Tobias Hunger
4230ac2572
Update copyright information to reflect name change
...
Also run resue over the codebase and fix complaints from that tool.
2022-02-09 10:27:47 +01:00
Simon Hausmann
f48d7d9f9e
SixtyFPS -> Slint in the C++ documentation
2022-02-02 15:19:13 +01:00
Simon Hausmann
b45433951a
Rename two more pre-processor variables
2022-02-02 13:39:11 +01:00
Simon Hausmann
fcf59f3793
Rename the C++ header files
2022-02-02 13:07:26 +01:00