Olivier Goffart
0b4bfd3a40
Qt style: Fix GroupBox not being clipped
...
Fixes #3541
2023-09-25 12:35:41 +02:00
Olivier Goffart
9466819421
Qt style: fix enabled state in some widgets
2023-09-25 10:48:51 +02:00
Olivier Goffart
d3ed4dfad0
Qt Widgets: set the preferred-size to the minimum-size
...
Instead of setting it to 0 which cause `widget.preferred-width` ti be 0
Fixes #3527
2023-09-22 14:31:46 +02:00
Olivier Goffart
86402483f8
qt style: Fix animation when the QStyle uses update() on the widget
...
Example Breeze do that.
Fixes #3482
2023-09-19 21:39:59 +02:00
Thorbjørn Lindeijer
7ee17d0914
Native style: Fixed scroll bar handle size for ScrollView ( #3489 )
...
This reverts commit 07f42afef3
, but applies
the same change specifically to the Slider, without affecting the
ScrollView.
The scaling up by factor 1024.0 of the min, max and value caused problems
for the ScrollView, which needs these values to match the viewport size
in order to correctly calculate the size of the scrollbar handle.
2023-09-19 10:07:25 +02:00
Guilhem Vallat
5cf1a45e41
Remove duplicated geometry properties from items
2023-09-13 16:08:37 +02:00
Olivier Goffart
06fc251729
Remove the geometry on ItemVTable
2023-09-13 16:08:37 +02:00
tronical
b8b9db4e42
Bump version number to 1.3.0
2023-09-05 15:46:36 +02:00
Simon Hausmann
dae978a0f9
Fix HighDPI rendering on Windows when using Qt as default backend
...
When not explicitly selected, we would construct the Backend struct as-is,
without calling `new()`. Therefore we would
miss the call to ensure_initialized() and
later set the Qt::AA_PluginApplication
application attribute, which screws up rendering.
2023-09-01 11:40:31 +02:00
Olivier Goffart
4920224be0
Rename Slider::vertical to Slider::orientation
2023-08-30 13:43:59 +02:00
Olivier Goffart
fde561a56a
Some improvements to Window visibility
...
- From C++, always call the Window::show() and hide() function instead
of going through set_visible directly as it doesn't set the size of
the WindowItem
- show() should also call resize on the renderer
- remove the is_visible in the WindowAdapterInternal as it is no longer
needed
2023-08-30 13:05:35 +02:00
Olivier Goffart
c33e5a0f12
Rust platform API: add ways to send CloseRequested and WindowActiveChanged events
2023-08-24 14:39:20 +02:00
Olivier Goffart
541e7137c6
Backends: don't resize the WindowItem in set_visible
...
We already query the size right after the call to set_visible in the
WindowInner::show()
2023-08-24 13:15:28 +02:00
Olivier Goffart
44a8147201
Rust platform API to query window properties
2023-08-22 18:32:50 +02:00
Olivier Goffart
c84a89c4ef
Native Style: Fix groupbox with the fusion style
2023-08-17 20:44:51 +02:00
Olivier Goffart
8884ce3565
Native Style: don't call initFrom on QStyleOption
...
This adds the enabled state which we don't need
2023-08-17 20:44:51 +02:00
Olivier Goffart
244e03a823
Native style: Fix animations
...
Commit bcbe157712
fixed animations in the
breeze style, but broke other style because it removed the call to
accept() the event
2023-08-17 20:44:51 +02:00
Simon Hausmann
96d7bb132c
reuse: remove glob for markdown files
...
Instead, place the copyright and license right into the source.
To satisfy reuse, this also removes the unnecessary MIT.txt
symlinks.
2023-08-17 08:55:28 +02:00
Tobias Hunger
09d3eaf00a
Update license symlinks
...
run `cargo xtask check_reuse_compliance --fix-symlinks`
2023-08-16 11:46:15 +02:00
Eric
4b9fb89332
add property for slider to support vertical orientation ( #3236 )
2023-08-16 09:58:50 +02:00
Olivier Goffart
bcbe157712
Native style: Fix animations with the KDE's breeze style
...
The style use update() on an invisible widget so animations wouldn't
work. As a workaround, capture the MetaCall event
2023-08-02 10:56:25 +02:00
Olivier Goffart
5718b15899
Qt platform: use QWindow::requestUpdate instead of QWidget::update
...
Otherwise we may repaint too fast
Fixes #3193
2023-08-02 10:56:25 +02:00
Olivier Goffart
ad389aa4eb
linuxkms: Implement keyboard input and clamp mouse
...
Unfortunately, this is currently not mapped to the right keyboard layout
Also keep the mouse clamped in the visible area.
And make it start in the middle of the screen.
2023-07-31 17:27:53 +02:00
Simon Hausmann
84ddfc6c2f
Add support for rendering the mouse cursor with linuxkms
...
The cursor is loaded by the window adapter from the cache. When it's
loaded the first time, its format will be Svg, so we convert it to a
pixel buffer. That way the skia backend can convert it on first draw
into a skia_safe::Image and replace the cache entry with the backend
storage variant.
2023-07-31 13:06:28 +02:00
Tobias Hunger
d47d52bf52
ItemVTable::init(...): Take an ItemRc so that the itan can know where in the Item Tree it is located
2023-07-27 12:04:16 +02:00
Simon Hausmann
af97435463
Replace show()/hide() in the WindowAdapter with set_visible(bool)
...
This makes for a smaller interface.
2023-07-26 13:53:45 +02:00
Simon Hausmann
7d136b6568
Remove the window parameter from the render() function of all the renderers
...
This makes for a slimmer API and instead we can create the renderer <-> window association
behind the scenes ourselves,
in set_component.
2023-07-25 17:28:08 +02:00
ogoffart
aebaa7d6c9
Bump version number to 1.2.0
2023-07-25 10:44:53 +00:00
Christian Boelsen
399e9c63d4
Allow Qt windows to run fullscreen with SLINT_FULLSCREEN
2023-07-24 14:52:33 +02:00
Eric
1b0d3b1061
Add edited callback for SpinBox ( #3096 )
...
* add edited callback for SpinBox
* fix compile error
* add inline comment for callback definition
2023-07-18 07:53:54 +02:00
Simon Hausmann
64f1504ab9
Fix rendering of QStyle animations
...
Allocate a widget per NativeXXX. This way QStyleAnimation objects
created by Qt aren't shared among style options.
Fixes #2045
Fixes #2987
2023-07-14 13:09:45 +02:00
Aurindam Jana
5a4a7fee63
Update royalty free license to 1.1 ( #2994 )
2023-07-10 10:12:11 +02:00
Olivier Goffart
9afadf50be
Get rid of the "use_modules" workaround
...
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
2023-07-05 13:41:06 +02:00
Guilhem Vallat
67493a4f3c
remove clippy::new-without-default warnings
2023-06-30 12:28:13 +02:00
Simon Hausmann
07f42afef3
Fix support normalized ranges for Slider with Qt style
...
The OpenGL Texture import example uses a Slider in the range 0..1. That doesn't work with
QStyleOptionSlider out of the box because it's
using integer values.
2023-06-28 17:42:34 +02:00
Tobias Hunger
e02c360000
Clippy polish
2023-06-28 14:22:30 +02:00
Tobias Hunger
8345c6cd79
Do automatic clippy fixes
2023-06-28 14:22:30 +02:00
ogoffart
c8c9496722
Bump version number to 1.1.1
2023-06-26 12:50:02 +00:00
Olivier Goffart
9b59036816
Add licenses symlinks
2023-06-26 13:12:29 +02:00
Olivier Goffart
1b9e245b4e
Remove the NativeSwitch
...
It is identical to the NativeCheckBox (Qt don't have a switch widget)
2023-06-23 11:02:46 +02:00
Olivier Goffart
d5fe68443f
Native ProgressIndicator: initialize the state properly
2023-06-22 14:23:56 +02:00
Tobias Hunger
50cc61c242
Fix reuse 3.1 spec compliance issues
2023-06-22 10:49:18 +02:00
Olivier Goffart
d5784811c7
Native style: Fix indeterminate ProgressIndicator
...
We need to pass a styleObject for the animation to work
The state will be shared accross all progressbar, but that's ok
2023-06-21 06:37:34 +02:00
Olivier Goffart
08e20c8586
Don't emit clicked when the pointer did not press the area
...
eg: releasing the pointer over a button that wasn't pressed shouldn't
click it
Fixes #2918
2023-06-20 16:06:12 +02:00
Florian Blasius
2656dfad7d
Refactor ProgressIndicator api according to api review. ( #2937 )
...
* Refactor ProgressIndicator api according to api review.
* Update docs/language/src/builtins/widgets.md
Co-authored-by: Simon Hausmann <simon.hausmann@slint-ui.com>
* Capping progress also for native.
---------
Co-authored-by: Simon Hausmann <simon.hausmann@slint-ui.com>
2023-06-20 12:27:48 +02:00
Olivier Goffart
11dea135f7
Domain: slint-ui.com -> slint.dev
2023-06-16 10:55:08 +02:00
Tobias Hunger
04d1229685
Fix licnese information using xtask
2023-06-16 09:14:20 +02:00
ogoffart
641cab0e75
Bump version number to 1.1.0
2023-06-15 16:01:28 +00:00
Olivier Goffart
033263127b
Qt Combobox: make it look proper when the style show the comobox in popup mode
...
As discusseed in https://github.com/slint-ui/slint/discussions/2893
Also initialize the current item the same way as fluent and material
2023-06-15 17:14:28 +02:00
Aurindam Jana
039e54a5de
Add royalty free license to files except examples and docs ( #2888 )
2023-06-15 11:20:50 +02:00