1 /*************************************************************************
2  *
3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4  *
5  * Copyright 2000, 2010 Oracle and/or its affiliates.
6  *
7  * OpenOffice.org - a multi-platform office productivity suite
8  *
9  * This file is part of OpenOffice.org.
10  *
11  * OpenOffice.org is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * OpenOffice.org is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU Lesser General Public License version 3 for more details
19  * (a copy is included in the LICENSE file that accompanied this code).
20  *
21  * You should have received a copy of the GNU Lesser General Public License
22  * version 3 along with OpenOffice.org.  If not, see
23  * <http://www.openoffice.org/license.html>
24  * for a copy of the LGPLv3 License.
25  *
26  ************************************************************************/
27 
28 #ifndef _CANVAS_IMPLTEXT_HXX
29 #define _CANVAS_IMPLTEXT_HXX
30 
31 #ifndef _COM_SUN_STAR_RENDERING_RENDERSTATE_HPP__
32 #include <com/sun/star/rendering/RenderState.hpp>
33 #endif
34 #ifndef _COM_SUN_STAR_RENDERING_STRINGCONTEXT_HPP__
35 #include <com/sun/star/rendering/StringContext.hpp>
36 #endif
37 #ifndef _COM_SUN_STAR_RENDERING_XCANVAS_HPP__
38 #include <com/sun/star/rendering/XCanvas.hpp>
39 #endif
40 #ifndef _COM_SUN_STAR_RENDERING_XCANVASFONT_HPP__
41 #include <com/sun/star/rendering/XCanvasFont.hpp>
42 #endif
43 
44 #include <cppcanvas/text.hxx>
45 #include <canvasgraphichelper.hxx>
46 
47 
48 namespace cppcanvas
49 {
50     namespace internal
51     {
52 
53         class ImplText : public virtual ::cppcanvas::Text, protected CanvasGraphicHelper
54         {
55         public:
56 
57             ImplText( const CanvasSharedPtr& 	rParentCanvas,
58                       const ::rtl::OUString&	rText );
59 
60             virtual ~ImplText();
61 
62             virtual bool draw() const;
63 
64             virtual void setFont( const FontSharedPtr& );
65             virtual FontSharedPtr getFont();
66 
67         private:
68             // default: disabled copy/assignment
69             ImplText(const ImplText&);
70             ImplText& operator= ( const ImplText& );
71 
72             FontSharedPtr		mpFont;
73             ::rtl::OUString		maText;
74         };
75     }
76 }
77 
78 #endif /* _CANVAS_IMPLTEXT_HXX */
79