00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
#ifndef __netwm_def_h
00027
#define __netwm_def_h
00028
00042 struct NETPoint {
00046 NETPoint() :
x(0),
y(0) { }
00047
00048
00049
00050
00051
int x,
00052 y;
00053 };
00054
00055
00069 struct NETSize {
00073 NETSize() :
width(0),
height(0) { }
00074
00075
00076
00077
00078
int width,
00079 height;
00080 };
00081
00092 struct NETRect {
00098 NETPoint pos;
00099
00105 NETSize size;
00106 };
00107
00108
00120 struct NETIcon {
00124 NETIcon() :
data(0) { }
00125
00131 NETSize size;
00132
00138 unsigned char *
data;
00139 };
00140
00141
00150 struct NETStrut {
00154 NETStrut() :
left(0),
right(0),
top(0),
bottom(0) { }
00155
00159 int left;
00160
00164 int right;
00165
00169 int top;
00170
00174 int bottom;
00175 };
00176
00177
00190 class NET {
00191
public:
00202 enum Role {
00203 Client,
00204 WindowManager
00205 };
00206
00237 enum WindowType {
00238 Unknown = -1,
00239 Normal = 0,
00240 Desktop = 1,
00241 Dock = 2,
00242 Toolbar = 3,
00243 Menu = 4,
00244 Dialog = 5,
00245 Override = 6,
00246 TopMenu = 7,
00247 Tool = Toolbar,
00248
Utility = 8,
00249
Splash = 9
00250 };
00251
00257 enum WindowTypeMask {
00258 NormalMask = 1<<0,
00259 DesktopMask = 1<<1,
00260 DockMask = 1<<2,
00261 ToolbarMask = 1<<3,
00262 MenuMask = 1<<4,
00263 DialogMask = 1<<5,
00264 OverrideMask = 1<<6,
00265 TopMenuMask = 1<<7,
00266 UtilityMask = 1<<8,
00267 SplashMask = 1<<9
00268 };
00269
00311 enum State {
00312 Modal = 1<<0,
00313 Sticky = 1<<1,
00314 MaxVert = 1<<2,
00315 MaxHoriz = 1<<3,
00316 Max = MaxVert | MaxHoriz,
00317 Shaded = 1<<4,
00318 SkipTaskbar = 1<<5,
00319
KeepAbove = 1<<6,
00320 StaysOnTop = KeepAbove,
00321 SkipPager = 1<<7,
00322
Hidden = 1<<8,
00323
FullScreen = 1<<9,
00324
KeepBelow = 1<<10,
00325
DemandsAttention = 1<<11
00326 };
00327
00347 enum Direction {
00348 TopLeft = 0,
00349 Top = 1,
00350 TopRight = 2,
00351 Right = 3,
00352 BottomRight = 4,
00353 Bottom = 5,
00354 BottomLeft = 6,
00355 Left = 7,
00356 Move = 8,
00360
KeyboardSize = 9,
00364
KeyboardMove = 10
00365 };
00366
00381
00382 enum MappingState {
00383 Visible,
00384 Withdrawn,
00385 Iconic
00386 };
00387
00392 enum Action {
00393 ActionMove = 1<<0,
00394 ActionResize = 1<<1,
00395 ActionMinimize = 1<<2,
00396 ActionShade = 1<<3,
00397 ActionStick = 1<<4,
00398 ActionMaxVert = 1<<5,
00399 ActionMaxHoriz = 1<<6,
00400 ActionMax = ActionMaxVert | ActionMaxHoriz,
00401 ActionFullScreen = 1<<7,
00402 ActionChangeDesktop = 1<<8,
00403 ActionClose = 1<<9
00404 };
00405
00452 enum Property {
00453
00454 Supported = 1<<0,
00455 ClientList = 1<<1,
00456 ClientListStacking = 1<<2,
00457 NumberOfDesktops = 1<<3,
00458 DesktopGeometry = 1<<4,
00459 DesktopViewport = 1<<5,
00460 CurrentDesktop = 1<<6,
00461 DesktopNames = 1<<7,
00462 ActiveWindow = 1<<8,
00463 WorkArea = 1<<9,
00464 SupportingWMCheck = 1<<10,
00465 VirtualRoots = 1<<11,
00466 KDESystemTrayWindows = 1<<12,
00467 CloseWindow = 1<<13,
00468 WMMoveResize = 1<<14,
00469
00470
00471 WMName = 1<<15,
00472 WMVisibleName = 1<<16,
00473 WMDesktop = 1<<17,
00474 WMWindowType = 1<<18,
00475 WMState = 1<<19,
00476 WMStrut = 1<<20,
00477 WMIconGeometry = 1<<21,
00478 WMIcon = 1<<22,
00479 WMPid = 1<<23,
00480 WMHandledIcons = 1<<24,
00481 WMPing = 1<<25,
00482 WMKDESystemTrayWinFor = 1<<26,
00483 XAWMState = 1<<27,
00484 WMKDEFrameStrut = 1<<28,
00485
00486
00487 WMIconName = 1<<29,
00488 WMVisibleIconName = 1<<30,
00489 WMGeometry = 1<<31
00490 };
00491
00509 enum Property2 {
00510 WM2UserTime = 1<<0,
00511 WM2StartupId = 1<<1,
00512 WM2TransientFor = 1<<2,
00513 WM2GroupLeader = 1<<3,
00514 WM2AllowedActions = 1<<4,
00515 WM2RestackWindow = 1<<5,
00516 WM2MoveResizeWindow = 1<<6
00517 };
00518
00524
enum { OnAllDesktops = -1 };
00525
00532
00533 enum RequestSource {
00534 FromUnknown,
00535 FromApplication,
00536 FromTool
00537 };
00538 };
00539
00540
00541
#endif // __netwm_def_h