From a30f5359f03c3017fa19a6770fab32d25d22cb87 Mon Sep 17 00:00:00 2001 From: Michele Calgaro Date: Mon, 15 Jul 2024 19:08:22 +0900 Subject: Rename graphics class nt* related files to equivalent tq* (part 1) Signed-off-by: Michele Calgaro --- doc/html/scribble-example.html | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'doc/html/scribble-example.html') diff --git a/doc/html/scribble-example.html b/doc/html/scribble-example.html index 81d5aa09d..6d0ee2343 100644 --- a/doc/html/scribble-example.html +++ b/doc/html/scribble-example.html @@ -71,13 +71,13 @@ class Canvas : public TQWidget public: Canvas( TQWidget *parent = 0, const char *name = 0 ); - void setPenColor( const TQColor &c ) + void setPenColor( const TQColor &c ) { pen.setColor( c ); } void setPenWidth( int w ) { pen.setWidth( w ); } - TQColor penColor() + TQColor penColor() { return pen.color(); } int penWidth() @@ -92,7 +92,7 @@ protected: void mouseReleaseEvent( TQMouseEvent *e ); void mouseMoveEvent( TQMouseEvent *e ); void resizeEvent( TQResizeEvent *e ); - void paintEvent( TQPaintEvent *e ); + void paintEvent( TQPaintEvent *e ); TQPen pen; TQPointArray polyline; @@ -143,14 +143,14 @@ protected slots: #include <ntqapplication.h> #include <ntqevent.h> -#include <ntqpainter.h> +#include <tqpainter.h> #include <tqtoolbar.h> #include <tqtoolbutton.h> #include <ntqspinbox.h> #include <tqtooltip.h> #include <ntqrect.h> #include <ntqpoint.h> -#include <ntqcolordialog.h> +#include <tqcolordialog.h> #include <tqfiledialog.h> #include <ntqcursor.h> #include <tqimage.h> @@ -199,14 +199,14 @@ void Canvas::clearScreen() void Canvas::mouseMoveEvent( TQMouseEvent *e ) { if ( mousePressed ) { - TQPainter painter; - painter.begin( &buffer ); - painter.setPen( pen ); + TQPainter painter; + painter.begin( &buffer ); + painter.setPen( pen ); polyline[2] = polyline[1]; polyline[1] = polyline[0]; polyline[0] = e->pos(); - painter.drawPolyline( polyline ); - painter.end(); + painter.drawPolyline( polyline ); + painter.end(); TQRect r = polyline.boundingRect(); r = r.normalize(); @@ -234,11 +234,11 @@ void Canvas::clearScreen() bitBlt( &buffer, 0, 0, &tmp, 0, 0, tmp.width(), tmp.height() ); } -void Canvas::paintEvent( TQPaintEvent *e ) +void Canvas::paintEvent( TQPaintEvent *e ) { TQWidget::paintEvent( e ); - TQMemArray<TQRect> rects = e->region().rects(); + TQMemArray<TQRect> rects = e->region().rects(); for ( uint i = 0; i < rects.count(); i++ ) { TQRect r = rects[(int)i]; bitBlt( this, r.x(), r.y(), &buffer, r.x(), r.y(), r.width(), r.height() ); @@ -303,8 +303,8 @@ void Scribble::slotSave() void Scribble::slotColor() { - TQColor c = TQColorDialog::getColor( canvas->penColor(), this ); - if ( c.isValid() ) + TQColor c = TQColorDialog::getColor( canvas->penColor(), this ); + if ( c.isValid() ) canvas->setPenColor( c ); } -- cgit v1.2.3