Commit Graph

944 Commits

Author SHA1 Message Date
Sergio Martins
96cb4b8b07 Rename MultiSplitter to MultiSplitterLayout
As it's no longer a QWidget
2019-06-22 00:13:05 +01:00
Sergio Martins
e96b8cc262 Add a clazy exclude 2019-06-22 00:02:40 +01:00
Sergio Martins
1ac3238d4c Remove unneeded signal arguments 2019-06-22 00:00:54 +01:00
Sergio Martins
0d367994c7 separate MultiSplitter into MultiSplitter and MultiSplitterWidget
This factors out the layouting code into a non-QWidget class, so
it can be reused
2019-06-21 23:56:25 +01:00
Sergio Martins
e10f27ddfa MultiSplitter: Also pass which location and relativeTo was used 2019-06-21 19:32:14 +01:00
Sergio Martins
7c51969731 MultiSplitter: add widgetRemoved() signal
Just like we already have widgetAdded()
2019-06-21 19:11:11 +01:00
Sergio Martins
d44f0257ee Mark some methods as private 2019-06-21 18:55:59 +01:00
Sergio Martins
033179a82c Make LayoutMemory take DockWidget instead of QWidget 2019-06-21 16:30:07 +01:00
Sergio Martins
115fc87ad5 Move LayoutMemory to src/
While MultiSplitter is generic this one will know about DockWidget
2019-06-21 16:21:39 +01:00
Sergio Martins
10244c6e65 Add more checks to .clazy 2019-06-21 16:19:38 +01:00
Sergio Martins
bc69a32fe2 silence a clang-tidy warning about use after free 2019-06-21 13:19:38 +01:00
Sergio Martins
435ace202e clazy: pass a big type by ref and use qAsConst 2019-06-21 13:06:46 +01:00
Sergio Martins
0c521b5cf3 clazy: Add missing Q_OBJECT 2019-06-21 13:06:23 +01:00
Sergio Martins
e1ba281254 Silence some clazy warnings in the tests and examples 2019-06-21 13:05:28 +01:00
Sergio Martins
545d77c770 Silence krazy warning 2019-06-20 16:43:55 +01:00
Sergio Martins
cb0bc99285 cmake: Add -Werror -Wall -Wextra to gcc/clang
At least if DEVELOPER_MODE is enabled
2019-06-20 16:04:34 +01:00
Sergio Martins
77b2ed927d tests: Try to fix build on macOS 2019-06-20 15:55:02 +01:00
Sergio Martins
3fc57d0223 Add a LayoutMemory class, memory in the sense that it remembers
Needed for restoring widgets to their positions when made visible
again
2019-06-20 12:57:27 +01:00
Sergio Martins
25af853f2f Move some static functions into the global namespace 2019-06-19 23:00:43 +01:00
Sergio Martins
e99772fa4f Hide the frame whenever DockWidget::setVisible(false) is called 2019-06-19 17:03:21 +01:00
Sergio Martins
a77d86b6ad readability++ 2019-06-19 15:41:19 +01:00
Sergio Martins
566370eb32 readability: Renamed Frame::widgetCount() to Frame::dockWidgetCount()
dpcs++
2019-06-19 14:44:07 +01:00
Sergio Martins
41d75dd494 tests++ 2019-06-19 12:58:05 +01:00
Sergio Martins
17ddc03b3f Fix DockWidget::isTabbed() when it's in the central frame
The central frame always shows tabs
2019-06-19 11:24:13 +01:00
Sergio Martins
d047702e29 tests: Test redocking the frame before redocking the middle dock
The middle dock still finds its home.
2019-06-19 10:48:08 +01:00
Sergio Martins
270d177d53 docs++ 2019-06-19 10:37:45 +01:00
Sergio Martins
cdcef34497 DockWidget::setFloating(false) now restores to the correct tab 2019-06-19 10:37:18 +01:00
Sergio Martins
ca4421e963 DockWidget::setFloating(false) now restores to previous tab
TODO: Restore to areas (non-tabbed). Will require a bigger refactoring.
2019-06-18 23:29:18 +01:00
Sergio Martins
0410963a3c Fix calling DockWidget::setFloating(true)
The used titlebar wasn't the right one.
2019-06-18 22:02:59 +01:00
Sergio Martins
d60baf9325 docs: random docs 2019-06-18 21:25:46 +01:00
Sergio Martins
aa7ae24b8b DockWidget: Rework setFloating/isFloating a bit
- setFloating() now works if the widget was tabbed.
- isFloating() changes the definition of floating a bit:
  If a widget is tabbed into another one then it's docked, not tabbed.
  To be floating it has to have it's own window and that window not have
  any other dock widgets, which excludes side-by-side and tabbed stuff, even if it's
  in a floating group (FloatingWindow)
