# kdecore Library API Documentation

Overview | Class Hierarchy | Classes | Classes (annotated) | Members | Namespaces | Source Files

# netwm_def.h

    00001 /*
    00002
    00003   Copyright (c) 2000 Troll Tech AS
    00004   Copyright (c) 2003 Lubos Lunak <l.lunak@kde.org>
    00005
    00006   Permission is hereby granted, free of charge, to any person obtaining a
    00007   copy of this software and associated documentation files (the "Software"),
    00008   to deal in the Software without restriction, including without limitation
    00009   the rights to use, copy, modify, merge, publish, distribute, sublicense,
    00010   and/or sell copies of the Software, and to permit persons to whom the
    00011   Software is furnished to do so, subject to the following conditions:
    00012
    00013   The above copyright notice and this permission notice shall be included in
    00014   all copies or substantial portions of the Software.
    00015
    00016   THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
    00017   IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
    00018   FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
    00019   THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
    00020   LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
    00021   FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
    00022   DEALINGS IN THE SOFTWARE.
    00023
    00024 */
    00025
    00026 #ifndef   __netwm_def_h
    00027 #define   __netwm_def_h
    00028
    00029 #include <kdelibs_export.h>
    00030
    00044 struct NETPoint {
    00048     NETPoint() : x(0), y(0) { }
    00049
    00050     /*
    00051        Public data member.
    00052     **/
    00053     int x,
    00054       y;
    00055 };
    00056
    00057
    00071 struct NETSize {
    00075     NETSize() : width(0), height(0) { }
    00076
    00077     /*
    00078        Public data member.
    00079     **/
    00080     int width,
    00081       height;
    00082 };
    00083
    00094 struct NETRect {
    00100     NETPoint pos;
    00101
    00107     NETSize size;
    00108 };
    00109
    00110
    00122 struct NETIcon {
    00126     NETIcon() : data(0) { }
    00127
    00133     NETSize size;
    00134
    00140     unsigned char *data;
    00141 };
    00142
    00143
    00153 struct NETExtendedStrut {
    00157     NETExtendedStrut() : left_width(0), left_start(0), left_end(0),
    00158         right_width(0), right_start(0), right_end(0), top_width(0), top_start(0), top_end(0),
    00159         bottom_width(0), bottom_start(0), bottom_end(0) {}
    00160
    00164     int left_width, left_start, left_end;
    00165
    00169     int right_width, right_start, right_end;
    00170
    00174     int top_width, top_start, top_end;
    00175
    00179     int bottom_width, bottom_start, bottom_end;
    00180
    00181 };
    00182
    00183
    00195 struct NETStrut {
    00199     NETStrut() : left(0), right(0), top(0), bottom(0) { }
    00200
    00204     int left;
    00205
    00209     int right;
    00210
    00214     int top;
    00215
    00219     int bottom;
    00220 };
    00221
    00222
    00235 class KDECORE_EXPORT NET {
    00236 public:
    00247     enum Role {
    00248     Client,
    00249     WindowManager
    00250     };
    00251
    00282     enum WindowType {
    00283     Unknown  = -1,
    00284     Normal   = 0,
    00285     Desktop  = 1,
    00286     Dock     = 2,
    00287     Toolbar  = 3,
    00288         Menu     = 4,
    00289     Dialog   = 5,
    00290     Override = 6, // NON STANDARD
    00291         TopMenu  = 7, // NON STANDARD
    00292     Tool     = Toolbar, // This will go away soon, COMPAT (How soon? :)
    00293     Utility  = 8,
    00294     Splash   = 9
    00295     };
    00296
    00302     enum WindowTypeMask {
    00303     NormalMask   = 1<<0,
    00304     DesktopMask  = 1<<1,
    00305     DockMask     = 1<<2,
    00306     ToolbarMask  = 1<<3,
    00307     MenuMask     = 1<<4,
    00308     DialogMask   = 1<<5,
    00309     OverrideMask = 1<<6,
    00310         TopMenuMask  = 1<<7,
    00311     UtilityMask  = 1<<8,
    00312     SplashMask   = 1<<9
    00313     };
    00314
    00315     // KDE4 move to WindowTypeMask
    00316     enum { AllTypesMask = 0LU-1 };
    00317
    00322     static bool typeMatchesMask( WindowType type, unsigned long mask );
    00323
    00365     enum State {
    00366     Modal        = 1<<0,
    00367     Sticky       = 1<<1,
    00368     MaxVert      = 1<<2,
    00369     MaxHoriz     = 1<<3,
    00370     Max = MaxVert | MaxHoriz,
    00371     Shaded       = 1<<4,
    00372     SkipTaskbar  = 1<<5,
    00373     KeepAbove    = 1<<6,
    00374     StaysOnTop   = KeepAbove,   // NOT STANDARD
    00375     SkipPager    = 1<<7,
    00376     Hidden       = 1<<8,
    00377     FullScreen   = 1<<9,
    00378     KeepBelow    = 1<<10,
    00379         DemandsAttention = 1<<11
    00380     };
    00381
    00401     enum Direction {
    00402     TopLeft      = 0,
    00403     Top          = 1,
    00404     TopRight     = 2,
    00405     Right        = 3,
    00406     BottomRight  = 4,
    00407     Bottom       = 5,
    00408     BottomLeft   = 6,
    00409     Left         = 7,
    00410     Move         = 8,  // movement only
    00414     KeyboardSize = 9,  // size via keyboard
    00418     KeyboardMove = 10  // move via keyboard
    00419     };
    00420
    00435     // KDE4 aaarghl, this doesn't map correctly to Xlib #defines
    00436     enum MappingState {
    00437     Visible, // ie. NormalState
    00438     Withdrawn,
    00439     Iconic
    00440     };
    00441
    00446     enum Action {
    00447         ActionMove           = 1<<0,
    00448         ActionResize         = 1<<1,
    00449         ActionMinimize       = 1<<2,
    00450         ActionShade          = 1<<3,
    00451         ActionStick          = 1<<4,
    00452         ActionMaxVert        = 1<<5,
    00453         ActionMaxHoriz       = 1<<6,
    00454         ActionMax            = ActionMaxVert | ActionMaxHoriz,
    00455         ActionFullScreen     = 1<<7,
    00456         ActionChangeDesktop  = 1<<8,
    00457         ActionClose          = 1<<9
    00458     };
    00459
    00506     enum Property {
    00507     // root
    00508     Supported             = 1<<0,
    00509     ClientList            = 1<<1,
    00510     ClientListStacking    = 1<<2,
    00511     NumberOfDesktops      = 1<<3,
    00512     DesktopGeometry       = 1<<4,
    00513     DesktopViewport       = 1<<5,
    00514     CurrentDesktop        = 1<<6,
    00515     DesktopNames          = 1<<7,
    00516     ActiveWindow          = 1<<8,
    00517     WorkArea              = 1<<9,
    00518     SupportingWMCheck     = 1<<10,
    00519     VirtualRoots          = 1<<11,
    00520     KDESystemTrayWindows  = 1<<12, // NOT STANDARD
    00521     CloseWindow           = 1<<13,
    00522     WMMoveResize          = 1<<14,
    00523
    00524     // window
    00525     WMName                = 1<<15,
    00526     WMVisibleName         = 1<<16,
    00527     WMDesktop             = 1<<17,
    00528     WMWindowType          = 1<<18,
    00529     WMState               = 1<<19,
    00530     WMStrut               = 1<<20,
    00531     WMIconGeometry        = 1<<21,
    00532     WMIcon                = 1<<22,
    00533     WMPid                 = 1<<23,
    00534     WMHandledIcons        = 1<<24,
    00535     WMPing                = 1<<25,
    00536     WMKDESystemTrayWinFor = 1<<26, // NOT STANDARD
    00537     XAWMState             = 1<<27, // NOT STANDARD
    00538     WMKDEFrameStrut       = 1<<28, // NOT STANDARD
    00539
    00540     // Need to be reordered
    00541     WMIconName            = 1<<29,
    00542     WMVisibleIconName     = 1<<30,
    00543     WMGeometry        = 1<<31
    00544     };
    00545
    00568     enum Property2 {
    00569         WM2UserTime            = 1<<0,
    00570         WM2StartupId           = 1<<1,
    00571         WM2TransientFor        = 1<<2,
    00572         WM2GroupLeader         = 1<<3,
    00573         WM2AllowedActions      = 1<<4,
    00574         WM2RestackWindow       = 1<<5,
    00575         WM2MoveResizeWindow    = 1<<6,
    00576         WM2ExtendedStrut       = 1<<7,
    00577         WM2TakeActivity        = 1<<8,
    00578         WM2KDETemporaryRules   = 1<<9,  // NOT STANDARD
    00579         WM2WindowClass         = 1<<10,
    00580         WM2WindowRole          = 1<<11,
    00581         WM2ClientMachine       = 1<<12
    00582     };
    00583
    00589     enum { OnAllDesktops = -1 };
    00590
    00597     // must match the values for data.l[0] field in _NET_ACTIVE_WINDOW message
    00598     enum RequestSource {
    00599         FromUnknown, // internal
    00600         FromApplication,
    00601         FromTool
    00602     };
    00603 };
    00604
    00605
    00606 #endif // __netwm_def_h

This file is part of the documentation for kdecore Library Version 3.4.1.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Sat Jun 11 20:18:13 2005 by doxygen 1.4.1 written by Dimitri van Heesch, © 1997-2003