superkaramba
Task Class Reference
#include <taskmanager.h>

Detailed Description
A dynamic interface to a task (main window).
- See also:
- TaskManager
KWinModule
Definition at line 73 of file taskmanager.h.
Public Types | |
| typedef QMap< WId, Task::TaskPtr > | Dict |
| typedef QVector< Task::TaskPtr > | List |
| typedef KSharedPtr< Task > | TaskPtr |
Public Slots | |
| void | activate () |
| void | activateRaiseOrIconify () |
| void | close () |
| void | lower () |
| void | move () |
| void | publishIconGeometry (QRect) |
| void | raise () |
| void | resize () |
| void | restore () |
| void | setAlwaysOnTop (bool) |
| void | setFullScreen (bool) |
| void | setIconified (bool) |
| void | setKeptBelowOthers (bool) |
| void | setMaximized (bool) |
| void | setShaded (bool) |
| void | toCurrentDesktop () |
| void | toDesktop (int) |
| void | toggleAlwaysOnTop () |
| void | toggleFullScreen () |
| void | toggleIconified () |
| void | toggleKeptBelowOthers () |
| void | toggleMaximized () |
| void | toggleShaded () |
| void | updateThumbnail () |
Signals | |
| void | activated () |
| void | changed () |
| void | deactivated () |
| void | iconChanged () |
| void | thumbnailChanged () |
Public Member Functions | |
| void | addTransient (WId w, const NETWinInfo &info) |
| QPixmap | bestIcon (int size, bool &isStaticIcon) |
| QString | classClass () |
| QString | className () |
| bool | demandsAttention () const |
| int | desktop () const |
| QRect | geometry () const |
| bool | hasThumbnail () const |
| bool | hasTransient (WId w) const |
| QPixmap | icon (int width, int height, bool allowResize=false) |
| KWindowInfo | info () const |
| bool | isActive () const |
| bool | isAlwaysOnTop () const |
| bool | isFullScreen () const |
| bool | isIconified () const |
| bool | isKeptBelowOthers () const |
| bool | isMaximized () const |
| bool | isMinimized () const |
| bool | isModified () const |
| bool | isOnAllDesktops () const |
| bool | isOnCurrentDesktop () const |
| bool | isOnScreen (int screen) const |
| bool | isOnTop () const |
| bool | isShaded () const |
| QString | name () const |
| QPixmap | pixmap () const |
| void | refresh (unsigned int dirty) |
| void | refreshIcon () |
| void | removeTransient (WId w) |
| void | setActive (bool a) |
| void | setThumbnailSize (double size) |
| bool | showInPager () const |
| bool | showInTaskbar () const |
| Task (WId win, QObject *parent, const char *name=0) | |
| QPixmap | thumbnail (int maxDimension) |
| const QPixmap & | thumbnail () const |
| double | thumbnailSize () const |
| WindowList | transients () const |
| void | updateDemandsAttentionState (WId w) |
| void | updateWindowPixmap () |
| QString | visibleName () const |
| QString | visibleNameWithState () const |
| WId | window () const |
| virtual | ~Task () |
Static Public Member Functions | |
| static bool | idMatch (const QString &, const QString &) |
Protected Slots | |
| void | generateThumbnail () |
Protected Member Functions | |
| void | findWindowFrameId () |
Properties | |
| bool | active |
| bool | alwaysOnTop |
| bool | demandsAttention |
| int | desktop |
| bool | hasThumbnail |
| bool | iconified |
| bool | maximized |
| bool | minimized |
| bool | modified |
| QString | name |
| bool | onAllDesktops |
| bool | onCurrentDesktop |
| QPixmap | pixmap |
| bool | shaded |
| QPixmap | thumbnail |
| double | thumbnailSize |
| QString | visibleName |
| QString | visibleNameWithState |
Member Typedef Documentation
| typedef QMap<WId, Task::TaskPtr> Task::Dict |
Definition at line 99 of file taskmanager.h.
| typedef QVector<Task::TaskPtr> Task::List |
Definition at line 98 of file taskmanager.h.
| typedef KSharedPtr<Task> Task::TaskPtr |
Definition at line 97 of file taskmanager.h.
Constructor & Destructor Documentation
| Task::Task | ( | WId | win, | |
| QObject * | parent, | |||
| const char * | name = 0 | |||
| ) |
Definition at line 552 of file taskmanager.cpp.
| Task::~Task | ( | ) | [virtual] |
Definition at line 597 of file taskmanager.cpp.
Member Function Documentation
| void Task::activate | ( | ) | [slot] |
| void Task::activated | ( | ) | [signal] |
Indicates that this task is now the active task.
| void Task::activateRaiseOrIconify | ( | ) | [slot] |
Perform the action that is most appropriate for this task.
If it is not active, activate it. Else if it is not the top window, raise it. Otherwise, iconify it.
Definition at line 1068 of file taskmanager.cpp.
| void Task::addTransient | ( | WId | w, | |
| const NETWinInfo & | info | |||
| ) |
Definition at line 775 of file taskmanager.cpp.
| QPixmap Task::bestIcon | ( | int | size, | |
| bool & | isStaticIcon | |||
| ) |
Returns the best icon for any of the KIconLoader::StdSizes.
If there is no icon of the specified size specified in the WM hints, it will try to get one using KIconLoader.
bool gotStaticIcon; QPixmap icon = myTask->icon( KIconLoader::SizeMedium, gotStaticIcon );
- Parameters:
-
size Any of the constants in KIconLoader::StdSizes. isStaticIcon Set to true if KIconLoader was used, false otherwise.
Definition at line 833 of file taskmanager.cpp.
| void Task::changed | ( | ) | [signal] |
Indicates that this task has changed in some way.
| QString Task::classClass | ( | ) |
Definition at line 802 of file taskmanager.cpp.
| QString Task::className | ( | ) |
| void Task::close | ( | ) | [slot] |
| void Task::deactivated | ( | ) | [signal] |
Indicates that this task is no longer the active task.
| bool Task::demandsAttention | ( | ) | const |
Returns true if the task is not active but demands user's attention.
| int Task::desktop | ( | ) | const [inline] |
Returns the desktop on which this task's window resides.
Definition at line 251 of file taskmanager.h.
| void Task::findWindowFrameId | ( | ) | [protected] |
Definition at line 610 of file taskmanager.cpp.
| void Task::generateThumbnail | ( | ) | [protected, slot] |
Definition at line 1207 of file taskmanager.cpp.
| QRect Task::geometry | ( | ) | const [inline] |
| bool Task::hasThumbnail | ( | ) | const [inline] |
Returns true if this task has a thumbnail.
Note that this method can only ever return true after a call to updateThumbnail().
Definition at line 335 of file taskmanager.h.
| bool Task::hasTransient | ( | WId | w | ) | const [inline] |
Definition at line 302 of file taskmanager.h.
| QPixmap Task::icon | ( | int | width, | |
| int | height, | |||
| bool | allowResize = false | |||
| ) |
Tries to find an icon for the task with the specified size.
If there is no icon that matches then it will either resize the closest available icon or return a null pixmap depending on the value of allowResize.
Note that the last icon is cached, so a sequence of calls with the same parameters will only query the NET properties if the icon has changed or none was found.
Definition at line 814 of file taskmanager.cpp.
| void Task::iconChanged | ( | ) | [signal] |
Indicates that the icon for this task has changed.
Returns true iff the windows with the specified ids should be grouped together in the task list.
Definition at line 906 of file taskmanager.cpp.
| KWindowInfo Task::info | ( | ) | const [inline] |
Definition at line 108 of file taskmanager.h.
| bool Task::isActive | ( | ) | const |
Returns true if the task's window is the active window.
Definition at line 729 of file taskmanager.cpp.
| bool Task::isAlwaysOnTop | ( | ) | const |
Returns true if the task's window will remain at the top of the stacking order.
Definition at line 699 of file taskmanager.cpp.
| bool Task::isFullScreen | ( | ) | const |
Returns true if the task's window is in full screen mode.
Definition at line 709 of file taskmanager.cpp.
| bool Task::isIconified | ( | ) | const |
- Deprecated:
- Returns true if the task's window is minimized(iconified).
Definition at line 694 of file taskmanager.cpp.
| bool Task::isKeptBelowOthers | ( | ) | const |
Returns true if the task's window will remain at the bottom of the stacking order.
Definition at line 704 of file taskmanager.cpp.
| bool Task::isMaximized | ( | ) | const |
| bool Task::isMinimized | ( | ) | const |
| bool Task::isModified | ( | ) | const |
Returns true if the document the task is editing has been modified.
This is currently handled heuristically by looking for the string '[i18n_modified]' in the window title where i18n_modified is the word 'modified' in the current language.
Definition at line 739 of file taskmanager.cpp.
| bool Task::isOnAllDesktops | ( | ) | const |
Returns true if the task's window is on all virtual desktops.
Definition at line 724 of file taskmanager.cpp.
| bool Task::isOnCurrentDesktop | ( | ) | const |
Returns true if the task's window is on the current virtual desktop.
Definition at line 719 of file taskmanager.cpp.
| bool Task::isOnScreen | ( | int | screen | ) | const |
Returns true if the window is on the specified screen of a multihead configuration.
Definition at line 755 of file taskmanager.cpp.
| bool Task::isOnTop | ( | ) | const |
Returns true if the task's window is the topmost non-iconified, non-always-on-top window.
Definition at line 734 of file taskmanager.cpp.
| bool Task::isShaded | ( | ) | const |
| void Task::lower | ( | ) | [slot] |
| void Task::move | ( | ) | [slot] |
| QString Task::name | ( | ) | const [inline] |
Definition at line 121 of file taskmanager.h.
| QPixmap Task::pixmap | ( | ) | const [inline] |
Returns a 16x16 (KIconLoader::Small) icon for the task.
This method will only fall back to a static icon if there is no icon of any size in the WM hints.
Definition at line 142 of file taskmanager.h.
| void Task::publishIconGeometry | ( | QRect | rect | ) | [slot] |
This method informs the window manager of the location at which this task will be displayed when iconised.
It is used, for example by the KWindowSystem inconify animation.
Definition at line 1162 of file taskmanager.cpp.
| void Task::raise | ( | ) | [slot] |
| void Task::refresh | ( | unsigned int | dirty | ) |
Definition at line 662 of file taskmanager.cpp.
| void Task::refreshIcon | ( | ) |
Definition at line 639 of file taskmanager.cpp.
| void Task::removeTransient | ( | WId | w | ) |
Definition at line 784 of file taskmanager.cpp.
| void Task::resize | ( | ) | [slot] |
| void Task::restore | ( | ) | [slot] |
Restore the main window of the task (if it was iconified).
Definition at line 994 of file taskmanager.cpp.
| void Task::setActive | ( | bool | a | ) |
Definition at line 674 of file taskmanager.cpp.
| void Task::setAlwaysOnTop | ( | bool | stay | ) | [slot] |
If true, the task's window will remain at the top of the stacking order.
Definition at line 1102 of file taskmanager.cpp.
| void Task::setFullScreen | ( | bool | fullscreen | ) | [slot] |
If true, the task's window will enter full screen mode.
Definition at line 1132 of file taskmanager.cpp.
| void Task::setIconified | ( | bool | iconify | ) | [slot] |
| void Task::setKeptBelowOthers | ( | bool | below | ) | [slot] |
If true, the task's window will remain at the bottom of the stacking order.
Definition at line 1116 of file taskmanager.cpp.
| void Task::setMaximized | ( | bool | maximize | ) | [slot] |
| void Task::setShaded | ( | bool | shade | ) | [slot] |
If true then the task's window will be shaded.
Most window managers represent this state by displaying on the window's title bar.
Definition at line 1148 of file taskmanager.cpp.
| void Task::setThumbnailSize | ( | double | size | ) | [inline] |
Sets the size for the window thumbnail.
For example a size of 0.2 indicates the thumbnail will be 20% of the original window size.
Definition at line 326 of file taskmanager.h.
| bool Task::showInPager | ( | ) | const [inline] |
Returns true if the task should be shown in pager-like apps.
Definition at line 278 of file taskmanager.h.
| bool Task::showInTaskbar | ( | ) | const [inline] |
Returns true if the task should be shown in taskbar-like apps.
Definition at line 270 of file taskmanager.h.
| QPixmap Task::thumbnail | ( | int | maxDimension | ) |
Definition at line 1306 of file taskmanager.cpp.
| const QPixmap& Task::thumbnail | ( | ) | const [inline] |
Returns the thumbnail for this task (or a null image if there is none).
Definition at line 344 of file taskmanager.h.
| void Task::thumbnailChanged | ( | ) | [signal] |
Indicates that the thumbnail for this task has changed.
| double Task::thumbnailSize | ( | ) | const [inline] |
| void Task::toCurrentDesktop | ( | ) | [slot] |
Moves the task's window to the current virtual desktop.
Definition at line 1097 of file taskmanager.cpp.
| void Task::toDesktop | ( | int | desk | ) | [slot] |
Moves the task's window to the specified virtual desktop.
Definition at line 1079 of file taskmanager.cpp.
| void Task::toggleAlwaysOnTop | ( | ) | [slot] |
Definition at line 1111 of file taskmanager.cpp.
| void Task::toggleFullScreen | ( | ) | [slot] |
Definition at line 1143 of file taskmanager.cpp.
| void Task::toggleIconified | ( | ) | [slot] |
Definition at line 1035 of file taskmanager.cpp.
| void Task::toggleKeptBelowOthers | ( | ) | [slot] |
Definition at line 1127 of file taskmanager.cpp.
| void Task::toggleMaximized | ( | ) | [slot] |
Definition at line 989 of file taskmanager.cpp.
| void Task::toggleShaded | ( | ) | [slot] |
Definition at line 1157 of file taskmanager.cpp.
| WindowList Task::transients | ( | ) | const [inline] |
A list of the window ids of all transient windows (dialogs) associated with this task.
Definition at line 132 of file taskmanager.h.
| void Task::updateDemandsAttentionState | ( | WId | w | ) |
Definition at line 760 of file taskmanager.cpp.
| void Task::updateThumbnail | ( | ) | [slot] |
Tells the task to generate a new thumbnail.
When the thumbnail is ready the thumbnailChanged() signal will be emitted.
Definition at line 1181 of file taskmanager.cpp.
| void Task::updateWindowPixmap | ( | ) |
Definition at line 1312 of file taskmanager.cpp.
| QString Task::visibleName | ( | ) | const [inline] |
Definition at line 113 of file taskmanager.h.
| QString Task::visibleNameWithState | ( | ) | const [inline] |
Definition at line 117 of file taskmanager.h.
| WId Task::window | ( | ) | const [inline] |
Definition at line 104 of file taskmanager.h.
Property Documentation
bool Task::active [read] |
Definition at line 85 of file taskmanager.h.
bool Task::alwaysOnTop [read, write] |
Definition at line 88 of file taskmanager.h.
bool Task::demandsAttention [read] |
Definition at line 90 of file taskmanager.h.
int Task::desktop [read] |
Definition at line 91 of file taskmanager.h.
bool Task::hasThumbnail [read] |
Definition at line 93 of file taskmanager.h.
bool Task::iconified [read] |
Definition at line 83 of file taskmanager.h.
bool Task::maximized [read] |
Definition at line 80 of file taskmanager.h.
bool Task::minimized [read] |
Definition at line 81 of file taskmanager.h.
bool Task::modified [read] |
Definition at line 89 of file taskmanager.h.
QString Task::name [read] |
Definition at line 77 of file taskmanager.h.
bool Task::onAllDesktops [read] |
Definition at line 87 of file taskmanager.h.
bool Task::onCurrentDesktop [read] |
Definition at line 86 of file taskmanager.h.
QPixmap Task::pixmap [read] |
Definition at line 79 of file taskmanager.h.
bool Task::shaded [read, write] |
Definition at line 84 of file taskmanager.h.
QPixmap Task::thumbnail [read] |
Definition at line 94 of file taskmanager.h.
double Task::thumbnailSize [read, write] |
Definition at line 92 of file taskmanager.h.
QString Task::visibleName [read] |
Definition at line 76 of file taskmanager.h.
QString Task::visibleNameWithState [read] |
Definition at line 78 of file taskmanager.h.
The documentation for this class was generated from the following files:
KDE 4.2 API Reference