diff options
author | Oliver Bolte <obo@openoffice.org> | 2007-07-17 14:23:50 +0000 |
---|---|---|
committer | Oliver Bolte <obo@openoffice.org> | 2007-07-17 14:23:50 +0000 |
commit | 2c0196934438950b977b416b10940ee5d0cbc821 (patch) | |
tree | c114f483c67ebf228fa2d31db4c0c0b6d91fc92a /cppcanvas/source/inc/canvasgraphichelper.hxx | |
parent | e4b4ec133d72e64bef93553e44bf9974520c3a15 (diff) |
INTEGRATION: CWS presfixes12 (1.5.50); FILE MERGED
2007/03/08 21:37:07 thb 1.5.50.1: #i37778# Added extra setClip() method to be able to set no clip - setting a clip with zero polygons by definition clips everything
Diffstat (limited to 'cppcanvas/source/inc/canvasgraphichelper.hxx')
-rw-r--r-- | cppcanvas/source/inc/canvasgraphichelper.hxx | 29 |
1 files changed, 14 insertions, 15 deletions
diff --git a/cppcanvas/source/inc/canvasgraphichelper.hxx b/cppcanvas/source/inc/canvasgraphichelper.hxx index f94bbc50072a..f9ec6aa5fb83 100644 --- a/cppcanvas/source/inc/canvasgraphichelper.hxx +++ b/cppcanvas/source/inc/canvasgraphichelper.hxx @@ -4,9 +4,9 @@ * * $RCSfile: canvasgraphichelper.hxx,v $ * - * $Revision: 1.5 $ + * $Revision: 1.6 $ * - * last change: $Author: kz $ $Date: 2005-11-02 13:39:11 $ + * last change: $Author: obo $ $Date: 2007-07-17 15:23:50 $ * * The Contents of this file are made available subject to * the terms of GNU Lesser General Public License Version 2.1. @@ -36,15 +36,13 @@ #ifndef _CPPCANVAS_CANVASGRAPHICHELPER_HXX #define _CPPCANVAS_CANVASGRAPHICHELPER_HXX -#ifndef _COM_SUN_STAR_RENDERING_RENDERSTATE_HPP__ #include <com/sun/star/rendering/RenderState.hpp> -#endif -#ifndef _BGFX_POLYGON_B2DPOLYPOLYGON_HXX #include <basegfx/polygon/b2dpolypolygon.hxx> -#endif #include <cppcanvas/canvasgraphic.hxx> +#include <boost/optional.hpp> + namespace com { namespace sun { namespace star { namespace rendering { class XGraphicDevice; @@ -65,14 +63,15 @@ namespace cppcanvas CanvasGraphicHelper( const CanvasSharedPtr& rParentCanvas ); // CanvasGraphic implementation - virtual void setTransformation( const ::basegfx::B2DHomMatrix& rMatrix ); - virtual ::basegfx::B2DHomMatrix getTransformation() const; - virtual void setClip( const ::basegfx::B2DPolyPolygon& rClipPoly ); - virtual ::basegfx::B2DPolyPolygon getClip() const; - virtual void setRGBAColor( Color::IntSRGBA ); - virtual Color::IntSRGBA getRGBAColor() const; - virtual void setCompositeOp( CompositeOp aOp ); - virtual CompositeOp getCompositeOp() const; + virtual void setTransformation( const ::basegfx::B2DHomMatrix& rMatrix ); + virtual ::basegfx::B2DHomMatrix getTransformation() const; + virtual void setClip( const ::basegfx::B2DPolyPolygon& rClipPoly ); + virtual void setClip(); + virtual ::basegfx::B2DPolyPolygon const* getClip() const; + virtual void setRGBAColor( Color::IntSRGBA ); + virtual Color::IntSRGBA getRGBAColor() const; + virtual void setCompositeOp( CompositeOp aOp ); + virtual CompositeOp getCompositeOp() const; protected: // for our clients @@ -84,7 +83,7 @@ namespace cppcanvas private: mutable ::com::sun::star::rendering::RenderState maRenderState; - ::basegfx::B2DPolyPolygon maClipPolyPolygon; + boost::optional<basegfx::B2DPolyPolygon> maClipPolyPolygon; CanvasSharedPtr mpCanvas; ::com::sun::star::uno::Reference< ::com::sun::star::rendering::XGraphicDevice > mxGraphicDevice; }; |