kdecore Library API Documentation

KWin Class Reference

Convenience access to certain properties and features of the window manager.Class for interaction with the window manager. More...

#include <kwin.h>

List of all members.

Public Types

enum  IconSource { NETWM = 1, WMHints = 2, ClassHint = 4, XApp = 8 }

Public Member Functions

 WindowInfo (WId window, unsigned long properties, unsigned long properties2)
 WindowInfo ()
bool valid (bool withdrawn_is_valid=false) const
WId win () const
unsigned long state () const
bool hasState (unsigned long s) const
bool isMinimized () const
NET::MappingState mappingState () const
NETExtendedStrut extendedStrut () const
NETStrut strut () const
NET::WindowType windowType (int supported_types) const
QString visibleName () const
QString visibleNameWithState () const
QString name () const
QString visibleIconName () const
QString visibleIconNameWithState () const
QString iconName () const
bool isOnCurrentDesktop () const
bool isOnDesktop (int desktop) const
bool onAllDesktops () const
int desktop () const
QRect geometry () const
QRect frameGeometry () const
WId transientFor () const
WId groupLeader () const
QCString windowClassClass () const
QCString windowClassName () const
QCString windowRole () const
QCString clientMachine () const
bool actionSupported (NET::Action action) const
 WindowInfo (const WindowInfo &)
WindowInfo & operator= (const WindowInfo &)

Static Public Member Functions

static void activateWindow (WId win, long time=0)
static void forceActiveWindow (WId win, long time=0)
static void setActiveWindow (WId win) KDE_DEPRECATED
static void demandAttention (WId win, bool set=true)
static void setUserTime (WId win, long time)
static void invokeContextHelp ()
static void setMainWindow (QWidget *subwindow, WId mainwindow)
static void setSystemTrayWindowFor (WId trayWin, WId forWin)
static WindowInfo windowInfo (WId win, unsigned long properties=0, unsigned long properties2=0)
static WId transientFor (WId window)
static WId groupLeader (WId window)
static QPixmap icon (WId win, int width=-1, int height=-1, bool scale=false)
static QPixmap icon (WId win, int width, int height, bool scale, int flags)
static void setIcons (WId win, const QPixmap &icon, const QPixmap &miniIcon)
static void setType (WId win, NET::WindowType windowType)
static void setState (WId win, unsigned long state)
static void clearState (WId win, unsigned long state)
static void setOpacity (WId win, uint percent)
static void setShadowSize (WId win, uint percent)
static void setOnAllDesktops (WId win, bool b)
static void setOnDesktop (WId win, int desktop)
static void setExtendedStrut (WId win, int left_width, int left_start, int left_end, int right_width, int right_start, int right_end, int top_width, int top_start, int top_end, int bottom_width, int bottom_start, int bottom_end)
static void setStrut (WId win, int left, int right, int top, int bottom)
static int currentDesktop ()
static int numberOfDesktops ()
static void setCurrentDesktop (int desktop)
static void iconifyWindow (WId win, bool animation=true)
static void deIconifyWindow (WId win, bool animation=true)
static void raiseWindow (WId win)
static void lowerWindow (WId win)
static bool icccmCompliantMappingState ()
static bool allowedActionsSupported ()
static QString readNameProperty (WId window, unsigned long atom)
static Info info (WId win) KDE_DEPRECATED

Classes

struct  Info


Detailed Description

Convenience access to certain properties and features of the window manager.Class for interaction with the window manager.

This class is not supposed to be instantiated. It exists mostly as a namespace for the static member functions.

In KDE 2 and KDE 3, communication with the windowmanager is done with the NET-protocol, a common window manager specification designed by various authors of X11 window managers (including those of the KDE project). The full specification can be found at www.freedesktop.org/standards/wm-spec .

To access features of the NET-protocol, use the classes NETRootInfo and NETWinInfo.

The purpose of this class is to to provide easy access to the most-commonly used NET-features with a simpler, KDEish interface.

In addition, it encapsulates KDE functionality not yet provided by the NET hints. Currently that is invokeContextHelp() and setSystemTrayWindowFor() only.

