|  | Home · All Classes · Modules

# QDesignerFormWindowManagerInterface Class Reference
[QtDesigner module]

The QDesignerFormWindowManagerInterface class allows you to manipulate the collection of form windows in Qt Designer, and control Qt Designer's form editing actions. More...

Inherits QObject.

### Methods

- __init__ (self, QObject parent = None)
- QAction actionAdjustSize (self)
- QAction actionBreakLayout (self)
- QAction actionCopy (self)
- QAction actionCut (self)
- QAction actionDelete (self)
- QAction actionFormLayout (self)
- QAction actionGridLayout (self)
- QAction actionHorizontalLayout (self)
- QAction actionLower (self)
- QAction actionPaste (self)
- QAction actionRaise (self)
- QAction actionRedo (self)
- QAction actionSelectAll (self)
- QAction actionSimplifyLayout (self)
- QAction actionSplitHorizontal (self)
- QAction actionSplitVertical (self)
- QAction actionUndo (self)
- QAction actionVerticalLayout (self)
- QDesignerFormWindowInterface activeFormWindow (self)
- addFormWindow (self, QDesignerFormWindowInterface formWindow)
- QDesignerFormEditorInterface core (self)
- QDesignerFormWindowInterface createFormWindow (self, QWidget parent = None, Qt.WindowFlags flags = 0)
- QDesignerFormWindowInterface formWindow (self, int index)
- int formWindowCount (self)
- removeFormWindow (self, QDesignerFormWindowInterface formWindow)
- setActiveFormWindow (self, QDesignerFormWindowInterface formWindow)

### Qt Signals

- void activeFormWindowChanged (QDesignerFormWindowInterface *)
- void formWindowAdded (QDesignerFormWindowInterface *)
- void formWindowRemoved (QDesignerFormWindowInterface *)

## Detailed Description

The QDesignerFormWindowManagerInterface class allows you to manipulate the collection of form windows in Qt Designer, and control Qt Designer's form editing actions.

QDesignerFormWindowManagerInterface is not intended to be instantiated directly. Qt Designer uses the form window manager to control the various form windows in its workspace. You can retrieve an interface to Qt Designer's form window manager using the QDesignerFormEditorInterface.formWindowManager() function. For example:

             QDesignerFormWindowManagerInterface *manager = 0;
             QDesignerFormWindowInterface *formWindow = 0;

             manager = formEditor->formWindowManager();
             formWindow = manager->formWindow(0);

             manager->setActiveFormWindow(formWindow);

When implementing a custom widget plugin, a pointer to Qt Designer's current QDesignerFormEditorInterface object (`formEditor` in the example above) is provided by the QDesignerCustomWidgetInterface.initialize() function's parameter. You must subclass the QDesignerCustomWidgetInterface to expose your plugin to Qt Designer.

The form window manager interface provides the createFormWindow() function that enables you to create a new form window which you can add to the collection of form windows that the manager maintains, using the addFormWindow() slot. It also provides the formWindowCount() function returning the number of form windows currently under the manager's control, the formWindow() function returning the form window associated with a given index, and the activeFormWindow() function returning the currently selected form window. The removeFormWindow() slot allows you to reduce the number of form windows the manager must maintain, and the setActiveFormWindow() slot allows you to change the form window focus in Qt Designer's workspace.

In addition, QDesignerFormWindowManagerInterface contains a collection of functions that enables you to intervene and control Qt Designer's form editing actions. All these functions return the original action, making it possible to propagate the function further after intervention.

Finally, the interface provides three signals which are emitted when a form window is added, when the currently selected form window changes, or when a form window is removed, respectively. All the signals carry the form window in question as their parameter.

## Method Documentation

### QDesignerFormWindowManagerInterface.__init__ (self, QObject parent = None)

The parent argument, if not None, causes self to be owned by Qt instead of PyQt.

Constructs an interface with the given parent for the form window manager.

### QAction QDesignerFormWindowManagerInterface.actionAdjustSize (self)

Allows you to intervene and control Qt Designer's "adjust size" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionBreakLayout (self)

Allows you to intervene and control Qt Designer's "break layout" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionCopy (self)

Allows you to intervene and control Qt Designer's "copy" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionCut (self)

Allows you to intervene and control Qt Designer's "cut" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionDelete (self)

Allows you to intervene and control Qt Designer's "delete" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionFormLayout (self)

Allows you to intervene and control Qt Designer's "form layout" action. The function returns the original action.

