Home | All Classes | Main Classes | Annotated | Grouped Classes | Functions |

# Workspace Module

## Overview

The workspace module provides all the facilities needed to allow developers to create a Multiple Document Interface (MDI) for their applications. This kind of user interface provides the user with a single workspace window that represents the application's documents as decorated child windows. MDI environments are typically seen in integrated environments for software development, but can be applied to almost any project-based working environment. For example, Qt Object Inspector uses a workspace to organize information about running Qt applications.

Any standard Qt widget can be inserted into a workspace and used as a document window, from simple functional widgets such as labels and frames to more sophisticated containers such as icon views, list views, and even other workspaces.

Child windows can be managed easily, especially when the workspace is used with the Window Menu from Qt Solutions.

## Details

Workspaces in Qt are implemented in the QWorkspace class, a dervied class of QWidget. Workspace widgets can be added to any container widgets that accept QWidgets, making it easy to add MDI functionality to an application.

Standard Qt widgets are added to the workspace to become child windows. These child widgets can either be created with the workspace as their parent, or reparented into the workspace from elsewhere.

A workspace manages the layout of its child widgets in a different way to that of other container widgets, like QHBox, QVBox, and QGrid. The user can freely arrange the child windows within the workspace, and functions also exist to tidy the windows into cascaded and tiled arrangements. Child windows can be maximized, minimized, and restored by the user just like normal top-level widgets; functions also exist to achieve this from within the application. In the common case, when used as the central widget of a main window, workspaces can take advantage of the main window's menu bar to provide maximized child windows with window furniture.

Workspaces can be made to automatically provide scrollbars, so that the user can access all child windows if the required workspace area exceeds the visible size of the workspace.

Please see the class documentation for further details.