class NETRootInfo
|
Common API for root window properties/protocols. More... |
|
|
Public Methods
- NETRootInfo (Display *display, Window supportWindow, const char *wmName, unsigned long properties, int screen = -1, bool doActivate = true)
- NETRootInfo (Display *display, unsigned long properties, int screen = -1, bool doActivate = true)
- NETRootInfo (const NETRootInfo &rootinfo)
- virtual ~NETRootInfo ()
- Display * x11Display () const
- Window rootWindow () const
- Window supportWindow () const
- const char * wmName () const
- int screenNumber () const
- unsigned long supported () const
- const Window * clientList () const
- int clientListCount () const
- const Window * clientListStacking () const
- int clientListStackingCount () const
- const Window * kdeSystemTrayWindows () const
- int kdeSystemTrayWindowsCount () const
- NETSize desktopGeometry (int desktop) const
- NETPoint desktopViewport (int desktop) const
- NETRect workArea (int desktop) const
- const char * desktopName (int desktop) const
- const Window * virtualRoots ( ) const
- int virtualRootsCount () const
- int numberOfDesktops () const
- int currentDesktop () const
- Window activeWindow () const
- void activate ()
- void setClientList (Window *windows, unsigned int count)
- void setClientListStacking (Window *windows, unsigned int count)
- void setKDESystemTrayWindows (Window *windows, unsigned int count)
- void setCurrentDesktop (int desktop)
- void setDesktopGeometry (int desktop, const NETSize &geometry)
- void setDesktopViewport (int desktop, const NETPoint &viewport)
- void setNumberOfDesktops (int numberOfDesktops)
- void setDesktopName (int desktop, const char *desktopName)
- void setActiveWindow (Window window)
- void setWorkArea (int desktop, const NETRect &workArea)
- void setVirtualRoots (Window *windows, unsigned int count)
- const NETRootInfo & operator= (const NETRootInfo &rootinfo)
- void closeWindowRequest (Window window)
- void moveResizeRequest (Window window, int x_root, int y_root, Direction direction)
- unsigned long event (XEvent *event)
- virtual void addClient (Window)
- virtual void removeClient (Window)
- virtual void addSystemTrayWin (Window)
- virtual void removeSystemTrayWin (Window)
- virtual void changeNumberOfDesktops (int)
- virtual void changeDesktopGeometry (int, const NETSize &)
- virtual void changeDesktopViewport (int, const NETPoint &)
- virtual void changeCurrentDesktop (int)
- virtual void changeActiveWindow (Window)
- virtual void closeWindow (Window)
- virtual void moveResize (Window, int, int, unsigned long)
- void update (unsigned long)
- void setSupported (unsigned long)
Protected Methods
- NETRootInfo (Display *display, Window supportWindow, const char *wmName, unsigned long properties, int screen = -1, bool doActivate = true)
- NETRootInfo (Display *display, unsigned long properties, int screen = -1, bool doActivate = true)
- NETRootInfo (const NETRootInfo &rootinfo)
- virtual ~NETRootInfo ()
- Display * x11Display () const
- Window rootWindow () const
- Window supportWindow () const
- const char * wmName () const
- int screenNumber () const
- unsigned long supported () const
- const Window * clientList () const
- int clientListCount () const
- const Window * clientListStacking () const
- int clientListStackingCount () const
- const Window * kdeSystemTrayWindows () const
- int kdeSystemTrayWindowsCount () const
- NETSize desktopGeometry (int desktop) const
- NETPoint desktopViewport (int desktop) const
- NETRect workArea (int desktop) const
- const char * desktopName (int desktop) const
- const Window * virtualRoots ( ) const
- int virtualRootsCount () const
- int numberOfDesktops () const
- int currentDesktop () const
- Window activeWindow () const
- void activate ()
- void setClientList (Window *windows, unsigned int count)
- void setClientListStacking (Window *windows, unsigned int count)
- void setKDESystemTrayWindows (Window *windows, unsigned int count)
- void setCurrentDesktop (int desktop)
- void setDesktopGeometry (int desktop, const NETSize &geometry)
- void setDesktopViewport (int desktop, const NETPoint &viewport)
- void setNumberOfDesktops (int numberOfDesktops)
- void setDesktopName (int desktop, const char *desktopName)
- void setActiveWindow (Window window)
- void setWorkArea (int desktop, const NETRect &workArea)
- void setVirtualRoots (Window *windows, unsigned int count)
- const NETRootInfo & operator= (const NETRootInfo &rootinfo)
- void closeWindowRequest (Window window)
- void moveResizeRequest (Window window, int x_root, int y_root, Direction direction)
- unsigned long event (XEvent *event)
- virtual void addClient (Window)
- virtual void removeClient (Window)
- virtual void addSystemTrayWin (Window)
- virtual void removeSystemTrayWin (Window)
- virtual void changeNumberOfDesktops (int)
- virtual void changeDesktopGeometry (int, const NETSize &)
- virtual void changeDesktopViewport (int, const NETPoint &)
- virtual void changeCurrentDesktop (int)
- virtual void changeActiveWindow (Window)
- virtual void closeWindow (Window)
- virtual void moveResize (Window, int, int, unsigned long)
- void update (unsigned long)
- void setSupported (unsigned long)
Common API for root window properties/protocols.
The NETRootInfo class provides a commom API for clients and window managers
to set/read/change properties on the root window as defined by the NET Window
Manager Specification..
See also: NET
NETRootInfo (Display *display, Window supportWindow, const char *wmName, unsigned long properties, int screen = -1, bool doActivate = true)
|
Window Managers should use this constructor to create a NETRootInfo object,
which will be used to set/update information stored on the rootWindow.
The application role is automatically set to WindowManager
when using this constructor.
Taken arguments:
- display - an X11 Display struct.
- supportWindow - the Window id of the supportWindow. The supportWindow
must be created by the window manager as a child of the rootWindow. The
supportWindow must not be destroyed until the Window Manager exits.
- wmName - a string which should be the window manager's name (ie. "KWin"
or "Blackbox").
- properties - an OR'ed list of all properties and protocols the window
manager supports (see the NET base class documentation for a description
of all properties and protocols).
- screen - for Window Managers that support multiple screen (ie.
"multiheaded") displays, the screen number may be explicitly defined. If
this argument is omitted, the default screen will be used.
NETRootInfo (Display *display, unsigned long properties, int screen = -1, bool doActivate = true)
|
Clients should use this constructor to create a NETRootInfo object, which
will be used to query information set on the root window. The application
role is automatically set to Client when using this constructor.
Taken arguments:
- display - an X11 Display struct.
- properties - an OR'ed list of all properties and protocols the client
supports (see the NET base class documentation for a description of all
properties and protocols).
- screen - for Clients that support multiple screen (ie. "multiheaded")
displays, the screen number may be explicitly defined. If this argument is
omitted, the default screen will be used.
Creates a shared copy of the specified NETRootInfo object.
[virtual]
Destroys the NETRootInfo object.
[const]
Returns the X11 Display struct used.
[const]
Returns the Window id of the rootWindow.
[const]
Returns the Window id of the supportWindow.
[const]
Returns the name of the Window Manager.
[const]
Returns the screenNumber.
unsigned long supported ()
|
[const]
Returns an OR'ed list of supported protocols and properties.
const Window * clientList ()
|
[const]
Returns an array of Window id's, which contain all managed windows.
See also: clientListCount
[const]
Returns the number of managed windows in clientList array.
const Window * clientListStacking ()
|
[const]
Returns an array of Window id's, which contain all managed windows in
stacking order.
int clientListStackingCount ()
|
[const]
Returns the number of managed windows in the clientListStacking array.
const Window * kdeSystemTrayWindows ()
|
[const]
Returns an array of Window id's, which contain all KDE system tray windows.
int kdeSystemTrayWindowsCount ()
|
[const]
Returns the number of windows in the kdeSystemTrayWindows array.
NETSize desktopGeometry (int desktop)
|
[const]
Returns the desktop geometry size.
The desktop argument is ignored. Early drafts of the NET WM
Specification were unclear about the semantics of this property.
[const]
Returns the viewport of the specified desktop.
[const]
Returns the workArea for the specified desktop.
const char * desktopName (int desktop)
|
[const]
Returns the name for the specified desktop.
const Window * virtualRoots ( )
|
[const]
Returns an array of Window id's, which contain the virtual root windows.
[const]
Returns the number of window in the virtualRoots array.
[const]
Returns the number of desktops.
[const]
Returns the current desktop.
[const]
Returns the active (focused) window.
Window Managers must call this after creating the NETRootInfo object, and
before using any other method in the class. This method sets initial data
on the root window and does other post-construction duties.
Clients must also call this after creating the object to do an initial
data read/update.
void setClientList (Window *windows, unsigned int count)
|
Sets the list of managed windows on the Root/Desktop window.
Taken arguments:
- windows - the array of Window id's
- count - the number of windows in the array
void setClientListStacking (Window *windows, unsigned int count)
|
Sets the list of managed windows in stacking order on the Root/Desktop
window.
Taken arguments:
- windows - the array of Window id's
- count - the number of windows in the array.
void setKDESystemTrayWindows (Window *windows, unsigned int count)
|
Sets the list of KDE system tray windows on the root window.
Taken arguments:
- window - the array of window id's
- count - the number of windows in the array.
void setCurrentDesktop (int desktop)
|
Sets the current desktop to the specified desktop.
void setDesktopGeometry (int desktop, const NETSize &geometry)
|
Sets the desktop geometry to the specified geometry.
The desktop argument is ignored. Early drafts of the NET WM
Specification were unclear about the semantics of this property.
void setDesktopViewport (int desktop, const NETPoint &viewport)
|
Sets the viewport for the current desktop to the specified point.
The desktop argument is ignored. Early drafts of the NET WM
Specification were unclear about the semantics of this property.
void setNumberOfDesktops (int numberOfDesktops)
|
Sets the number of desktops the the specified number.
void setDesktopName (int desktop, const char *desktopName)
|
Sets the name of the specified desktop.
void setActiveWindow (Window window)
|
Sets the active (focused) window the specified window.
void setWorkArea (int desktop, const NETRect &workArea)
|
Sets the workarea for the specified desktop
void setVirtualRoots (Window *windows, unsigned int count)
|
Sets the list of virtual root windows on the root window.
Taken arguments:
- windows - the array of Window id's
- count - the number of windows in the array.
Assignment operator. Ensures that the shared data reference counts are
correct.
void closeWindowRequest (Window window)
|
Clients (such as pagers/taskbars) that wish to close a window should call
this function. This will send a request to the Window Manager, which
usually can usually decide how to react to such requests.
void moveResizeRequest (Window window, int x_root, int y_root, Direction direction)
|
Clients (such as pagers/taskbars) that wish to start a WMMoveResize
(where the window manager controls the resize/movement) should call
this function. This will send a request to the Window Manager.
Taken arguments:
- window - the client window that whould be resized/moved.
- x_root - X position of the cursor relative to the root window.
- y_root - Y position of the cursor relative to the root window.
- direction - one of NET::Direction (see base class documentation for
a description of the different directions).
unsigned long event (XEvent *event)
|
This function takes the passed XEvent and returns an OR'ed list of
NETRootInfo properties that have changed. The new information will be
read immediately by the class.
[protected:
virtual]
A Client should subclass NETRootInfo and reimplement this function when
it wants to know when a window has been added.
void removeClient (Window)
|
[protected:
virtual]
A Client should subclass NETRootInfo and reimplement this function when
it wants to know when a window has been removed.
void addSystemTrayWin (Window)
|
[protected:
virtual]
A Client should subclass NETRootInfo and reimeplement this function when
it wants to know when a system tray window has been added. This is a KDE 2.0
extension.
void removeSystemTrayWin (Window)
|
[protected:
virtual]
A Client should subclass NETRootInfo and reimplement this function when
it wants to know when a system tray window has been removed. This is a KDE 2.0
extension.
void changeNumberOfDesktops (int)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to change the number
of desktops.
void changeDesktopGeometry (int, const NETSize &)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to change the specified
desktop geometry.
void changeDesktopViewport (int, const NETPoint &)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to change the specified
desktop viewport.
void changeCurrentDesktop (int)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to change the current
desktop.
void changeActiveWindow (Window)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to change the active
(focused) window.
void closeWindow (Window)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to close a window.
void moveResize (Window, int, int, unsigned long)
|
[protected:
virtual]
A Window Manager should subclass NETRootInfo and reimplement this function
when it wants to know when a Client made a request to start a move/resize.
Taken arguments:
- window - the window that wants to move/resize
- x_root / y_root - position of the cursor relative to the root window.
- direction - one of NET::Direction (see base class documentation for
a description of the different directions).
- Author: Bradley T. Hughes <bhughes@trolltech.com>
- Generated: marc@yogi on Tue Mar 27 13:06:25 2001, using kdoc 2.0a48.