diff options
Diffstat (limited to 'doc/html/toplevel-example.html')
-rw-r--r-- | doc/html/toplevel-example.html | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/doc/html/toplevel-example.html b/doc/html/toplevel-example.html index 0e5682242..6bcd36fe4 100644 --- a/doc/html/toplevel-example.html +++ b/doc/html/toplevel-example.html @@ -38,8 +38,8 @@ This example demonstrates the use of TQt's widget flags to provide toplevel widgets with customized window decorations. <p> It provides a graphical user interface for selecting different options for widget decoration and behavior, and passes the -appropriate widget flags to the <a href="ntqwidget.html">TQWidget</a> constructor. -<a href="ntqwidget.html#reparent">TQWidget::reparent</a>() is used to change the widget flags at runtime. +appropriate widget flags to the <a href="tqwidget.html">TQWidget</a> constructor. +<a href="tqwidget.html#reparent">TQWidget::reparent</a>() is used to change the widget flags at runtime. <p> <b>Warning:</b> Note that the interpretation and functionality of the widget flags depends on the window manager used when running the application. Many window managers do not support every possible flag @@ -128,7 +128,7 @@ have been checked. </pre>If the window should not have a border it cannot have a titlebar. Widgets that provide their own (e.g. themed) window decoration should use this flag. -<p> <pre> <a href="ntqwidget.html">TQWidget</a> *parent = this; +<p> <pre> <a href="tqwidget.html">TQWidget</a> *parent = this; if ( cbBehaviorTaskbar->isChecked() ) { parent = 0; f |= WGroupLeader; @@ -188,23 +188,23 @@ modeless dialogs. <a name="x2532"></a> label-><a href="ntqlabel.html#setTextFormat">setTextFormat</a>(RichText); <a name="x2531"></a> label-><a href="ntqlabel.html#setAlignment">setAlignment</a>(WordBreak); <a href="ntqpushbutton.html">TQPushButton</a> *okButton = new <a href="ntqpushbutton.html">TQPushButton</a>( "Close", widget ); - <a name="x2535"></a> connect( okButton, TQ_SIGNAL(<a href="ntqbutton.html#clicked">clicked</a>()), widget, TQ_SLOT(<a href="ntqwidget.html#close">close</a>()) ); - <a name="x2537"></a> widget-><a href="ntqwidget.html#move">move</a>( pos() ); + <a name="x2535"></a> connect( okButton, TQ_SIGNAL(<a href="ntqbutton.html#clicked">clicked</a>()), widget, TQ_SLOT(<a href="tqwidget.html#close">close</a>()) ); + <a name="x2537"></a> widget-><a href="tqwidget.html#move">move</a>( pos() ); </pre>The widget is created if it has not been created yet, or if it was closed (since we use the <tt>WDestructiveClose</tt> flag). Note that the window is not visible yet. <a href="#footnote2"><sup>(2)</sup></a><a name="footnote-call2"></a> <p> <pre> } else { - <a name="x2538"></a><a name="x2536"></a> widget-><a href="ntqwidget.html#reparent">reparent</a>( parent, f, widget-><a href="ntqwidget.html#geometry">geometry</a>().topLeft(), FALSE); + <a name="x2538"></a><a name="x2536"></a> widget-><a href="tqwidget.html#reparent">reparent</a>( parent, f, widget-><a href="tqwidget.html#geometry">geometry</a>().topLeft(), FALSE); } </pre>If the widget has already been created the reparent() function is used to modify the widget's flags. The widget's geometry is not changed, and the window is not shown again. -<p> <pre> <a name="x2539"></a> widget-><a href="ntqwidget.html#setCaption">setCaption</a>( leCaption->text() ); - <a name="x2540"></a> widget-><a href="ntqwidget.html#setIcon">setIcon</a>( leIcon->text() ); - <a name="x2541"></a> widget-><a href="ntqwidget.html#setWindowOpacity">setWindowOpacity</a>(double(slTransparency->maxValue() - slTransparency->value()) / 100); +<p> <pre> <a name="x2539"></a> widget-><a href="tqwidget.html#setCaption">setCaption</a>( leCaption->text() ); + <a name="x2540"></a> widget-><a href="tqwidget.html#setIcon">setIcon</a>( leIcon->text() ); + <a name="x2541"></a> widget-><a href="tqwidget.html#setWindowOpacity">setWindowOpacity</a>(double(slTransparency->maxValue() - slTransparency->value()) / 100); - <a name="x2542"></a> widget-><a href="ntqwidget.html#show">show</a>(); + <a name="x2542"></a> widget-><a href="tqwidget.html#show">show</a>(); </pre>Finally the higher level properties such as the window's caption and icon are set. The window transparency is set according to the slider value. Note that this will only have effect on systems that support |