FormWindowManagerPrivateMap *fwmpm = g_FormWindowManagerPrivateMap();

This function was introduced in Qt 4.4.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionGridLayout (self)

Allows you to intervene and control a request for grid layout for a form window in Qt Designer's workspace. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionHorizontalLayout (self)

Allows you to intervene and control a request for horizontal layout for a form window in Qt Designer's workspace. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionLower (self)

Allows you to intervene and control the action of lowering a form window in Qt Designer's workspace. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionPaste (self)

Allows you to intervene and control Qt Designer's "paste" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionRaise (self)

The QAction result

Allows you to intervene and control the action of raising of a form window in Qt Designer's workspace. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionRedo (self)

Allows you to intervene and control Qt Designer's "redo" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionSelectAll (self)

Allows you to intervene and control Qt Designer's "select all" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionSimplifyLayout (self)

Allows you to intervene and control Qt Designer's "simplify layout" action. The function returns the original action.

This function was introduced in Qt 4.4.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionSplitHorizontal (self)

Allows you to intervene and control Qt Designer's "split horizontal" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionSplitVertical (self)

Allows you to intervene and control Qt Designer's "split vertical" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionUndo (self)

Allows you to intervene and control Qt Designer's "undo" action. The function returns the original action.

See also QAction.

### QAction QDesignerFormWindowManagerInterface.actionVerticalLayout (self)

Allows you to intervene and control a request for vertical layout for a form window in Qt Designer's workspace. The function returns the original action.

See also QAction.

### QDesignerFormWindowInterface QDesignerFormWindowManagerInterface.activeFormWindow (self)

Returns the currently active form window in Qt Designer's workspace.

See also setActiveFormWindow() and removeFormWindow().

### QDesignerFormWindowManagerInterface.addFormWindow (self, QDesignerFormWindowInterface formWindow)

This method is also a Qt slot with the C++ signature `void addFormWindow(QDesignerFormWindowInterface *)`.

Adds the given formWindow to the collection of windows that Qt Designer's form window manager maintains.

See also formWindowAdded().

### QDesignerFormEditorInterface QDesignerFormWindowManagerInterface.core (self)

Returns a pointer to Qt Designer's current QDesignerFormEditorInterface object.

### QDesignerFormWindowInterface QDesignerFormWindowManagerInterface.createFormWindow (self, QWidget parent = None, Qt.WindowFlags flags = 0)

The parent argument, if not None, causes self to be owned by Qt instead of PyQt.

Creates a form window with the given parent and the given window flags.

See also addFormWindow().

### QDesignerFormWindowInterface QDesignerFormWindowManagerInterface.formWindow (self, int index)

Returns the form window at the given index.

See also setActiveFormWindow() and removeFormWindow().

### int QDesignerFormWindowManagerInterface.formWindowCount (self)

Returns the number of form windows maintained by Qt Designer's form window manager.

### QDesignerFormWindowManagerInterface.removeFormWindow (self, QDesignerFormWindowInterface formWindow)

This method is also a Qt slot with the C++ signature `void removeFormWindow(QDesignerFormWindowInterface *)`.

Removes the given formWindow from the collection of windows that Qt Designer's form window manager maintains.

See also formWindow() and formWindowRemoved().

### QDesignerFormWindowManagerInterface.setActiveFormWindow (self, QDesignerFormWindowInterface formWindow)

This method is also a Qt slot with the C++ signature `void setActiveFormWindow(QDesignerFormWindowInterface *)`.

Sets the given formWindow to be the currently active form window in Qt Designer's workspace.

See also activeFormWindow() and activeFormWindowChanged().

## Qt Signal Documentation

### void activeFormWindowChanged (QDesignerFormWindowInterface *)

This is the default overload of this signal.

This signal is emitted when the contents of the currently active form window in Qt Designer's workspace changed. A pointer to the currently active formWindow is passed as an argument.

See also activeFormWindow().

### void formWindowAdded (QDesignerFormWindowInterface *)

This is the default overload of this signal.

This signal is emitted when a new form window is added to the collection of windows that Qt Designer's form window manager maintains. A pointer to the new formWindow is passed as an argument.

See also addFormWindow() and setActiveFormWindow().

### void formWindowRemoved (QDesignerFormWindowInterface *)

This is the default overload of this signal.

This signal is emitted when a form window is removed from the collection of windows that Qt Designer's form window manager maintains. A pointer to the removed formWindow is passed as an argument.

See also removeFormWindow().