See also:
NET

NetWinInfo

Author:
Matthias Ettrich (ettrich@kde.org)

Definition at line 61 of file kwin.h.


Member Enumeration Documentation

enum KWin::IconSource
 

Masks specifying from which sources to read an icon.

They are tried from the best until an icon is found.

  • NETWM from property from the window manager specification
  • WMHints from WMHints property
  • ClassHint load icon after getting name from the classhint
  • XApp load the standard X icon (last fallback)
Enumerator:
NETWM  read from property from the window manager specification
WMHints  read from WMHints property
ClassHint  load icon after getting name from the classhint
XApp  load the standard X icon (last fallback)

Definition at line 230 of file kwin.h.


Member Function Documentation

void KWin::activateWindow WId  win,
long  time = 0
[static]
 

Requests that window win is activated.

There are two ways how to activate a window, by calling activateWindow() and forceActiveWindow(). Generally, applications shouldn't make attempts to explicitly activate their windows, and instead let the user to activate them. In the special cases where this may be needed, applications should use activateWindow(). Window manager may consider whether this request wouldn't result in focus stealing, which would be obtrusive, and may refuse the request.

The usage of forceActiveWindow() is meant only for pagers and similar tools, which represent direct user actions related to window manipulation. Except for rare cases, this request will be always honored, and normal applications are forbidden to use it.

In case of problems, consult the KWin README in the kdebase package (kdebase/kwin/README), or ask on the kwin@kde.org mailing list.

Parameters:
win the id of the window to make active
time X server timestamp of the user activity that caused this request
Since:
3.2

Definition at line 221 of file kwin.cpp.

References info(), NETRootInfo::setActiveWindow(), and KUniqueApplication::setHandleAutoStarted().

void KWin::forceActiveWindow WId  win,
long  time = 0
[static]
 

Sets window win to be the active window.

Note that this should be called only in special cases, applications shouldn't force themselves or other windows to be the active window. Generally, this call should used only by pagers and similar tools. See the explanation in description of activateWindow().

Parameters:
win the id of the window to make active
time X server timestamp of the user activity that caused this request
Since:
3.2

Definition at line 233 of file kwin.cpp.

References info(), NETRootInfo::setActiveWindow(), and KUniqueApplication::setHandleAutoStarted().

Referenced by KStartupInfo::setNewStartupId().

void KWin::setActiveWindow WId  win  )  [static]
 

Deprecated:
Consider using activateWindow(), use forceActiveWindow() only if necessary.

Definition at line 244 of file kwin.cpp.

References info(), NETRootInfo::setActiveWindow(), and KUniqueApplication::setHandleAutoStarted().

void KWin::demandAttention WId  win,
bool  set = true
[static]
 

When application finishes some operation and wants to notify the user about it, it can call demandAttention().

Instead of activating the window, which could be obtrusive, the window will be marked specially as demanding user's attention. See also explanation in description of activateWindow().

Note that it's usually better to use KNotifyClient.

Since:
3.2

Definition at line 253 of file kwin.cpp.

References NET::DemandsAttention, info(), and NETWinInfo::setState().

void KWin::setUserTime WId  win,
long  time
[static]
 

Sets user timestamp time on window win.

The timestamp is expressed as XServer time. If a window is shown with user timestamp older than the time of the last user action, it won't be activated after being shown. The most common case is the special value 0 which means not to activate the window after being shown.

Since:
3.2

Definition at line 261 of file kwin.cpp.

References info(), and NETWinInfo::setUserTime().

void KWin::invokeContextHelp  )  [static]
 

Invokes interactive context help.

Definition at line 198 of file kwin.cpp.

void KWin::setMainWindow QWidget subwindow,
WId  mainwindow
[static]
 

Sets the parent window of subwindow to be mainwindow.

This overrides the parent set the usual way as the QWidget parent, but only for the window manager - e.g. stacking order and window grouping will be affected, but features like automatic deletion of children when the parent is deleted are unaffected and normally use the QWidget parent.

