Yuhang Zhao
c849217d43
fix build on linux and macos
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-12-12 14:55:17 +08:00
Yuhang Zhao
f00adba67c
replace QScopedPointer with std::unique_ptr
...
QScopedPointer is being deprecated in latest qtbase code.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-12-12 11:59:53 +08:00
Yuhang Zhao
cb88b602fe
minor tweaks
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-12-05 14:33:38 +08:00
Yuhang Zhao
48a1106fc0
Allow build with no private Qt modules
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-12-04 14:25:09 +08:00
Yuhang Zhao
ff5b171566
win: final fix of the multi-monitor bug
...
#141
#184
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-11-23 14:54:46 +08:00
Yuhang Zhao
3961ecb505
quick: fix a regression
...
Looks like we can't use overloads in QML documents.
Should fix #183
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-11-21 17:12:33 +08:00
Yuhang Zhao
3791802d3b
win: add support for mica alt and other tweaks
...
Add some more comments to the windows header.
Remove the usages of UseRoundWindowCorner.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-11-16 14:10:49 +08:00
Yuhang Zhao
fe6fb8ef5f
win: add new win10 subver
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-19 17:15:23 +08:00
Yuhang Zhao
87da6cb5da
move static_assert to cpp source files
...
To speed up compilation time.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-13 09:44:50 +08:00
Yuhang Zhao
994b02ad6c
quick: add FramelessApplicationWindow element
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-12 10:47:41 +08:00
Yuhang Zhao
fcf51d6d73
refactor
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-11 11:52:49 +08:00
Yuhang Zhao
1e43ba2e81
improve windowborder element
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-10 22:12:01 +08:00
Yuhang Zhao
92415fb61c
Add WindowBorderPainter and WindowBorder
...
1. Added WindowBorderPainter for QtWidgets
2. Added WindowBorder for QtQuick (uses WindowBorderPainter internally)
3. Adjust some header includes
4. Limit a Linux workaround to the appropriate Qt versions
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-10 13:35:37 +08:00
Yuhang Zhao
b50a2dcd72
fix Qt5 compilation error
...
And change to lazy initialization for Mica Material.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-09 10:08:49 +08:00
Yuhang Zhao
d483c39b9a
add way to disable window maximization
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-10-08 15:25:22 +08:00
Yuhang Zhao
ac9a05209e
quick: fix misleading and annoying warning
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-30 12:58:13 +08:00
Yuhang Zhao
f97f000cc7
avoid potential deadlocks
...
And some other minor tweaks.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-25 10:35:00 +08:00
Yuhang Zhao
eeda750a61
finalize api update
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-21 13:22:03 +08:00
Yuhang Zhao
47bf4da5ae
allow user to remove a window from the frameless window list
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-20 15:56:59 +08:00
Yuhang Zhao
3d3607af7b
refactor
...
and maybe avoid potential bugs.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-16 17:38:13 +08:00
Yuhang Zhao
91bb8273b8
routine code quality improvement
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-15 18:24:34 +08:00
Yuhang Zhao
47dcb8f032
quick: emulate Windows behavior more, just like widget
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-14 17:07:06 +08:00
Yuhang Zhao
221f1c12aa
fix button size can't be changed
...
widget: fix the bug
quick: add the interface to change size
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-13 17:38:10 +08:00
Yuhang Zhao
34596db939
fix various issues found by user
...
Issue list:
1. MinGW lacks some definitions so there's compilation errors
2. The chrome buttons' foreground color is incorrect when the window is inactive.
3. Adapt to new macros from Qt dev branch.
4. Remove unneeded parameter from setApplicationOSThemeAware().
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-10 13:11:55 +08:00
Yuhang Zhao
b9f65aa783
add frameless dialog & demo
...
And some other minor fixes.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-09-05 15:00:02 +08:00
Yuhang Zhao
7a35b09a74
add limited qmake support
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-08-31 16:34:30 +08:00
Yuhang Zhao
abf4b29dca
minor fixes of the last commit
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-08-31 10:45:26 +08:00
Yuhang Zhao
463ac0a999
add window icon support
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-08-31 10:21:24 +08:00
Yuhang Zhao
6c060b3946
demo: add shortcut to switch between fullscreen state
...
Can also help use better debugging the old style window frame
issue on Windows.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-08-21 15:38:43 +08:00
Yuhang Zhao
0535276f55
win: use Qt functionalities as much as possible
...
If Qt provides the functionalities we need, use it
instead of reinventing the wheel.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-08-16 15:24:14 +08:00
Yuhang Zhao
775b1a2aab
minor tweaks
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-30 11:34:14 +08:00
Yuhang Zhao
7616161699
Implement homemade Mica material & other improvements
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-16 15:25:15 +08:00
Yuhang Zhao
011b4a85f5
fix Qt5 build
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-07 16:22:34 +08:00
Yuhang Zhao
2806cc811b
code simplification, minor re-structure
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-07 13:43:09 +08:00
Yuhang Zhao
464e2af515
finish the chrome palette implementation
...
And with some other minor tweaks that improve user experience.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-06 14:24:41 +08:00
Yuhang Zhao
e8dcb6e6fe
add api to set title bar and chrome button color
...
TODO:
1. Special handling for the close button
2. Move QuickChromePalette class to own files
3. More testing
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-05 17:58:04 +08:00
Yuhang Zhao
71f8a5aab1
add blurBehindWindowEnabled property
...
Current only implements for Windows,
macOS will be implemented later,
Linux won't be supported in the near future.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-03 16:01:19 +08:00
Yuhang Zhao
f90b49538a
add support for qmltc tool
...
Also remove one useless enum.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-07-01 15:52:28 +08:00
Yuhang Zhao
75f19218c6
minor tweaks
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-06-24 21:38:26 +08:00
Yuhang Zhao
888f9d0aca
standardsystembutton: use icon font instead of svg images
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-06-24 18:04:49 +08:00
Yuhang Zhao
a04fd53a38
general improvements
...
1. replace raw char array with QByteArray
2. Register QWindow for Quick module
3. Account for hidden and disable state when hovering controls
4. fix quick title bar label alignment
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-06-01 11:16:34 +08:00
Yuhang Zhao
0cff5ff48e
add "hideWhenClose" property
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-23 21:09:09 +08:00
Yuhang Zhao
093040ec93
make windowFixedSize a Qt property
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-23 15:17:34 +08:00
Yuhang Zhao
5754f2ec20
common: improve robustness
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-20 17:36:44 +08:00
Yuhang Zhao
44b3730056
quick: remove not used code
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-19 10:23:18 +08:00
Yuhang Zhao
3a0e6f081f
titlebar: allow use alternative background
...
Set this property to true if you want to use your own background color/pixmap
instead of system's current accent color.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-15 11:46:27 +08:00
Yuhang Zhao
d13d74783f
quick: simplify implementation
...
1. Merge the three system buttons into one class.
2. Fixed some color calculation errors of system button.
3. Removed some not used bundled resources.
4. Added function to retrieve runtime version of FramelessHelper.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-13 17:33:01 +08:00
Yuhang Zhao
8042a78b8f
various fixes and improvements
...
1. Make all demo applications be able to record and restore the previous window geometry.
2. Improve the robustness of the widgets and quick implementation.
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-13 14:19:50 +08:00
Yuhang Zhao
5c3b8b70df
general: fix the system button background color in various cases
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-12 17:25:10 +08:00
Yuhang Zhao
8cb24c61b3
general improvements
...
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
2022-05-12 15:07:57 +08:00