xref: /aoo42x/main/sw/source/core/inc/notxtfrm.hxx (revision 1d2dbeb0)
1 /**************************************************************
2  *
3  * Licensed to the Apache Software Foundation (ASF) under one
4  * or more contributor license agreements.  See the NOTICE file
5  * distributed with this work for additional information
6  * regarding copyright ownership.  The ASF licenses this file
7  * to you under the Apache License, Version 2.0 (the
8  * "License"); you may not use this file except in compliance
9  * with the License.  You may obtain a copy of the License at
10  *
11  *   http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing,
14  * software distributed under the License is distributed on an
15  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16  * KIND, either express or implied.  See the License for the
17  * specific language governing permissions and limitations
18  * under the License.
19  *
20  *************************************************************/
21 
22 
23 #ifndef SW_NOTXTFRM_HXX
24 #define SW_NOTXTFRM_HXX
25 
26 #include <cntfrm.hxx>
27 
28 class SwNoTxtNode;
29 class OutputDevice;
30 class SwBorderAttrs;
31 class Bitmap;
32 struct SwCrsrMoveState;
33 
34 class SwNoTxtFrm: public SwCntntFrm
35 {
36     friend void _FrmFinit();
37 
38 	short	 nWeight;					// "Wichtigkeit" der Grafik
39 
40 	const Size& GetSize() const;
41 
42 	void InitCtor();
43 
44 	void Format ( const SwBorderAttrs *pAttrs = 0 );
45 	void PaintCntnt  ( OutputDevice*, const SwRect&, const SwRect& ) const;
46     /// OD 25.09.2002 #99739# - delete unused 3rd parameter
47     void PaintPicture( OutputDevice*, const SwRect& ) const;
48 protected:
49 	virtual void MakeAll();
50 	virtual void Modify( const SfxPoolItem*, const SfxPoolItem* );
51 public:
52 	SwNoTxtFrm( SwNoTxtNode * const, SwFrm* );
53 	~SwNoTxtFrm();
54 
55     virtual void Paint( SwRect const&,
56                         SwPrintData const*const pPrintData = NULL ) const;
57 	virtual sal_Bool GetCharRect( SwRect &, const SwPosition&,
58 							  SwCrsrMoveState* = 0) const;
59 	sal_Bool GetCrsrOfst(SwPosition* pPos, Point& aPoint,
60                      SwCrsrMoveState* = 0) const;
61 
GetGrfSize() const62 	const Size &GetGrfSize() const	{ return GetSize(); }
63 	void GetGrfArea( SwRect &rRect, SwRect * = 0, sal_Bool bMirror = sal_True ) const;
64 
65 	sal_Bool IsTransparent() const;
66 
67 	void StopAnimation( OutputDevice* = 0 ) const;
68 	sal_Bool HasAnimation()  const;
69 
70 	// Routinen fuer den Grafik-Cache
GetWeight()71 	sal_uInt16 GetWeight() { return nWeight; }
72 };
73 
74 #endif
75 
76