This function should be used before a dialog is shown for a window that belongs to another application.

Since:
3.4

Definition at line 289 of file kwin.cpp.

References endl(), kdWarning(), QWidget::parentWidget(), and QWidget::winId().

void KWin::setSystemTrayWindowFor WId  trayWin,
WId  forWin
[static]
 

Makes trayWin a system tray window for forWin.

A system tray window serves as an icon replacement. It's displayed inside the panel's system tray.

Parameters:
trayWin the id of the system tray window
forWin the id of the window represented by the system tray window

Definition at line 205 of file kwin.cpp.

References endl(), info(), NETRootInfo::isSupported(), kdWarning(), DCOPRef::send(), and NETWinInfo::setKDESystemTrayWinFor().

KWin::WindowInfo KWin::windowInfo WId  win,
unsigned long  properties = 0,
unsigned long  properties2 = 0
[static]
 

Returns information about window win.

It is recommended to check whether the returned info is valid by calling the valid() method.

Parameters:
win the id of the window
properties all properties that should be retrieved (see NET::Property enum for details) - passing 0 means all properties. Unlisted properties cause related information to be invalid in the returned data, but make this function faster when not all data is needed.
properties2 additional properties (see NET::Property2 enum)
Returns:
the window information
Since:
3.2

Definition at line 269 of file kwin.cpp.

References WindowInfo().

WId KWin::transientFor WId  window  )  [static]
 

Returns the WM_TRANSIENT_FOR property for the given window, i.e.

the mainwindow for this window.

Parameters:
window the id of the window
Since:
3.2

Definition at line 275 of file kwin.cpp.

WId KWin::groupLeader WId  window  )  [static]
 

Returns the leader window for the group the given window is in, if any.

Parameters:
window the id of the window
Since:
3.2

Definition at line 311 of file kwin.cpp.

QPixmap KWin::icon WId  win,
int  width = -1,
int  height = -1,
bool  scale = false
[static]
 

Returns an icon for window win.

If width and height are specified, the best icon for the requested size is returned.

If scale is true, the icon is smooth-scaled to have exactly the requested size.

Parameters:
win the id of the window
width the desired width, or -1
height the desired height, or -1
scale if true the icon will be scaled to the desired size. Otherwise the icon will not be modified.
Returns:
the icon of the window

Definition at line 377 of file kwin.cpp.

References ClassHint, NETWM, WMHints, and XApp.

QPixmap KWin::icon WId  win,
int  width,
int  height,
bool  scale,
int  flags
[static]
 

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Overloaded variant that allows specifying from which sources the icon should be read.

You should usually prefer the simpler variant which tries all possibilities to get an icon.

Parameters:
win the id of the window
width the desired width, or -1
height the desired height, or -1
scale if true the icon will be scaled to the desired size. Otherwise the icon will not be modified.
flags OR-ed flags from the IconSource enum
Since:
3.2

Definition at line 383 of file kwin.cpp.

References ClassHint, QPixmap::convertFromImage(), QPixmap::convertToImage(), NETIcon::data, KIcon::DefaultState, QPixmap::detach(), NETSize::height, NETWinInfo::icon(), KInstance::iconLoader(), info(), KGlobal::instance(), QPixmap::isNull(), QImage::isNull(), KIconLoader::loadIcon(), QString::lower(), NETWM, QImage::setAlphaBuffer(), QPixmap::setMask(), QImage::size(), NETIcon::size, KIcon::Small, QImage::smoothScale(), NETSize::width, WMHints, and XApp.

void KWin::setIcons WId  win,
const QPixmap icon,
const QPixmap miniIcon
[static]
 

Sets an icon and a miniIcon on window win.

Parameters:
win the id of the window
icon the new icon
miniIcon the new mini icon

Definition at line 499 of file kwin.cpp.

References QImage::bits(), QPixmap::convertToImage(), NETIcon::data, NETSize::height, info(), QPixmap::isNull(), NETWinInfo::setIcon(), QImage::size(), NETIcon::size, and NETSize::width.

