forked from nspire-emus/firebird
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathdockwidget.h
More file actions
31 lines (22 loc) · 723 Bytes
/
Copy pathdockwidget.h
File metadata and controls
31 lines (22 loc) · 723 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#ifndef DOCKWIDGET_H
#define DOCKWIDGET_H
#include <QDockWidget>
/* This class augments QDockWidget with the function
* to hide the titlebar of non-floating docks. */
class DockWidget : public QDockWidget
{
Q_OBJECT
public:
explicit DockWidget(const QString &title, QWidget *parent = nullptr,
Qt::WindowFlags flags = Qt::WindowFlags());
explicit DockWidget(QWidget *parent = nullptr, Qt::WindowFlags flags = Qt::WindowFlags())
: DockWidget({}, parent, flags) {}
~DockWidget() {}
void hideTitlebar(bool b);
protected slots:
void refreshTitlebar();
protected:
bool hide_titlebar_if_possible = false;
QWidget empty_titlebar;
};
#endif // DOCKWIDGET_H