From e69e8b1d09fb579316595b4e6a850e717358a8b1 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sun, 19 Jun 2011 19:03:33 +0000 Subject: TQt4 port kdegraphics This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1237557 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- ksvg/impl/SVGMaskElementImpl.h | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'ksvg/impl/SVGMaskElementImpl.h') diff --git a/ksvg/impl/SVGMaskElementImpl.h b/ksvg/impl/SVGMaskElementImpl.h index 2a96967c..4631ebae 100644 --- a/ksvg/impl/SVGMaskElementImpl.h +++ b/ksvg/impl/SVGMaskElementImpl.h @@ -56,7 +56,7 @@ public: { public: Mask() : m_width(0), m_height(0) {} - Mask(const TQByteArray& mask, const TQWMatrix& screenToMask, int width, int height); + Mask(const TQByteArray& tqmask, const TQWMatrix& screenToMask, int width, int height); ~Mask() {} bool isEmpty() const { return m_width == 0; } @@ -68,15 +68,15 @@ public: private: int m_width; int m_height; - TQByteArray m_mask; + TQByteArray m_tqmask; TQWMatrix m_screenToMask; }; SVGMaskElementImpl(DOM::ElementImpl *); virtual ~SVGMaskElementImpl(); - SVGAnimatedEnumerationImpl *maskUnits() const; - SVGAnimatedEnumerationImpl *maskContentUnits() const; + SVGAnimatedEnumerationImpl *tqmaskUnits() const; + SVGAnimatedEnumerationImpl *tqmaskContentUnits() const; SVGAnimatedLengthImpl *x() const; SVGAnimatedLengthImpl *y() const; SVGAnimatedLengthImpl *width() const; @@ -89,10 +89,10 @@ public: Mask createMask(SVGShapeImpl *referencingElement); - // Compute the mask on a given shape, taking into account all masks defined - // on the shape's ancestors. This is a workaround for us not having a buffer - // for container elements, so we can't mask containers directly. - static TQByteArray maskRectangle(SVGShapeImpl *shape, const TQRect& screenRectangle); + // Compute the tqmask on a given tqshape, taking into account all tqmasks defined + // on the tqshape's ancestors. This is a workaround for us not having a buffer + // for container elements, so we can't tqmask containers directly. + static TQByteArray tqmaskRectangle(SVGShapeImpl *tqshape, const TQRect& screenRectangle); private: class CacheKey @@ -110,8 +110,8 @@ private: Mask createMask(SVGShapeImpl *referencingElement, int imageWidth, int imageHeight); - SVGAnimatedEnumerationImpl *m_maskUnits; - SVGAnimatedEnumerationImpl *m_maskContentUnits; + SVGAnimatedEnumerationImpl *m_tqmaskUnits; + SVGAnimatedEnumerationImpl *m_tqmaskContentUnits; SVGAnimatedLengthImpl *m_x; SVGAnimatedLengthImpl *m_y; SVGAnimatedLengthImpl *m_width; @@ -120,7 +120,7 @@ private: SVGUnitConverter *m_converter; KSVGCanvas *m_canvas; - MinOneLRUCache m_maskCache; + MinOneLRUCache m_tqmaskCache; public: KSVG_GET @@ -137,7 +137,7 @@ public: void putValueProperty(KJS::ExecState *exec, int token, const KJS::Value &value, int attr); }; -KSVG_REGISTER_ELEMENT(SVGMaskElementImpl, "mask") +KSVG_REGISTER_ELEMENT(SVGMaskElementImpl, "tqmask") inline unsigned char SVGMaskElementImpl::Mask::value(int screenX, int screenY) const { @@ -146,7 +146,7 @@ inline unsigned char SVGMaskElementImpl::Mask::value(int screenX, int screenY) c m_screenToMask.map(screenX, screenY, &x, &y); if(x >= 0 && x < m_width && y >= 0 && y < m_height) - return m_mask[x + y * m_width]; + return m_tqmask[x + y * m_width]; else return 0; } -- cgit v1.2.1