Olivier Goffart
6bf224c9de
Bump version of strum
2021-11-18 11:16:24 +01:00
Olivier Goffart
2681c24813
Disable caching of Qt 6 on Windows again
...
Somehow the cache is empty otherwise
2021-11-18 10:23:06 +01:00
Simon Hausmann
234b95554f
Prospective fix for unnecessary cargo build when running cpack
...
Run the `package` target with `--config Release` just like the previous
build.
2021-11-18 10:23:06 +01:00
Olivier Goffart
7c34e7f27f
C++ packages: Move the Qt plugins in the right directory
2021-11-18 10:23:06 +01:00
Olivier Goffart
1bde79e884
Fix native widgets with C++ on windows
...
The function that expose the vtable was not exported because the declare_item_vtable
expanded to a `#[cfg(feature = "ffi")]` with the intention to be the ffi feature
of the corelib crate. But when this macro is used from the qt backend, the ffi
feature was not set
2021-11-18 10:23:06 +01:00
Olivier Goffart
cd14e1d70c
Move the NativeButtonVTable in the right module
2021-11-18 10:23:06 +01:00
Olivier Goffart
6cfb18b5d7
Fix warnings in the tests in release
...
The maybe-uninitialized warning triggers while we know from what
we are testing that it is meant to be initialized
2021-11-18 10:23:06 +01:00
Olivier Goffart
c5de0e6260
Update .github/workflows/ci.yaml
...
Co-authored-by: Simon Hausmann <simon.hausmann@sixtyfps.io>
2021-11-18 10:23:06 +01:00
Olivier Goffart
8757193253
Update to Qt6 for the C++ packages
...
(excepted on Linux)
2021-11-18 10:23:06 +01:00
Olivier Goffart
304ca3b62f
C++ package: Bundle the Qt binary in the binary package
2021-11-18 10:23:06 +01:00
Olivier Goffart
24ed7155b7
CI: build C++ packages in release mode
2021-11-18 10:23:06 +01:00
Olivier Goffart
44118556c3
cpack: Only generate one package (the tar.gz one)
2021-11-18 10:23:06 +01:00
unc0
54ae34f9fb
Set MSVC to use UTF-8 character sets on c++ source files,
...
so it won't throw error on `u"string"` when running in
other codepage, for example cp936.
Ref: https://docs.microsoft.com/en-us/cpp/build/reference/utf-8-set-source-and-executable-character-sets-to-utf-8
2021-11-17 19:35:12 +01:00
Olivier Goffart
73e753f091
sixtyfps-interpreter test: use the fluent style
...
because the native style can't run in tests because it cannot draw from
different threads
2021-11-17 14:09:55 +01:00
Olivier Goffart
2bf3e00a35
Make sure sixtyfps-interpreter tests are run with the testing backend
...
Because the Qt backend don't support being run in threads and the tests are
in threads and in parallel
2021-11-17 09:55:18 +01:00
Olivier Goffart
becb4574c1
Qt backend: don't set Qt::AA_PluginApplication when using the backend
...
Otherwise Qt won't set the hidpi mode on windows, for example
2021-11-17 09:05:24 +01:00
Olivier Goffart
40a6f3e740
Polish the Native Spinbox: There is a line edit that need to be drawn inside
2021-11-17 08:44:08 +01:00
Olivier Goffart
238ae33fe6
Remove a presumably useless file
...
We have no memory of why this file is needed. Let's remove it
2021-11-16 18:01:28 +01:00
Olivier Goffart
7bf3fd2871
Fix invalid CMake package on windows because of missing IMPORTED_IMPLIB
2021-11-16 17:06:27 +01:00
Olivier Goffart
8a3b064b58
cmake: have the style as a cmake cache variable
2021-11-16 17:06:15 +01:00
Olivier Goffart
c3baef1f64
Compiler: Add a --style
option
...
So we will be able to set the style from the command line args in addition
to the env variable
2021-11-16 17:06:15 +01:00
Olivier Goffart
83fac67632
Binary package: use Qt 6 on windows and add the svg image plugin
2021-11-16 12:23:46 +01:00
Olivier Goffart
7a5fc72093
Fix black background with native style
...
If we don't tell the compiler that the properties are `native_output` then
it might const-propagate the default value which is transparent
2021-11-16 11:27:21 +01:00
Olivier Goffart
aa24922a1a
Mention the VIM 3rd party plugins in the LSP readme
...
cc #429
2021-11-16 09:20:29 +01:00
Olivier Goffart
a6425300fb
Fix documentation warning
...
In wasm, the documentation eed to be repeated
2021-11-15 17:03:47 +01:00
Simon Hausmann
b29b2cfaea
Make WinitWindow::apply_window_properties work outside the GL backend crate
...
Move the image loading related bit for the icon back into glwindow.
Amends commit
51469be56b
.
2021-11-12 11:44:39 +01:00
Simon Hausmann
e3ee59fd13
Fix transitioning from fixed size to resizable window with the GL backend
...
PR #642 fixed making the window not resizable when it has initially a
fixed size. This change applies a different logic with the same
resulting effect when the window item changes later, for example when
transiting in the live-preview from a fixed size to a resizable window -
by looking at the min/max constraints.
2021-11-12 09:06:35 +01:00
Simon Hausmann
51469be56b
Move more of the winit related code from PlatformWindow impl into WinitWindow
...
This will allow code sharing with the simulator in the future.
2021-11-12 09:02:52 +01:00
Simon Hausmann
68ec3ccf6f
GL backend cleanup
...
Move the window constraint application handling into WinitWindow,
for future sharing.
2021-11-11 11:47:54 +01:00
Simon Hausmann
8de52f1b70
GL backend cleanup
...
Move the OpenGLContext helper into a module of its own, for future sharing.
2021-11-11 11:47:54 +01:00
Simon Hausmann
ad1b251966
Internal cleanup
...
Centralize the setting of the width/height on the window item in the core library.
2021-11-11 11:47:54 +01:00
Simon Hausmann
1fb101c0a0
GL window cleanup
...
Remove internal component() function. There was only one call site.
2021-11-11 11:47:54 +01:00
Simon Hausmann
6fe9c3c23c
GL window cleanup
...
Inline map_window() and unmap_window()
2021-11-11 11:47:52 +01:00
Simon Hausmann
3c0607276c
Make the GL backends' winit driven event loop a reusable module
...
Abstract away the dependency to the former GraphicsWindow by
(1) Renaming GraphicsWindow to GLWindow
(2) Introducing a WinitWindow trait
2021-11-11 11:45:56 +01:00
Aursen
bd613219ba
Refactoring code
2021-11-11 11:45:37 +01:00
Aursen
ceb8ed626c
Fix previous error
2021-11-11 11:45:37 +01:00
Aursen
2962da65a4
Fix the maximization button with a fixed inner size
2021-11-11 11:45:37 +01:00
Olivier Goffart
de43f0a783
Start doing some constant evaluation
...
There was a warning in the C++ generated code in the tests: (in test_cpp_image_geometry)
```
/tmp/.tmpsAMWqZ.cpp:307:85: error: self-comparison always evaluates to true [-Werror,-Wtautological-compare]
this->image_in_layout_fit_ok.set((sixtyfps::cbindgen_private::ImageFit::contain == sixtyfps::cbindgen_private::ImageFit::contain));
^
```
Deoing some simple evaluation prevent this warning at least
2021-11-11 11:14:59 +01:00
Olivier Goffart
4360dc2010
Fix const detection with declared aliases
2021-11-11 11:14:59 +01:00
Olivier Goffart
a3adfd94b1
Const propagation
...
Inline access to constant properties
2021-11-11 11:14:59 +01:00
Olivier Goffart
125ab12816
Don't take the binding when calling visit_element_expressions
...
So that we can visit the expression and the property reference
still have a meaning
2021-11-11 11:14:59 +01:00
Olivier Goffart
dd3fa1c221
Make the BindingMap hold RefCell of the BindingExpression
...
This will allow later to be able to operate on the binding despite the
element is borrowed.
Since the Binding itself is in a RefCell, the analysis don't need to
be anymore.
To do this change, a small change in the binding_analysis logic was required
which means that we will now detect binding loop if a binding was causing
two binding loop. (before, only one binding loop was detected)
2021-11-11 11:14:59 +01:00
Simon Hausmann
a10f832a93
Remove unused dependency
2021-11-10 10:54:56 +01:00
Olivier Goffart
390b838c21
Use intra doc links in the documentation of vtable and const-field-offset macro
2021-11-09 17:37:31 +01:00
Olivier Goffart
973964c2e3
Fix warning in documentation because of a typo
2021-11-09 17:00:43 +01:00
Olivier Goffart
0484c7ea4b
Rename the env variable
...
Co-authored-by: Simon Hausmann <simon.hausmann@sixtyfps.io>
2021-11-09 15:32:33 +01:00
Olivier Goffart
61202c6cba
Make the inlining decision part of the CompilerConfiguration
...
This also enable disable inlining by default
2021-11-09 15:32:33 +01:00
Simon Hausmann
8ff27671ef
Fix absolute item index computation for children of nested sub-components
...
Somehow the focus_change_subcompo test missed this case and the visible
issue of this off-by-one was that
the combo boxes in the printer demo's settings page opened at the wrong location (wrong parent).
2021-11-09 14:52:47 +01:00
Olivier Goffart
669f96d2b6
const-field-offset: Also fix privacy rule when field-offset-trait feature is activated
2021-11-09 14:36:50 +01:00
Olivier Goffart
92998a76aa
Rust: Don't mark the window as pub
...
No reason to have it public
2021-11-09 13:48:22 +01:00