Referenced by KApplication::notify(), and KApplication::setTopWidget().

void KWin::setType WId  win,
NET::WindowType  windowType
[static]
 

Sets the type of window win to windowType.

Possible values are NET::Normal, NET::Desktop, NET::Dock, NET::Tool, NET::Menu, NET::Dialog, NET::Override (== no decoration frame), NET::TopMenu, NET::Utility or NET::Splash

Parameters:
win the id of the window
windowType the type of the window

Definition at line 521 of file kwin.cpp.

References info(), and NETWinInfo::setWindowType().

void KWin::setState WId  win,
unsigned long  state
[static]
 

Sets the state of window win to state.

Possible values are or'ed combinations of NET::Modal, NET::Sticky, NET::MaxVert, NET::MaxHoriz, NET::Shaded, NET::SkipTaskbar, NET::SkipPager, NET::Hidden, NET::FullScreen, NET::KeepAbove, NET::KeepBelow, NET::StaysOnTop

Parameters:
win the id of the window
state the new flags that will be set

Definition at line 529 of file kwin.cpp.

References info(), and NETWinInfo::setState().

void KWin::clearState WId  win,
unsigned long  state
[static]
 

Clears the state of window win from state.

Possible values are or'ed combinations of NET::Modal, NET::Sticky, NET::MaxVert, NET::MaxHoriz, NET::Shaded, NET::SkipTaskbar, NET::SkipPager, NET::Hidden, NET::FullScreen, NET::KeepAbove, NET::KeepBelow, NET::StaysOnTop

Parameters:
win the id of the window
state the flags that will be cleared

Definition at line 537 of file kwin.cpp.

References info(), and NETWinInfo::setState().

void KWin::setOpacity WId  win,
uint  percent
[static]
 

Sets the opacity of window win to percetage percent.

Convenience function that just sets an X property needs a running composite manager for any visible effect

Parameters:
win the id of the window
percent the opacity value in percent (will be justified to [ 0: transparent - 100: opaque ])
Since:
3.4

Definition at line 545 of file kwin.cpp.

void KWin::setShadowSize WId  win,
uint  percent
[static]
 

Sets the shadowsize of window win to percetage percent.

Convenience function that just sets an X property needs the running KDE kompmgr manager for any visible effect

Parameters:
win the id of the window
percent the opacity value in percent (0 leads to a completely unshadowed window)
Since:
3.4

Definition at line 559 of file kwin.cpp.

void KWin::setOnAllDesktops WId  win,
bool  b
[static]
 

Sets window win to be present on all virtual desktops if is true.

Otherwise the window lives only on one single desktop.

Parameters:
win the id of the window
b true to show the window on all desktops, false otherwise

Definition at line 568 of file kwin.cpp.

References NETRootInfo::currentDesktop(), NETWinInfo::desktop(), info(), NETWinInfo::OnAllDesktops, and NETWinInfo::setDesktop().

void KWin::setOnDesktop WId  win,
int  desktop
[static]
 

Moves window win to desktop desktop.

Parameters:
win the id of the window
desktop the number of the new desktop

Definition at line 581 of file kwin.cpp.

References info(), and NETWinInfo::setDesktop().

void KWin::setExtendedStrut WId  win,
int  left_width,
int  left_start,
int  left_end,
int  right_width,
int  right_start,
int  right_end,
int  top_width,
int  top_start,
int  top_end,
int  bottom_width,
int  bottom_start,
int  bottom_end
[static]
 

Sets the strut of window win to to left width ranging from left_start to left_end on the left edge, and simiarly for the other edges.

For not reserving a strut, pass 0 as the width. E.g. to reserve 10x10 square in the topleft corner, use e.g. setExtendedStrut( w, 10, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0 ).

