From ea318d1431c89e647598c510c4245c6571aa5f46 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 26 Jan 2012 23:32:43 -0600 Subject: Update to latest tqt3 automated conversion --- doc/html/motif-walkthrough-9.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'doc/html/motif-walkthrough-9.html') diff --git a/doc/html/motif-walkthrough-9.html b/doc/html/motif-walkthrough-9.html index 4c0cc9dc6..76fb859a7 100644 --- a/doc/html/motif-walkthrough-9.html +++ b/doc/html/motif-walkthrough-9.html @@ -39,12 +39,12 @@ body { background: #ffffff; color: black; }

The Print dialog is the last component in our application that uses Motif. The current Print() function does nothing more than write the plain text to a temporary file, and then executes 'lpr' to -send the text to the printer. Since we will use TQPrinter, we do not +send the text to the printer. Since we will use TQPrinter, we do not this function any more, so we remove it. The current MainWindow::filePrint() implementation is removed as well. We will write a new MainWindow::filePrint() implementation in mainwindow.ui.h.

Note: The steps involved in using the TQPrinter class are beyond the scope of this walkthrough and will not be discussed here. The -TQPrinter Class Reference, TQSimpleRichText Class Reference and the +TQPrinter Class Reference, TQSimpleRichText Class Reference and the Simple Application Walkthrough contain information on the use of TQPrinter.

For completeness, the code to initialize a TQPrinter object is included below. @@ -62,12 +62,12 @@ previous versions.


 

Next we just loop over all pages, appending the page label, contents and formatting characters to a printtext variable (which is a -TQString). +TQString).


 

The rest of the MainWindow::filePrint() function is the actual -printing code. Here we simply create a TQSimpleRichText object using -the string we created above, and draw this string on the TQPrinter -object using TQPainter. +printing code. Here we simply create a TQSimpleRichText object using +the string we created above, and draw this string on the TQPrinter +object using TQPainter.


 

Removing the Dependency on Xt/Motif

-- cgit v1.2.1