2019-06-18 21:23:51 +01:00
Sergio Martins
5a78ef27c1 TabBar: Exposed code that detached a tab
Called TabBar::detachTab(DockWidget).
2019-06-18 21:14:33 +01:00
Sergio Martins
481f466038 Introduce FloatingWindow::hasSingleFrame() and hasSingleDockWidget() 2019-06-18 18:47:16 +01:00
Sergio Martins
e8bf44d238 tests: Add a minimal tst_isTabbed() 2019-06-18 18:29:27 +01:00
Sergio Martins
0e5409dae7 Introduce DockWidget::isTabbed() 2019-06-18 18:16:12 +01:00
Sergio Martins
7c302dc2d1 docs++ 2019-06-18 18:05:15 +01:00
Sergio Martins
48f4f389a2 More docs and improve Anchor::isValid() 2019-06-18 15:52:55 +01:00
Sergio Martins
18347d919f Rename Anchor::Options to Anchor::Type
Because an anchor can only have 1 type, you can't combine different flags.
2019-06-18 15:29:12 +01:00
Sergio Martins
708bf9941a docs: Document Anchor::Option 2019-06-18 14:57:56 +01:00
Sergio Martins
fa7c9c6b7f Update .gitignore to ignore doxygen artifacts 2019-06-18 14:46:07 +01:00
Sergio Martins
525d72b1c9 docs++
Just @file for now
2019-06-18 14:44:33 +01:00
Sergio Martins
55d0968d96 tests: Print the warning category 2019-06-17 18:24:14 +01:00
Sergio Martins
824ff58464 Merge branch 'master' into kdab_master 2019-05-18 11:16:08 +01:00
Laurent Montel
364d2aae40 Use debug category
Change-Id: I18f56a9c85c50da81693004fec03ee6fe93bc9ce
Reviewed-on: https://codereview.kdab.com/68187
Reviewed-by: Sérgio Martins <sergio@kdab.com>
2019-05-17 23:43:27 +02:00
Laurent Montel
b06a9c8d60 Fix forward declaration. Remove not necessary includes
Change-Id: If2dc2c52fa8dbabd9aeca03ba96e01c1c6bce37d
Reviewed-on: https://codereview.kdab.com/68186
Reviewed-by: Sérgio Martins <sergio@kdab.com>
2019-05-15 16:36:42 +02:00
Sergio Martins
8d763e0df9 try to fix macOS build 2019-05-11 23:07:59 +01:00
Sergio Martins
0edcb3e459 Fix rendering the indicators on Linux without a compositor
We use setMask() to punch holes
2019-05-11 22:43:11 +01:00
Sergio Martins
933287e9c3 Add KDDockWidgets::windowManagerSupportsTranslucency() 2019-05-11 22:30:33 +01:00
Sergio Martins
56c33782ec Merge branch 'master' into kdab_master 2019-05-11 22:07:39 +01:00
Laurent Montel
83906dfa21 Remove unused method
Change-Id: I2ee427564bb79c46f58c31991b0468fa2fc73554
Reviewed-on: https://codereview.kdab.com/67900
Reviewed-by: Sérgio Martins <sergio@kdab.com>
2019-05-07 10:11:57 +02:00