Parameters:
win the id of the window
left_width width of the strut at the left edge
left_start starting y coordinate of the strut at the left edge
left_end ending y coordinate of the strut at the left edge
right_width width of the strut at the right edge
right_start starting y coordinate of the strut at the right edge
right_end ending y coordinate of the strut at the right edge
top_width width of the strut at the top edge
top_start starting x coordinate of the strut at the top edge
top_end ending x coordinate of the strut at the top edge
bottom_width width of the strut at the bottom edge
bottom_start starting x coordinate of the strut at the bottom edge
bottom_end ending x coordinate of the strut at the bottom edge

Definition at line 589 of file kwin.cpp.

References NETExtendedStrut::bottom_end, NETExtendedStrut::bottom_start, NETExtendedStrut::bottom_width, info(), NETExtendedStrut::left_end, NETExtendedStrut::left_start, NETExtendedStrut::left_width, NETExtendedStrut::right_end, NETExtendedStrut::right_start, NETExtendedStrut::right_width, NETWinInfo::setExtendedStrut(), strut(), NETExtendedStrut::top_end, NETExtendedStrut::top_start, and NETExtendedStrut::top_width.

void KWin::setStrut WId  win,
int  left,
int  right,
int  top,
int  bottom
[static]
 

Deprecated:
use setExtendedStrut() Sets the strut of window win to left, right, top, bottom.

Parameters:
win the id of the window
left the left strut
right the right strut
top the top strut
bottom the bottom strut

Definition at line 612 of file kwin.cpp.

References NETStrut::bottom, info(), NETStrut::left, NETStrut::right, NETWinInfo::setStrut(), strut(), and NETStrut::top.

int KWin::currentDesktop  )  [static]
 

Convenience function to access the current desktop.

See NETRootInfo.

Returns:
the number of the current desktop

Definition at line 625 of file kwin.cpp.

References NETRootInfo::currentDesktop(), and info().

int KWin::numberOfDesktops  )  [static]
 

Convenience function to access the number of desktops.

See NETRootInfo.

Returns:
the number of desktops

Definition at line 637 of file kwin.cpp.

References info(), and NETRootInfo::numberOfDesktops().

void KWin::setCurrentDesktop int  desktop  )  [static]
 

Convenience function to set the current desktop to desktop.

See NETRootInfo.

Parameters:
desktop the number of the new desktop

Definition at line 649 of file kwin.cpp.

References info(), and NETRootInfo::setCurrentDesktop().

void KWin::iconifyWindow WId  win,
bool  animation = true
[static]
 

Iconifies a window.

Compatible to XIconifyWindow but has an additional parameter animation.

Parameters:
win the id of the window
animation true to show an animation
See also:
deIconifyWindow()

Definition at line 658 of file kwin.cpp.

void KWin::deIconifyWindow WId  win,
bool  animation = true
[static]
 

DeIconifies a window.

Compatible to XMapWindow but has an additional parameter animation.

Parameters:
win the id of the window
animation true to show an animation
See also:
iconifyWindow()

Definition at line 671 of file kwin.cpp.

void KWin::raiseWindow WId  win  )  [static]
 

Raises the given window.

This call is only for pagers and similar tools that represent direct user actions. Applications should not use it, they should keep using QWidget::raise() or XRaiseWindow() if necessary.

Since:
3.2

Definition at line 683 of file kwin.cpp.

References info(), NETRootInfo::isSupported(), and NETRootInfo::restackRequest().

void KWin::lowerWindow WId  win  )  [static]
 

Lowers the given window.

This call is only for pagers and similar tools that represent direct user actions. Applications should not use it, they should keep using QWidget::lower() or XLowerWindow() if necessary.

Since:
3.2

Definition at line 694 of file kwin.cpp.

References info(), NETRootInfo::isSupported(), and NETRootInfo::restackRequest().

bool KWin::allowedActionsSupported  )  [static]
 

Returns true if the WM announces which actions it allows for windows.

Since:
3.2

Definition at line 1197 of file kwin.cpp.

References info(), and NETRootInfo::isSupported().

QString KWin::readNameProperty WId  window,
unsigned long  atom
[static]
 

Function that reads and returns the contents of the given text property (WM_NAME, WM_ICON_NAME,.

..).

Since:
3.2

