From c20c79cfd367c2a68d5fcc1eb822143b9023727e Mon Sep 17 00:00:00 2001 From: Henrik Hautakoski Date: Sun, 2 Oct 2022 17:00:45 +0200 Subject: [PATCH] Adding source/Platform/Unix/wm_hints.h --- source/Platform/Unix/wm_hints.h | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 source/Platform/Unix/wm_hints.h diff --git a/source/Platform/Unix/wm_hints.h b/source/Platform/Unix/wm_hints.h new file mode 100644 index 0000000..6e9e470 --- /dev/null +++ b/source/Platform/Unix/wm_hints.h @@ -0,0 +1,32 @@ + +#ifndef SPECTRE_PLATFORM_UNIX_WM_HINTS_H +#define SPECTRE_PLATFORM_UNIX_WM_HINTS_H + +#define MWM_HINTS_FUNCTIONS (1 << 0) +#define MWM_HINTS_DECORATIONS (1 << 1) + +#define MWM_DECOR_BORDER (1 << 1) +#define MWM_DECOR_RESIZEH (1 << 2) +#define MWM_DECOR_TITLE (1 << 3) +#define MWM_DECOR_MENU (1 << 4) +#define MWM_DECOR_MINIMIZE (1 << 5) +#define MWM_DECOR_MAXIMIZE (1 << 6) + +#define MWM_FUNC_RESIZE (1 << 1) +#define MWM_FUNC_MOVE (1 << 2) +#define MWM_FUNC_MINIMIZE (1 << 3) +#define MWM_FUNC_MAXIMIZE (1 << 4) +#define MWM_FUNC_CLOSE (1 << 5) + +// Number of elements in WMHints struct. +#define WMHINTS_NUM_ELEMENTS (sizeof(struct WMHints) / sizeof(long)) + +struct WMHints{ + unsigned long flags; + unsigned long functions; + unsigned long decorations; + long inputMode; + unsigned long state; +}; + +#endif /* SPECTRE_PLATFORM_UNIX_WM_HINTS_H */