![]() |
| ||
Classes - Annotated - Tree - Functions - Home - Structure |
The QDesktopWidget class provides an API to access the screen information on multi-head systems. More...
#include <qdesktopwidget.h>
Inherits QWidget.
Systems with more than one graphics card and monitor can manage the screen space available either as multiple desktops, or as a big virtual desktop, which usually has the size of the bounding rectangle of all screens.
For an application, one of the available screens is the primary screen - e.g. the screen where the main widget resides. All windows opened in the context of this application have to be constrained to the boundaries of this screen - it would be awkward if e.g. a dialog box would open up on a different screen, or in the middle of two screens.
The QDesktopWidget provides the information about the geometry of the available screens. Widgets provided by Qt use this class to place e.g. tooltips, menus or dialog boxes according to the parent- or application widget.
Applications can use this class to e.g. save window positions, or to align child widgets to one screen.
For virtual desktops, screen will always return the same widget. The size of the virtual desktop is the size of this desktop widget.
See also primaryScreen().
See also numScreens().
QPainter paint( QApplication::desktop()->screen( 0 ), TRUE ); paint.draw... ... paint.end();
If the system uses a virtual desktop, the returned widget will have the geometry of the desktop for every screen.
See also primaryScreen(), numScreens() and isVirtualDesktop().
See also screenNumber().
See also primaryScreen().
See also primaryScreen().
Search the documentation, FAQ, qt-interest archive and more (uses
www.trolltech.com):
This file is part of the Qt toolkit, copyright © 1995-2000 Trolltech, all rights reserved.
Copyright © 2000 Trolltech | Trademarks | Qt version main-beta1
|