summaryrefslogtreecommitdiffstats
path: root/lib/kotext/KoTextZoomHandler.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/kotext/KoTextZoomHandler.h')
-rw-r--r--lib/kotext/KoTextZoomHandler.h36
1 files changed, 18 insertions, 18 deletions
diff --git a/lib/kotext/KoTextZoomHandler.h b/lib/kotext/KoTextZoomHandler.h
index 81211086..f8c2ef12 100644
--- a/lib/kotext/KoTextZoomHandler.h
+++ b/lib/kotext/KoTextZoomHandler.h
@@ -23,7 +23,7 @@
#include <KoZoomHandler.h>
/**
- * This class extends KoZoomHandler to add support for WYSIWYG text tqlayouting.
+ * This class extends KoZoomHandler to add support for WYSIWYG text layouting.
*/
class KOTEXT_EXPORT KoTextZoomHandler : public KoZoomHandler
{
@@ -31,7 +31,7 @@ public:
KoTextZoomHandler() {}
virtual ~KoTextZoomHandler() {}
- //// Support for WYSIWYG text tqlayouting /////
+ //// Support for WYSIWYG text layouting /////
/** The "[zoomed] view pixel" -> "tqlayout unit pixel" conversions. */
int pixelToLayoutUnitX( int x ) const;
@@ -44,22 +44,22 @@ public:
pixelToLayoutUnit( r.bottomRight() ) ); }
/** The "tqlayout unit pixel" -> "[zoomed] view pixel" conversions. */
- int tqlayoutUnitToPixelX( int lupix ) const;
- int tqlayoutUnitToPixelY( int lupix ) const;
+ int layoutUnitToPixelX( int lupix ) const;
+ int layoutUnitToPixelY( int lupix ) const;
/** This variant converts a width, using a reference X position.
* This prevents rounding problems. */
- int tqlayoutUnitToPixelX( int x, int w ) const;
+ int layoutUnitToPixelX( int x, int w ) const;
/** This variant converts a height, using a reference Y position.
* This prevents rounding problems. */
- int tqlayoutUnitToPixelY( int y, int h ) const;
+ int layoutUnitToPixelY( int y, int h ) const;
- TQPoint tqlayoutUnitToPixel( const TQPoint &p ) const
- { return TQPoint( tqlayoutUnitToPixelX( p.x() ),
- tqlayoutUnitToPixelY( p.y() ) ); }
- TQRect tqlayoutUnitToPixel( const TQRect &r ) const
- { return TQRect( tqlayoutUnitToPixel( r.topLeft() ),
- tqlayoutUnitToPixel( r.bottomRight() ) ); }
+ TQPoint layoutUnitToPixel( const TQPoint &p ) const
+ { return TQPoint( layoutUnitToPixelX( p.x() ),
+ layoutUnitToPixelY( p.y() ) ); }
+ TQRect layoutUnitToPixel( const TQRect &r ) const
+ { return TQRect( layoutUnitToPixel( r.topLeft() ),
+ layoutUnitToPixel( r.bottomRight() ) ); }
/** Basic pt to pixel and pixel to pt conversions, valid at any zoom level,
as well as at the Layout Unit level (and mostly useful for Layout Units).
@@ -92,11 +92,11 @@ public:
* Given the font size for the font in tqlayout units, in pt (use pointSize())
* this returns the font size to use on screen the current zoom, in pt (use setPointSizeFloat()),
*/
- double tqlayoutUnitToFontSize( int luSize, bool /*forPrint*/ ) const;
+ double layoutUnitToFontSize( int luSize, bool /*forPrint*/ ) const;
// Note: For converting fontsizes from/to tqlayout units and zoom-independent
// pt sizes (like the one the user sees, e.g. 12pt),
- // use ptToLayoutUnit and tqlayoutUnitToPt, not tqlayoutToFontSize.
+ // use ptToLayoutUnit and layoutUnitToPt, not layoutToFontSize.
// The conversions below convert between an internal text tqlayout resolution of
@@ -122,11 +122,11 @@ public:
{ return KoRect( ptToLayoutUnitPt( r.topLeft() ),
ptToLayoutUnitPt( r.bottomRight() ) ); }
- static double tqlayoutUnitPtToPt( double lupt )
+ static double layoutUnitPtToPt( double lupt )
{ return lupt / static_cast<double>( m_layoutUnitFactor ); }
- static KoPoint tqlayoutUnitPtToPt( const KoPoint& p )
- { return KoPoint( tqlayoutUnitPtToPt( p.x() ),
- tqlayoutUnitPtToPt( p.y() ) ); }
+ static KoPoint layoutUnitPtToPt( const KoPoint& p )
+ { return KoPoint( layoutUnitPtToPt( p.x() ),
+ layoutUnitPtToPt( p.y() ) ); }
protected:
/** This being static ensures that the same value is used by all KoTextZoomHandler instances */