KanoopGuiQt 1.3.0
Qt GUI utility library
Loading...
Searching...
No Matches
guitypes.h
1/******************************************************************************************
2**
3** guitypes.h
4**
5** Moved from my Tesseract Engineering repo to open-source
6**
7** Author: Stephen Punak
8** Created: Fri Oct 13 13:08:02 2023
9**
10******************************************************************************************/
11#ifndef GUITYPES_H
12#define GUITYPES_H
13#include <Qt>
14#include <Kanoop/gui/libkanoopgui.h>
15
16/**
17 * @brief KanoopGuiQt namespace containing GUI-specific enumerations and helpers.
18 */
19namespace GUI
20{
21
22/**
23 * @brief Drag-and-drop gesture state.
24 */
26{
27 NotDragging, ///< No drag in progress
28 MaybeDrag, ///< Mouse pressed but threshold not reached
29 Dragging ///< Active drag in progress
30};
31
32/**
33 * @brief Top-level window state.
34 */
36{
37 NormalState, ///< Window is in normal (restored) state
38 Closed, ///< Window has been closed
39 Minimized, ///< Window is minimized
40 Maximized, ///< Window is maximized
41};
42
43/**
44 * @brief Title-bar button visibility flags.
45 */
47{
48 NoButton = 0,
49
50 MaximizeButton = 0x01, ///< Show the maximize button
51 MinimizeButton = 0x02, ///< Show the minimize button
52 CloseButton = 0x04, ///< Show the close button
53};
54Q_DECLARE_FLAGS(TitlebarButtonOptions, TitlebarButtonOption)
55Q_DECLARE_OPERATORS_FOR_FLAGS(TitlebarButtonOptions)
56
57/**
58 * @brief Register KanoopGuiQt metatypes with Qt's type system.
59 *
60 * Call this once at application startup (e.g. from main()) before using
61 * GUI types in signals, slots, or QVariant containers.
62 */
63LIBKANOOPGUI_EXPORT void registerMetatypes();
64} // namespace GUI
65
66
67#endif // GUITYPES_H
KanoopGuiQt namespace containing GUI-specific enumerations and helpers.
Definition guitypes.h:20
WindowState
Top-level window state.
Definition guitypes.h:36
@ Closed
Window has been closed.
Definition guitypes.h:38
@ Maximized
Window is maximized.
Definition guitypes.h:40
@ NormalState
Window is in normal (restored) state.
Definition guitypes.h:37
@ Minimized
Window is minimized.
Definition guitypes.h:39
LIBKANOOPGUI_EXPORT void registerMetatypes()
Register KanoopGuiQt metatypes with Qt's type system.
DragState
Drag-and-drop gesture state.
Definition guitypes.h:26
@ NotDragging
No drag in progress.
Definition guitypes.h:27
@ Dragging
Active drag in progress.
Definition guitypes.h:29
@ MaybeDrag
Mouse pressed but threshold not reached.
Definition guitypes.h:28
TitlebarButtonOption
Title-bar button visibility flags.
Definition guitypes.h:47
@ CloseButton
Show the close button.
Definition guitypes.h:52
@ MinimizeButton
Show the minimize button.
Definition guitypes.h:51
@ MaximizeButton
Show the maximize button.
Definition guitypes.h:50