diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-01-26 23:32:43 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2012-01-26 23:32:43 -0600 |
commit | ea318d1431c89e647598c510c4245c6571aa5f46 (patch) | |
tree | 996d29b80c30d453dda86d1a23162d441628f169 /doc/html/motif-walkthrough-8.html | |
parent | aaf89d4b48f69c9293feb187db26362e550b5561 (diff) | |
download | tqt3-ea318d1431c89e647598c510c4245c6571aa5f46.tar.gz tqt3-ea318d1431c89e647598c510c4245c6571aa5f46.zip |
Update to latest tqt3 automated conversion
Diffstat (limited to 'doc/html/motif-walkthrough-8.html')
-rw-r--r-- | doc/html/motif-walkthrough-8.html | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/doc/html/motif-walkthrough-8.html b/doc/html/motif-walkthrough-8.html index 40bc1f1a3..d0a2c5720 100644 --- a/doc/html/motif-walkthrough-8.html +++ b/doc/html/motif-walkthrough-8.html @@ -50,7 +50,7 @@ and code will need to be modified or rewritten. New code must be written in a way that maintains compatibility with previous versions of our application. <p> </ul> -<p> <li> We can write a new <a href="qwidget.html">TQWidget</a> subclass that is identical to the <tt>XmNotebook</tt> widget class. +<p> <li> We can write a new <a href="ntqwidget.html">TQWidget</a> subclass that is identical to the <tt>XmNotebook</tt> widget class. <p> <ul> <p> <li> Advantages - The existing data structures will not change, allowing compatibility with previous and future versions. @@ -69,8 +69,8 @@ application on all platforms supported by TQt. <p> </ul> <p> </ol> <p> We will use the first approach to complete the migration of the -example project used in this walkthrough, using <a href="qtextedit.html">TQTextEdit</a>, <a href="qlabel.html">TQLabel</a> and -<a href="qspinbox.html">TQSpinBox</a> to provide a similar look. The only difference is that we +example project used in this walkthrough, using <a href="ntqtextedit.html">TQTextEdit</a>, <a href="ntqlabel.html">TQLabel</a> and +<a href="ntqspinbox.html">TQSpinBox</a> to provide a similar look. The only difference is that we will not have tabs. <p> We use <a href="designer-manual.html">TQt Designer</a> to add the TQTextEdit, TQLabel and TQSpinBox widgets to the <em>Main Window</em> widget. @@ -125,10 +125,10 @@ number (with an indication that the page is invalid). <p> The <tt>PageChange()</tt> function is moved from <tt>todo.cpp</tt> to the <tt>MainWindow::pageChange()</tt> function in <tt>mainwindow.ui.h</tt>. As with the <tt>MainWindow::setPae()</tt> function, we need to modify the code to use the new widgets in our <em>Main Window</em> widget. -<p> Note: <a href="qtextedit.html#text">TQTextEdit::text</a>() returns a <a href="qstring.html">TQString</a>, which needs to be converted +<p> Note: <a href="ntqtextedit.html#text">TQTextEdit::text</a>() returns a <a href="ntqstring.html">TQString</a>, which needs to be converted into a normal <tt>char*</tt> array. To do this we create a copy of the -string in the local encoding. We need to make the copy using <a href="qcstring.html#qstrdup">qstrdup</a>() because the data contained in the <a href="qcstring.html">TQCString</a> returned by -<a href="qstring.html#local8Bit">TQString::local8Bit</a>() is deallocated when the TQCString is destroyed. +string in the local encoding. We need to make the copy using <a href="ntqcstring.html#qstrdup">qstrdup</a>() because the data contained in the <a href="ntqcstring.html">TQCString</a> returned by +<a href="ntqstring.html#local8Bit">TQString::local8Bit</a>() is deallocated when the TQCString is destroyed. <p> <pre></pre> <p> The <tt>TextChanged()</tt> function does nothing more than set the <tt>modified</tt> variable to 1. Our new <tt>MainWindow::textChanged()</tt> function does exactly the same. @@ -140,8 +140,8 @@ variable, we add a forward declaration at the top of <tt>mainwindow.ui.h</tt>. renamed to <tt>MainWindow::readDB()</tt> and <tt>MainWindow::saveDB()</tt>, respectively. We need to modify the code in order to make the code work properly. -<p> First, We add <tt>#include</tt> statements for the <tt>MainWindow</tt>, <a href="qspinbox.html">TQSpinBox</a> -and <a href="qtextedit.html">TQTextEdit</a> classes. +<p> First, We add <tt>#include</tt> statements for the <tt>MainWindow</tt>, <a href="ntqspinbox.html">TQSpinBox</a> +and <a href="ntqtextedit.html">TQTextEdit</a> classes. <p> <pre></pre><pre></pre> @@ -150,7 +150,7 @@ will not use any Xt/Motif functions, so we remove the Xt/Motif <tt>#include</tt> These functions remain largely unchanged, maintaining compatibility with previous versions. Also, the <tt>ReadDB()</tt> and <tt>SaveDB()</tt> functions have been converted into <tt>MainWindow</tt> member functions, so -we can pass <em>this</em> as the <em>parent</em> argument to the <a href="qmessagebox.html">TQMessageBox</a> +we can pass <em>this</em> as the <em>parent</em> argument to the <a href="ntqmessagebox.html">TQMessageBox</a> functions. <p> <pre></pre> <p> After reading the file in the <tt>MainWindow::readDB()</tt> function, we set @@ -160,11 +160,11 @@ values. <p> <pre></pre> <p> In the <tt>MainWindow::saveDB()</tt> function, we need to store the text -currently displayed, so we use <a href="qtextedit.html#text">TQTextEdit::text</a>() instead of <tt>XmTextGetString()</tt>. Note: TQTextEdit::text() returns a <a href="qstring.html">TQString</a>, which +currently displayed, so we use <a href="ntqtextedit.html#text">TQTextEdit::text</a>() instead of <tt>XmTextGetString()</tt>. Note: TQTextEdit::text() returns a <a href="ntqstring.html">TQString</a>, which needs to be converted into a normal <tt>char*</tt> array. To do this we create a copy of the string in the local encoding. We need to make -the copy using <a href="qcstring.html#qstrdup">qstrdup</a>() because the data contained in the <a href="qcstring.html">TQCString</a> -returned by <a href="qstring.html#local8Bit">TQString::local8Bit</a>() is deallocated when the TQCString is +the copy using <a href="ntqcstring.html#qstrdup">qstrdup</a>() because the data contained in the <a href="ntqcstring.html">TQCString</a> +returned by <a href="ntqstring.html#local8Bit">TQString::local8Bit</a>() is deallocated when the TQCString is destroyed. <p> <pre></pre> <p> <a name="actions-cpp-viewwidget-modifications"></a> |