diff options
Diffstat (limited to 'doc/html/movies-example.html')
-rw-r--r-- | doc/html/movies-example.html | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/doc/html/movies-example.html b/doc/html/movies-example.html index ae07a20b1..96fdea355 100644 --- a/doc/html/movies-example.html +++ b/doc/html/movies-example.html @@ -81,7 +81,7 @@ public: setBackgroundMode(NoBackground); // Get the movie to tell use when interesting things happen. -<a name="x500"></a> movie.<a href="tqmovie.html#connectUpdate">connectUpdate</a>(this, TQ_SLOT(movieUpdated(const <a href="ntqrect.html">TQRect</a>&))); +<a name="x500"></a> movie.<a href="tqmovie.html#connectUpdate">connectUpdate</a>(this, TQ_SLOT(movieUpdated(const <a href="tqrect.html">TQRect</a>&))); <a name="x498"></a> movie.<a href="tqmovie.html#connectResize">connectResize</a>(this, TQ_SLOT(movieResized(const <a href="tqsize.html">TQSize</a>&))); <a name="x499"></a> movie.<a href="tqmovie.html#connectStatus">connectStatus</a>(this, TQ_SLOT(movieStatus(int))); @@ -99,25 +99,25 @@ protected: void drawContents(TQPainter* p) { // Get the current movie frame. -<a name="x502"></a> <a href="ntqpixmap.html">TQPixmap</a> pm = movie.<a href="tqmovie.html#framePixmap">framePixmap</a>(); +<a name="x502"></a> <a href="tqpixmap.html">TQPixmap</a> pm = movie.<a href="tqmovie.html#framePixmap">framePixmap</a>(); // Get the area we have to draw in. - <a href="ntqrect.html">TQRect</a> r = contentsRect(); + <a href="tqrect.html">TQRect</a> r = contentsRect(); -<a name="x511"></a> if ( !pm.<a href="ntqpixmap.html#isNull">isNull</a>() ) { +<a name="x511"></a> if ( !pm.<a href="tqpixmap.html#isNull">isNull</a>() ) { // Only rescale is we need to - it can take CPU! -<a name="x516"></a><a name="x512"></a> if ( r.<a href="ntqrect.html#size">size</a>() != pm.<a href="ntqpixmap.html#size">size</a>() ) { - <a href="ntqwmatrix.html">TQWMatrix</a> m; -<a name="x524"></a><a name="x517"></a><a name="x513"></a> m.<a href="ntqwmatrix.html#scale">scale</a>((double)r.<a href="ntqrect.html#width">width</a>()/pm.<a href="ntqpixmap.html#width">width</a>(), -<a name="x515"></a><a name="x510"></a> (double)r.<a href="ntqrect.html#height">height</a>()/pm.<a href="ntqpixmap.html#height">height</a>()); -<a name="x514"></a> pm = pm.<a href="ntqpixmap.html#xForm">xForm</a>(m); +<a name="x516"></a><a name="x512"></a> if ( r.<a href="tqrect.html#size">size</a>() != pm.<a href="tqpixmap.html#size">size</a>() ) { + <a href="tqwmatrix.html">TQWMatrix</a> m; +<a name="x524"></a><a name="x517"></a><a name="x513"></a> m.<a href="tqwmatrix.html#scale">scale</a>((double)r.<a href="tqrect.html#width">width</a>()/pm.<a href="tqpixmap.html#width">width</a>(), +<a name="x515"></a><a name="x510"></a> (double)r.<a href="tqrect.html#height">height</a>()/pm.<a href="tqpixmap.html#height">height</a>()); +<a name="x514"></a> pm = pm.<a href="tqpixmap.html#xForm">xForm</a>(m); } // Draw the [possibly scaled] frame. movieUpdated() below calls // repaint with only the changed area, so clipping will ensure we // only do the minimum amount of rendering. // -<a name="x519"></a><a name="x518"></a> p->drawPixmap(r.<a href="ntqrect.html#x">x</a>(), r.<a href="ntqrect.html#y">y</a>(), pm); +<a name="x519"></a><a name="x518"></a> p->drawPixmap(r.<a href="tqrect.html#x">x</a>(), r.<a href="tqrect.html#y">y</a>(), pm); } @@ -138,19 +138,19 @@ protected: p->setFont(TQFont("Helvetica", 24)); <a href="tqfontmetrics.html">TQFontMetrics</a> fm = p->fontMetrics(); -<a name="x496"></a> if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="ntqrect.html#width">width</a>()-10 ) +<a name="x496"></a> if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="tqrect.html#width">width</a>()-10 ) p->setFont(TQFont("Helvetica", 18)); fm = p->fontMetrics(); - if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="ntqrect.html#width">width</a>()-10 ) + if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="tqrect.html#width">width</a>()-10 ) p->setFont(TQFont("Helvetica", 14)); fm = p->fontMetrics(); - if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="ntqrect.html#width">width</a>()-10 ) + if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="tqrect.html#width">width</a>()-10 ) p->setFont(TQFont("Helvetica", 12)); fm = p->fontMetrics(); - if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="ntqrect.html#width">width</a>()-10 ) + if ( fm.<a href="tqfontmetrics.html#width">width</a>(message) > r.<a href="tqrect.html#width">width</a>()-10 ) p->setFont(TQFont("Helvetica", 10)); // "Shadow" effect. @@ -190,22 +190,22 @@ public slots: } private slots: - void movieUpdated(const <a href="ntqrect.html">TQRect</a>& area) + void movieUpdated(const <a href="tqrect.html">TQRect</a>& area) { if (!isVisible()) show(); // The given area of the movie has changed. - <a href="ntqrect.html">TQRect</a> r = contentsRect(); + <a href="tqrect.html">TQRect</a> r = contentsRect(); - if ( r.<a href="ntqrect.html#size">size</a>() != movie.<a href="tqmovie.html#framePixmap">framePixmap</a>().size() ) { + if ( r.<a href="tqrect.html#size">size</a>() != movie.<a href="tqmovie.html#framePixmap">framePixmap</a>().size() ) { // Need to scale - redraw whole frame. repaint( r ); } else { // Only redraw the changed area of the frame - repaint( area.<a href="ntqrect.html#x">x</a>()+r.<a href="ntqrect.html#x">x</a>(), area.<a href="ntqrect.html#y">y</a>()+r.<a href="ntqrect.html#x">x</a>(), - area.<a href="ntqrect.html#width">width</a>(), area.<a href="ntqrect.html#height">height</a>() ); + repaint( area.<a href="tqrect.html#x">x</a>()+r.<a href="tqrect.html#x">x</a>(), area.<a href="tqrect.html#y">y</a>()+r.<a href="tqrect.html#x">x</a>(), + area.<a href="tqrect.html#width">width</a>(), area.<a href="tqrect.html#height">height</a>() ); } } |