source: trunk/doc/html/qmotifdialog.html@ 203

Last change on this file since 203 was 190, checked in by rudi, 14 years ago

reference documentation added

File size: 12.5 KB
Line 
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2<!-- /home/espenr/tmp/qt-3.3.8-espenr-2499/qt-x11-free-3.3.8/extensions/motif/src/qmotifdialog.cpp:167 -->
3<html>
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
6<title>QMotifDialog Class</title>
7<style type="text/css"><!--
8fn { margin-left: 1cm; text-indent: -1cm; }
9a:link { color: #004faf; text-decoration: none }
10a:visited { color: #672967; text-decoration: none }
11body { background: #ffffff; color: black; }
12--></style>
13</head>
14<body>
15
16<table border="0" cellpadding="0" cellspacing="0" width="100%">
17<tr bgcolor="#E5E5E5">
18<td valign=center>
19 <a href="index.html">
20<font color="#004faf">Home</font></a>
21 | <a href="classes.html">
22<font color="#004faf">All&nbsp;Classes</font></a>
23 | <a href="mainclasses.html">
24<font color="#004faf">Main&nbsp;Classes</font></a>
25 | <a href="annotated.html">
26<font color="#004faf">Annotated</font></a>
27 | <a href="groups.html">
28<font color="#004faf">Grouped&nbsp;Classes</font></a>
29 | <a href="functions.html">
30<font color="#004faf">Functions</font></a>
31</td>
32<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>QMotifDialog Class Reference</h1>
33
34<p>The QMotifDialog class provides the QDialog API for Motif-based dialogs.
35<a href="#details">More...</a>
36<p>This class is part of the <b>Qt Motif Extension</b>.
37<p><tt>#include &lt;<a href="qmotifdialog-h.html">qmotifdialog.h</a>&gt;</tt>
38<p>Inherits <a href="qdialog.html">QDialog</a>.
39<p><a href="qmotifdialog-members.html">List of all member functions.</a>
40<h2>Public Members</h2>
41<ul>
42<li class=fn>enum DialogType { Prompt, Selection, Command, FileSelection, Template, Error, Information, Message, Question, Warning, Working } &nbsp;<em>(obsolete)</em></li>
43<li class=fn>QMotifDialog ( DialogType&nbsp;dialogtype, Widget&nbsp;parent, ArgList&nbsp;args = NULL, Cardinal&nbsp;argcount = 0, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 ) &nbsp;<em>(obsolete)</em></li>
44<li class=fn>QMotifDialog ( Widget&nbsp;parent, ArgList&nbsp;args = NULL, Cardinal&nbsp;argcount = 0, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 ) &nbsp;<em>(obsolete)</em></li>
45<li class=fn><a href="#QMotifDialog-3"><b>QMotifDialog</b></a> ( Widget&nbsp;parent, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 )</li>
46<li class=fn><a href="#QMotifDialog-4"><b>QMotifDialog</b></a> ( QWidget&nbsp;*&nbsp;parent, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 )</li>
47<li class=fn>virtual <a href="#~QMotifDialog"><b>~QMotifDialog</b></a> ()</li>
48<li class=fn>Widget <a href="#shell"><b>shell</b></a> () const</li>
49<li class=fn>Widget <a href="#dialog"><b>dialog</b></a> () const</li>
50</ul>
51<h2>Static Public Members</h2>
52<ul>
53<li class=fn>void <a href="#acceptCallback"><b>acceptCallback</b></a> ( Widget, XtPointer&nbsp;client_data, XtPointer )</li>
54<li class=fn>void <a href="#rejectCallback"><b>rejectCallback</b></a> ( Widget, XtPointer&nbsp;client_data, XtPointer )</li>
55</ul>
56<hr><a name="details"></a><h2>Detailed Description</h2>
57<p> This class is defined in the <b>Qt <a href="motif-extension.html#Motif">Motif</a> Extension</b>, which can be found in the <tt>qt/extensions</tt> directory. It is not included in the main Qt API.
58<p>
59
60The QMotifDialog class provides the <a href="qdialog.html">QDialog</a> API for Motif-based dialogs.
61
62<p>
63<p> QMotifDialog provides two separate modes of operation. The
64application programmer can use QMotifDialog with an existing
65Motif-based dialog and a <a href="qwidget.html">QWidget</a> parent, or the application
66programmer can use QMotifDialog with a custom Qt-based dialog and
67a Motif-based parent. Modality continues to work as expected.
68<p> Motif-based dialogs must have a <tt>Shell</tt> widget parent with a
69single child, due to requirements of the Motif toolkit. The <tt>Shell</tt> widget, which is a special subclass of <tt>XmDialogShell</tt>, is
70created during construction. It can be accessed using the <a href="#shell">shell</a>()
71member function.
72<p> The single child of the <tt>Shell</tt> can be accessed using the
73<a href="#dialog">dialog</a>() member function <em>after</em> it has been created.
74<p> The <a href="#acceptCallback">acceptCallback</a>() and <a href="#rejectCallback">rejectCallback</a>() functions provide a
75convenient way to call <a href="qdialog.html#accept">QDialog::accept</a>() and <a href="qdialog.html#reject">QDialog::reject</a>()
76through callbacks. A pointer to the QMotifDialog should be passed
77as the <tt>client_data</tt> argument to the callback.
78<p> The API and behavior QMotifDialog is identical to that of <a href="qdialog.html">QDialog</a>
79when using a custom Qt-based dialog with a Motif-based parent.
80The only difference is that a Motif-based <em>parent</em> argument is
81passed to the constructor, instead of a <a href="qwidget.html">QWidget</a> parent.
82
83<hr><h2>Member Type Documentation</h2>
84<h3 class=fn><a name="DialogType-enum"></a>QMotifDialog::DialogType</h3> <b>This function is obsolete.</b> It is provided to keep old source working. We strongly advise against using it in new code.
85<p>
86<p> This enum lists the predefined <a href="motif-extension.html#Motif">Motif</a> dialog types.
87<ul>
88<li><tt>QMotifDialog::Prompt</tt>
89<li><tt>QMotifDialog::Selection</tt>
90<li><tt>QMotifDialog::Command</tt>
91<li><tt>QMotifDialog::FileSelection</tt>
92<li><tt>QMotifDialog::Template</tt>
93<li><tt>QMotifDialog::Error</tt>
94<li><tt>QMotifDialog::Information</tt>
95<li><tt>QMotifDialog::Message</tt>
96<li><tt>QMotifDialog::Question</tt>
97<li><tt>QMotifDialog::Warning</tt>
98<li><tt>QMotifDialog::Working</tt>
99</ul>
100<hr><h2>Member Function Documentation</h2>
101<h3 class=fn><a name="QMotifDialog"></a>QMotifDialog::QMotifDialog ( <a href="qmotifdialog.html#DialogType-enum">DialogType</a>&nbsp;dialogtype, Widget&nbsp;parent, ArgList&nbsp;args = NULL, Cardinal&nbsp;argcount = 0, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 )
102</h3> <b>This function is obsolete.</b> It is provided to keep old source working. We strongly advise against using it in new code.
103<p> Creates a QMotifDialog using one of the predefined <a href="motif-extension.html#Motif">Motif</a> dialog
104types. The <em>name</em>, <em>modal</em> and <em>flags</em> arguments are passed to
105the <a href="qdialog.html">QDialog</a> constructor.
106<p> This constructor creates a Shell widget, which is a special
107subclass of XmDialogShell. The <em>parent</em>, <em>args</em> and <em>argcount</em>
108arguments are passed to XtCreatePopupShell() when creating the
109subclass. You can access the Shell widget with the <a href="#shell">shell</a>() member
110function.
111<p> This constructor also creates the dialog widget with the Shell
112widget as its parent. The type of the dialog created is specified
113by the <em>dialogtype</em> argument. See the DialogType enum for a list
114of available dialog types. You can access the dialog widget with
115the <a href="#dialog">dialog</a>() member function.
116<p> <b>Warning:</b> QMotifDialog takes ownership of the child widget and
117destroys it during destruction. You should not destroy the dialog
118widget yourself.
119<p> <p>See also <a href="#DialogType-enum">DialogType</a>, <a href="#shell">shell</a>(), and <a href="#dialog">dialog</a>().
120
121<h3 class=fn><a name="QMotifDialog-2"></a>QMotifDialog::QMotifDialog ( Widget&nbsp;parent, ArgList&nbsp;args = NULL, Cardinal&nbsp;argcount = 0, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 )
122</h3> <b>This function is obsolete.</b> It is provided to keep old source working. We strongly advise against using it in new code.
123<p> Creates a QMotifDialog which allows the application programmer to
124use the <a href="motif-extension.html#Motif">Motif</a>-based <em>parent</em> for a custom <a href="qdialog.html">QDialog</a>. The <em>name</em>,
125<em>modal</em> and <em>flags</em> arguments are passed to the QDialog
126constructor.
127<p> This constructor creates a Shell widget, which is a special
128subclass of XmDialogShell. The <em>args</em> and <em>argcount</em> arguments
129are passed to XtCreatePopupShell() when creating the subclass.
130You can access the Shell widget with the <a href="#shell">shell</a>() member function.
131<p> The dialog widget is not created by the constructor. You must
132create the dialog widget as a child of the the widget returned by
133shell(). You can access the child widget with the <a href="#dialog">dialog</a>() member
134function.
135<p> A dialog widget is not created by this constructor. Instead, you
136should create the dialog widget as a child of this
137dialog. QMotifDialog will take ownership of your custom dialog,
138and you can access it with the dialog() member function.
139<p> <b>Warning:</b> QMotifDialog takes ownership of the child widget and
140destroys it during destruction. You should not destroy the dialog
141widget yourself.
142<p> <p>See also <a href="#shell">shell</a>() and <a href="#dialog">dialog</a>().
143
144<h3 class=fn><a name="QMotifDialog-3"></a>QMotifDialog::QMotifDialog ( Widget&nbsp;parent, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 )
145</h3>
146Creates a QMotifDialog which allows the application programmer to
147use the <a href="motif-extension.html#Motif">Motif</a>-based <em>parent</em> for a custom <a href="qdialog.html">QDialog</a>. The <em>name</em>,
148<em>modal</em> and <em>flags</em> arguments are passed to the QDialog
149constructor.
150<p> This constructor creates a <tt>Shell</tt> widget, which is a special
151subclass of <tt>XmDialogShell</tt>. You can access the <tt>Shell</tt> widget
152with the <a href="#shell">shell</a>() member function.
153<p> <p>See also <a href="#shell">shell</a>().
154
155<h3 class=fn><a name="QMotifDialog-4"></a>QMotifDialog::QMotifDialog ( <a href="qwidget.html">QWidget</a>&nbsp;*&nbsp;parent, const&nbsp;char&nbsp;*&nbsp;name = 0, bool&nbsp;modal = FALSE, WFlags&nbsp;flags = 0 )
156</h3>
157Creates a QMotifDialog which allows the application programmer to
158use a <a href="qwidget.html">QWidget</a> parent for an existing <a href="motif-extension.html#Motif">Motif</a>-based dialog. The <em>parent</em>, <em>name</em>, <em>modal</em> and <em>flags</em> arguments are passed to the
159<a href="qdialog.html">QDialog</a> constructor.
160<p> This constructor creates a <tt>Shell</tt> widget, which is a special
161subclass of <tt>XmDialogShell</tt>. You can access the <tt>Shell</tt> widget
162with the <a href="#shell">shell</a>() member functon.
163<p> A dialog widget is not created by this constructor. Instead, you
164should create the dialog widget as a child of this
165dialog. QMotifDialog will take ownership of your custom dialog,
166and you can access it with the <a href="#dialog">dialog</a>() member function.
167<p> <b>Warning:</b> QMotifDialog takes ownership of the child widget and
168destroys it during destruction. You should not destroy the dialog
169widget yourself.
170<p> <p>See also <a href="#shell">shell</a>() and <a href="#dialog">dialog</a>().
171
172<h3 class=fn><a name="~QMotifDialog"></a>QMotifDialog::~QMotifDialog ()<tt> [virtual]</tt>
173</h3>
174Destroys the <a href="qdialog.html">QDialog</a>, dialog widget and <tt>Shell</tt> widget.
175
176<h3 class=fn>void <a name="acceptCallback"></a>QMotifDialog::acceptCallback ( Widget, XtPointer&nbsp;client_data, XtPointer )<tt> [static]</tt>
177</h3>
178Convenient Xt/Motif callback to accept the QMotifDialog.
179<p> The data is passed in <em>client_data</em>.
180
181<h3 class=fn>Widget <a name="dialog"></a>QMotifDialog::dialog () const
182</h3>
183Returns the <a href="motif-extension.html#Motif">Motif</a> widget embedded in this dialog.
184
185<h3 class=fn>void <a name="rejectCallback"></a>QMotifDialog::rejectCallback ( Widget, XtPointer&nbsp;client_data, XtPointer )<tt> [static]</tt>
186</h3>
187Convenient Xt/Motif callback to reject the QMotifDialog.
188<p> The data is passed in <em>client_data</em>.
189
190<h3 class=fn>Widget <a name="shell"></a>QMotifDialog::shell () const
191</h3>
192Returns the <tt>Shell</tt> widget embedded in this dialog.
193
194<p>Example: <a href="motif-dialog-example.html#x2707">dialog/mainwindow.cpp</a>.
195<!-- eof -->
196<hr><p>
197This file is part of the <a href="index.html">Qt toolkit</a>.
198Copyright &copy; 1995-2007
199<a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center>
200<table width=100% cellspacing=0 border=0><tr>
201<td>Copyright &copy; 2007
202<a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
203<td align=right><div align=right>Qt 3.3.8</div>
204</table></div></address></body>
205</html>
Note: See TracBrowser for help on using the repository browser.