1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156
|
'\" t
.TH QWSDecoration 3qt "18 March 2002" "Trolltech AS" \" -*- nroff -*-
.\" Copyright 1992-2001 Trolltech AS. All rights reserved. See the
.\" license file included in the distribution for a complete license
.\" statement.
.\"
.ad l
.nh
.SH NAME
QWSDecoration \- Allows the appearance of the Qt/Embedded Window Manager to be customized
.SH SYNOPSIS
\fC#include <qwsdecoration_qws.h>\fR
.PP
.SS "Public Members"
.in +1c
.ti -1c
.BI "\fBQWSDecoration\fR ()"
.br
.ti -1c
.BI "virtual \fB~QWSDecoration\fR ()"
.br
.ti -1c
.BI "enum \fBRegion\fR { None = 0, All = 1, Title = 2, Top = 3, Bottom = 4, Left = 5, Right = 6, TopLeft = 7, TopRight = 8, BottomLeft = 9, BottomRight = 10, Close = 11, Minimize = 12, Maximize = 13, Normalize = 14, Menu = 15, LastRegion = Menu }"
.br
.ti -1c
.BI "virtual QRegion \fBregion\fR ( const QWidget * widget, const QRect & rect, Region type = All ) = 0"
.br
.ti -1c
.BI "virtual void \fBclose\fR ( QWidget * widget )"
.br
.ti -1c
.BI "virtual void \fBminimize\fR ( QWidget * widget )"
.br
.ti -1c
.BI "virtual void \fBmaximize\fR ( QWidget * widget )"
.br
.ti -1c
.BI "virtual QPopupMenu * \fBmenu\fR ( const QWidget *, const QPoint & )"
.br
.ti -1c
.BI "virtual void \fBpaint\fR ( QPainter * painter, const QWidget * widget ) = 0"
.br
.ti -1c
.BI "virtual void \fBpaintButton\fR ( QPainter * painter, const QWidget * widget, Region type, int state ) = 0"
.br
.in -1c
.SH DESCRIPTION
The QWSDecoration class allows the appearance of the Qt/Embedded Window Manager to be customized.
.PP
Qt/Embedded provides window management to top level windows. The appearance of the borders and buttons (the decoration) around the managed windows can be customized by creating your own class derived from QWSDecoration and overriding a few methods.
.PP
This class is non-portable. It is available \fIonly\fR in Qt/Embedded.
.PP
See also QApplication::qwsSetDecoration() and Qt/Embedded.
.SS "Member Type Documentation"
.SH "QWSDecoration::Region"
This enum describes the regions in the window decorations.
.TP
\fCQWSDecoration::None\fR - used internally.
.TP
\fCQWSDecoration::All\fR - the entire region used by the window decoration.
.TP
\fCQWSDecoration::Title\fR - Displays the window title and allows the window to be moved by dragging.
.TP
\fCQWSDecoration::Top\fR - allows the top of the window to be resized.
.TP
\fCQWSDecoration::Bottom\fR - allows the bottom of the window to be resized.
.TP
\fCQWSDecoration::Left\fR - allows the left edge of the window to be resized.
.TP
\fCQWSDecoration::Right\fR - allows the right edge of the window to be resized.
.TP
\fCQWSDecoration::TopLeft\fR - allows the top-left of the window to be resized.
.TP
\fCQWSDecoration::TopRight\fR - allows the top-right of the window to be resized.
.TP
\fCQWSDecoration::BottomLeft\fR - allows the bottom-left of the window to be resized.
.TP
\fCQWSDecoration::BottomRight\fR - allows the bottom-right of the window to be resized.
.TP
\fCQWSDecoration::Close\fR - clicking in this region closes the window.
.TP
\fCQWSDecoration::Minimize\fR - clicking in this region minimizes the window.
.TP
\fCQWSDecoration::Maximize\fR - clicking in this region maximizes the window.
.TP
\fCQWSDecoration::Normalize\fR - returns a maximized window to previous size.
.TP
\fCQWSDecoration::Menu\fR - clicking in this region opens the window operations menu.
.SH MEMBER FUNCTION DOCUMENTATION
.SH "QWSDecoration::QWSDecoration ()"
Constructs a decorator.
.SH "QWSDecoration::~QWSDecoration ()\fC [virtual]\fR"
Destroys a decorator.
.SH "void QWSDecoration::close ( QWidget * widget )\fC [virtual]\fR"
Called when the user clicks in the Close region.
.PP
\fIwidget\fR is the QWidget to be closed.
.PP
The default behaviour is to close the widget.
.SH "void QWSDecoration::maximize ( QWidget * widget )\fC [virtual]\fR"
Called when the user clicks in the Maximize region.
.PP
\fIwidget\fR is the QWidget to be maximized.
.PP
The default behaviour is to resize the widget to be full-screen. This method can be overridden to, e.g. avoid launch panels.
.SH "QPopupMenu * QWSDecoration::menu ( const QWidget *, const QPoint & )\fC [virtual]\fR"
Called to create a QPopupMenu containing the valid menu operations.
.PP
The default implementation adds all possible window operations.
.SH "void QWSDecoration::minimize ( QWidget * widget )\fC [virtual]\fR"
Called when the user clicks in the Minimize region.
.PP
\fIwidget\fR is the QWidget to be minimized.
.PP
The default behaviour is to ignore this action.
.SH "void QWSDecoration::paint ( QPainter * painter, const QWidget * widget )\fC [pure virtual]\fR"
Override to paint the border and title decoration around \fIwidget\fR using \fIpainter\fR.
.SH "void QWSDecoration::paintButton ( QPainter * painter, const QWidget * widget, Region type, int state )\fC [pure virtual]\fR"
Override to paint a button \fItype\fR using \fIpainter\fR.
.PP
\fIwidget\fR is the widget whose button is to be drawn. \fIstate\fR is the state of the button. It can be a combination of the following ORed together:
.TP
\fCQWSButton::MouseOver\fR
.TP
\fCQWSButton::Clicked\fR
.TP
\fCQWSButton::On\fR
.SH "QRegion QWSDecoration::region ( const QWidget * widget, const QRect & rect, Region type = All )\fC [pure virtual]\fR"
Returns the requested region \fItype\fR which will contain \fIwidget\fR
with geometry \fIrect\fR.
.SH "SEE ALSO"
.BR http://doc.trolltech.com/qwsdecoration.html
.BR http://www.trolltech.com/faq/tech.html
.SH COPYRIGHT
Copyright 1992-2001 Trolltech AS, http://www.trolltech.com. See the
license file included in the distribution for a complete license
statement.
.SH AUTHOR
Generated automatically from the source code.
.SH BUGS
If you find a bug in Qt, please report it as described in
.BR http://doc.trolltech.com/bughowto.html .
Good bug reports help us to help you. Thank you.
.P
The definitive Qt documentation is provided in HTML format; it is
located at $QTDIR/doc/html and can be read using Qt Assistant or with
a web browser. This man page is provided as a convenience for those
users who prefer man pages, although this format is not officially
supported by Trolltech.
.P
If you find errors in this manual page, please report them to
.BR qt-bugs@trolltech.com .
Please include the name of the manual page (qwsdecoration.3qt) and the Qt
version (3.0.3).
|