From 1e9fa8e06de5da7fcc268e9cccb2d6b21c5f53a3 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Sat, 20 Jul 2024 20:15:52 +0900 Subject: Rename graphics class nt* related files to equivalent tq* (part 2) Signed-off-by: Michele Calgaro --- doc/html/helpviewer-example.html | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'doc/html/helpviewer-example.html') diff --git a/doc/html/helpviewer-example.html b/doc/html/helpviewer-example.html index e57fc7eb1..17cf93ddf 100644 --- a/doc/html/helpviewer-example.html +++ b/doc/html/helpviewer-example.html @@ -117,7 +117,7 @@ private: #include "helpwindow.h" #include <tqstatusbar.h> -#include <ntqpixmap.h> +#include <tqpixmap.h> #include <tqpopupmenu.h> #include <tqmenubar.h> #include <tqtoolbar.h> @@ -136,7 +136,7 @@ private: #include <tqfileinfo.h> #include <tqfile.h> #include <tqdatastream.h> -#include <ntqprinter.h> +#include <tqprinter.h> #include <ntqsimplerichtext.h> #include <tqpainter.h> #include <tqpaintdevicemetrics.h> @@ -341,33 +341,33 @@ void HelpWindow::newWindow() void HelpWindow::print() { #ifndef TQT_NO_PRINTER - TQPrinter printer( TQPrinter::HighResolution ); - printer.setFullPage(TRUE); - if ( printer.setup( this ) ) { + TQPrinter printer( TQPrinter::HighResolution ); + printer.setFullPage(TRUE); + if ( printer.setup( this ) ) { TQPainter p( &printer ); if( !p.isActive() ) // starting printing failed return; TQPaintDeviceMetrics metrics(p.device()); int dpiy = metrics.logicalDpiY(); int margin = (int) ( (2/2.54)*dpiy ); // 2 cm margins - TQRect view( margin, margin, metrics.width() - 2*margin, metrics.height() - 2*margin ); + TQRect view( margin, margin, metrics.width() - 2*margin, metrics.height() - 2*margin ); TQSimpleRichText richText( browser->text(), TQFont(), browser->context(), browser->styleSheet(), browser->mimeSourceFactory(), - view.height() ); - richText.setWidth( &p, view.width() ); + view.height() ); + richText.setWidth( &p, view.width() ); int page = 1; do { richText.draw( &p, margin, margin, view, colorGroup() ); - view.moveBy( 0, view.height() ); - p.translate( 0 , -view.height() ); - p.drawText( view.right() - p.fontMetrics().width( TQString::number(page) ), - view.bottom() + p.fontMetrics().ascent() + 5, TQString::number(page) ); - if ( view.top() - margin >= richText.height() ) + view.moveBy( 0, view.height() ); + p.translate( 0 , -view.height() ); + p.drawText( view.right() - p.fontMetrics().width( TQString::number(page) ), + view.bottom() + p.fontMetrics().ascent() + 5, TQString::number(page) ); + if ( view.top() - margin >= richText.height() ) break; - printer.newPage(); + printer.newPage(); page++; } while (TRUE); } -- cgit v1.2.1