Definition at line 1211 of file kwin.cpp.

References QString::fromLocal8Bit().

KWin::Info KWin::info WId  win  )  [static]
 

Deprecated:
Use
See also:
windowInfo() .

Definition at line 331 of file kwin.cpp.

References NETWinInfo::desktop(), KWin::Info::desktop, KWin::Info::frameGeometry, QString::fromLocal8Bit(), QString::fromUtf8(), KWin::Info::geometry, NETSize::height, NETWinInfo::kdeGeometry(), NETWinInfo::mappingState(), KWin::Info::mappingState, KWin::Info::name, NETWinInfo::name(), NETWinInfo::OnAllDesktops, KWin::Info::onAllDesktops, NETWinInfo::pid(), KWin::Info::pid, NETRect::pos, QRect::setRect(), NETRect::size, NETWinInfo::state(), KWin::Info::state, NETWinInfo::strut(), KWin::Info::strut, KWin::Info::visibleName, NETWinInfo::visibleName(), NETSize::width, KWin::Info::win, NETWinInfo::windowType(), KWin::Info::windowType, NETPoint::x, and NETPoint::y.

Referenced by activateWindow(), allowedActionsSupported(), clearState(), currentDesktop(), demandAttention(), forceActiveWindow(), icccmCompliantMappingState(), icon(), lowerWindow(), numberOfDesktops(), raiseWindow(), setActiveWindow(), setCurrentDesktop(), setExtendedStrut(), setIcons(), setOnAllDesktops(), setOnDesktop(), setState(), setStrut(), setSystemTrayWindowFor(), setType(), and setUserTime().

KWin::WindowInfo WId  window,
unsigned long  properties,
unsigned long  properties2
 

Reads all the info about the given window.

Referenced by windowInfo().

bool KWin::valid bool  withdrawn_is_valid = false  )  const
 

Returns false if this window info is not valid (most probably the given window doesn't exist).

Parameters:
withdrawn_is_valid if true, windows in the withdrawn state (i.e. not managed) are also considered. This is usually not the case.

WId KWin::win  )  const
 

Returns the window identifier.

unsigned long KWin::state  )  const
 

Returns the window's state flags (see the NET::State enum for details).

Requires NET::WMState passed to KWin::windowInfo().

bool KWin::hasState unsigned long  s  )  const [inline]
 

Returns true if the window has the given state flag set (see the NET::State enum for details).

Requires NET::WMState passed to KWin::windowInfo().

Since:
3.2.1

Definition at line 540 of file kwin.h.

bool KWin::isMinimized  )  const
 

Returns true if the window is minimized.

Note that it is true only if the window is truly minimized, not shaded or on another virtual desktops, which makes it different from mappingState() == NET::Iconic or QWidget::isMinimized(). Requires NET::WMState and NET::XAWMState passed to KWin::windowInfo().

NET::MappingState KWin::mappingState  )  const
 

Returns the mapping state of the window (see NET::MappingState).

Note that it's very likely that you don't want to use this function, and use isOnDesktop(), isMinimized() etc. instead. Requires NET::XAWMState passed to KWin::windowInfo().

NETExtendedStrut KWin::extendedStrut  )  const
 

Returns the window extended (partial) strut.

Requires NET::WM2ExtendedStrut passed to KWin::windowInfo().

NETStrut KWin::strut  )  const
 

Deprecated:
use extendedStrut() Returns the window strut.
Requires NET::WMStrut passed to KWin::windowInfo().

Referenced by setExtendedStrut(), and setStrut().

NET::WindowType KWin::windowType int  supported_types  )  const
 

Returns the window type of this window (see NET::WindowType).

The argument should be all window types your application supports (see NET::WindowTypeMask). Requires NET::WMWindowType passed to KWin::windowInfo().

QString KWin::visibleName  )  const
 

Returns the visible name of the window (i.e.

including possible <2> appended when there are two or more windows with the same name). Requires NET::WMVisibleName passed to KWin::windowInfo().

QString KWin::visibleNameWithState  )  const
 

Returns a visible name with state.

