| Classes - Annotated - Tree - Functions - Home - Structure

# QSemiModal Class Reference

The QSemiModal class is the base class of semi-modal dialog windows. More...

`#include <qsemimodal.h>`

Inherits QWidget.

Inherited by QProgressDialog.

List of all member functions.

## Public Members

- QSemiModal ( QWidget * parent=0, const char * name=0, bool modal=FALSE, WFlags f=0 )
- ~QSemiModal ()
- virtual void show ()
- virtual void move ( int x, int y )
- void move ( const QPoint & p )
- virtual void resize ( int w, int h )
- void resize ( const QSize & )
- virtual void setGeometry ( int x, int y, int w, int h )
- virtual void setGeometry ( const QRect & )

## Detailed Description

The QSemiModal class is the base class of semi-modal dialog windows.

The semi-modal dialog window can disable events to other windows while it is open. To enable this, the QSemiModal must be constructed with TRUE for the modal argument, which is FALSE by default, for consistency with QDialog. Such a QSemiModal is modal like QDialog, but it does not have its own event loop. The flow of control is still within your code and it is up to you to update the semi-modal dialog (for example a progressbar) from time to time.

Note that the parent widget has a different meaning for dialogs than for other types of widgets. A dialog is placed on top of the parent widget. The dialog is centered on the screen if the parent widget is zero.

## Member Function Documentation

### QSemiModal::QSemiModal ( QWidget * parent=0, const char * name=0, bool modal=FALSE, WFlags f=0 )

Constructs a semi-modal dialog named name, which has a parent widget parent. If modal is FALSE (the default), the only behavior different to a QWidget is automatic sizing and positioning.

### QSemiModal::~QSemiModal ()

Destructs the widget, deleting all its children.

### void QSemiModal::move ( const QPoint & p )

Reimplements QWidget::move() for internal purposes.

### void QSemiModal::move ( int x, int y ) `[virtual]`

Reimplements QWidget::move() for internal purposes.

Reimplemented from QWidget.

### void QSemiModal::resize ( const QSize & s )

Reimplements QWidget::resize() for internal purposes.

### void QSemiModal::resize ( int w, int h ) `[virtual]`

Reimplements QWidget::resize() for internal purposes.

Reimplemented from QWidget.

### void QSemiModal::setGeometry ( const QRect & r ) `[virtual]`

Reimplements QWidget::setGeometry() for internal purposes.

### void QSemiModal::setGeometry ( int x, int y, int w, int h ) `[virtual]`

Reimplements QWidget::setGeometry() for internal purposes.

### void QSemiModal::show () `[virtual]`

Shows the widget. This implementation also does automatic resizing and automatic positioning. If you have not already resized or moved the dialog, it will find a size that fits the contents and a position near the middle of the screen (or centered relative to the parent widget if any).

Reimplemented from QWidget.

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.