This is a simple convenience function that returns the visible name but with parentheses around minimized windows. Requires NET::WMVisibleName, NET::WMState and NET::XAWMState passed to KWin::windowInfo().

Returns:
the window name with state

QString KWin::name  )  const
 

Returns the name of the window, as specified by the application, without any modifications.

You should often use visibleName() instead. Requires NET::WMName passed to KWin::windowInfo().

QString KWin::visibleIconName  )  const
 

Returns the visible name of the window that should be shown in taskbar and all other "iconic" representations of the window.

Note that this has nothing to do with normal icons. Requires NET::WMVisibleIconName passed to KWin::windowInfo().

QString KWin::visibleIconNameWithState  )  const
 

Returns a visible name with state.

This is a simple convenience function that returns the visible iconic name but with parentheses around minimized windows. Note that this has nothing to do with normal icons. Requires NET::WMVisibleIconName, NET::WMState and NET::XAWMState passed to KWin::windowInfo().

Returns:
the window iconic name with state

QString KWin::iconName  )  const
 

Returns the name of the window that should be shown in taskbar and all other "iconic" representations of the window.

Note that this has nothing to do with normal icons. Requires NET::WMIconName passed to KWin::windowInfo().

bool KWin::isOnCurrentDesktop  )  const
 

Returns true if the window is on the currently active virtual desktop.

Requires NET::WMDesktop passed to KWin::windowInfo().

bool KWin::isOnDesktop int  desktop  )  const
 

Returns true if the window is on the given virtual desktop.

Requires NET::WMDesktop passed to KWin::windowInfo().

bool KWin::onAllDesktops  )  const
 

Returns true if the window is on all desktops (equal to desktop()==NETOnAllDesktops).

Requires NET::WMDesktop passed to KWin::windowInfo().

int KWin::desktop  )  const
 

Returns the virtual desktop this window is on (NET::OnAllDesktops if the window is on all desktops).

You should prefer using isOnDesktop(). Requires NET::WMDesktop passed to KWin::windowInfo().

QRect KWin::geometry  )  const
 

Returns the position and size of the window contents.

Requires NET::WMGeometry passed to KWin::windowInfo().

QRect KWin::frameGeometry  )  const
 

Returns the frame geometry of the window, i.e.

including the window decoration. Requires NET::WMKDEFrameStrut passed to KWin::windowInfo().

WId KWin::transientFor  )  const
 

Returns the WM_TRANSIENT_FOR property for the window, i.e.

the mainwindow for this window. Requires NET::WM2TransientFor passed to KWin::windowInfo().

WId KWin::groupLeader  )  const
 

Returns the leader window for the group the window is in, if any.

Requires NET::WM2GroupLeader passed to KWin::windowInfo().

QCString KWin::windowClassClass  )  const
 

Returns the class component of the window class for the window (i.e.

WM_CLASS property). Requires NET::WM2WindowClass passed to KWin::windowInfo().

Since:
3.3

QCString KWin::windowClassName  )  const
 

Returns the name component of the window class for the window (i.e.

WM_CLASS property). Requires NET::WM2WindowClass passed to KWin::windowInfo().

Since:
3.3

QCString KWin::windowRole  )  const
 

Returns the window role for the window (i.e.

WM_WINDOW_ROLE property). Requires NET::WM2WindowRole passed to KWin::windowInfo().

Since:
3.3

QCString KWin::clientMachine  )  const
 

Returns the client machine for the window (i.e.

WM_CLIENT_MACHINE property). Requires NET::WMClientMachine passed to KWin::windowInfo().

Since:
3.3

bool KWin::actionSupported NET::Action  action  )  const
 

Returns true if the given action is currently supported for the window by the window manager.

Requires NET::WM2AllowedActions passed to KWin::windowInfo().


The documentation for this class was generated from the following files:
KDE Logo
This file is part of the documentation for kdecore Library Version 3.4.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Mon Jun 12 11:29:03 2006 by doxygen 1.4.4 written by Dimitri van Heesch, © 1997-2003