merge the formfield patch from ooo-build
[ooovba.git] / lotuswordpro / source / filter / lwpparaproperty.hxx
blob66ef2d3549d5ff4d9e7f9df1ca285891e7ed7e08
1 /*************************************************************************
3 * The Contents of this file are made available subject to the terms of
4 * either of the following licenses
6 * - GNU Lesser General Public License Version 2.1
7 * - Sun Industry Standards Source License Version 1.1
9 * Sun Microsystems Inc., October, 2000
11 * GNU Lesser General Public License Version 2.1
12 * =============================================
13 * Copyright 2000 by Sun Microsystems, Inc.
14 * 901 San Antonio Road, Palo Alto, CA 94303, USA
16 * This library is free software; you can redistribute it and/or
17 * modify it under the terms of the GNU Lesser General Public
18 * License version 2.1, as published by the Free Software Foundation.
20 * This library is distributed in the hope that it will be useful,
21 * but WITHOUT ANY WARRANTY; without even the implied warranty of
22 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
23 * Lesser General Public License for more details.
25 * You should have received a copy of the GNU Lesser General Public
26 * License along with this library; if not, write to the Free Software
27 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
28 * MA 02111-1307 USA
31 * Sun Industry Standards Source License Version 1.1
32 * =================================================
33 * The contents of this file are subject to the Sun Industry Standards
34 * Source License Version 1.1 (the "License"); You may not use this file
35 * except in compliance with the License. You may obtain a copy of the
36 * License at http://www.openoffice.org/license.html.
38 * Software provided under this License is provided on an "AS IS" basis,
39 * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
40 * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
41 * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
42 * See the License for the specific provisions governing your rights and
43 * obligations concerning the Software.
45 * The Initial Developer of the Original Code is: IBM Corporation
47 * Copyright: 2008 by IBM Corporation
49 * All Rights Reserved.
51 * Contributor(s): _______________________________________
54 ************************************************************************/
55 /*************************************************************************
56 * @file
57 * For LWP filter architecture prototype
58 ************************************************************************/
59 /*************************************************************************
60 * Change History
61 Jan 2005 Created
62 ************************************************************************/
63 #ifndef _LWPPARAPROPERTY_HXX_
64 #define _LWPPARAPROPERTY_HXX_
66 #include "lwpobj.hxx"
67 #include "lwpobjstrm.hxx"
68 #include "lwpdllist.hxx"
70 #include "lwpoverride.hxx"
71 #include "lwppiece.hxx"
73 /* paragraph property ID's */
74 #define PP_OUTLINE_SHOW 0x53484f4cUL /* "SHOW" */
75 #define PP_OUTLINE_HIDE 0x48494445UL /* "HIDE" */
76 #define PP_LOCAL_ALIGN 0x414c494eUL /* "ALIN" */
77 #define PP_LOCAL_INDENT 0x494e444eUL /* "INDN" */
78 #define PP_LOCAL_SPACING 0x5350434eUL /* "SPCN" */
79 #define PP_LOCAL_TABRACK 0x54414253UL /* "TABS" */
80 #define PP_LOCAL_BREAKS 0x42524b53UL /* "BRKS" */
81 #define PP_LOCAL_BULLET 0x42554c4cUL /* "BULL" */
82 #define PP_LOCAL_BORDER 0x424f5244UL /* "BORD" */
83 #define PP_LOCAL_BACKGROUND 0x4241434bUL /* "BACK" */
84 #define PP_LOCAL_NUMBERING 0x4e4d4252UL /* "NMBR" */
85 #define PP_LOCAL_KINSOKU 0x4b494e53UL /* "KINS" */
86 #define PP_PROPLIST 0x50524f50UL /* "PROP" */
88 class LwpParaProperty : public LwpDLList
90 public:
91 LwpParaProperty(){};
92 virtual ~LwpParaProperty(void){};
93 virtual sal_uInt32 GetType(void) = 0;
94 inline LwpParaProperty* GetNext(void);
95 inline LwpParaProperty* GetPrevious(void);
97 static LwpParaProperty* ReadPropertyList(LwpObjectStream* pFile,LwpObject* Whole);
101 inline LwpParaProperty* LwpParaProperty::GetNext(void)
103 return static_cast<LwpParaProperty*>(LwpDLList::GetNext());
106 inline LwpParaProperty* LwpParaProperty::GetPrevious(void)
108 return static_cast<LwpParaProperty*>(LwpDLList::GetPrevious());
111 //align/indent/spacing
112 //TO DO:border/backgroud etc
115 class LwpParaAlignProperty : public LwpParaProperty
117 public:
118 // LwpParaAlignProperty(LwpParaAlignProperty* pOther);
119 LwpParaAlignProperty(LwpObjectStream* pFile);
120 virtual ~LwpParaAlignProperty(void);
121 LwpAlignmentOverride* GetAlignment(void);
122 sal_uInt32 GetType(void);
124 private:
125 // LwpAlignmentPiece m_Alignment;
126 LwpAlignmentOverride* m_pAlignment;
129 inline LwpAlignmentOverride* LwpParaAlignProperty::GetAlignment(void)
131 // return static_cast<LwpAlignmentOverride*>(m_Alignment.m_pOverride);
132 return m_pAlignment; //add by 1-24
135 class LwpParaIndentProperty : public LwpParaProperty
137 public:
138 LwpParaIndentProperty(LwpObjectStream* pFile);
139 virtual ~LwpParaIndentProperty(void);
140 LwpIndentOverride* GetIndent(void);
141 sal_uInt32 GetType(void);
142 //add by , 03/22/2005
143 inline LwpObjectID GetIndentID();
144 //end add
146 private:
147 //add by , 03/22/2005
148 LwpObjectID m_aIndentID;
149 //end add
150 LwpIndentOverride* m_pIndent;
152 inline LwpObjectID LwpParaIndentProperty::GetIndentID()
154 return m_aIndentID;
156 inline LwpIndentOverride* LwpParaIndentProperty::GetIndent(void)
158 return m_pIndent;
161 class LwpParaSpacingProperty : public LwpParaProperty
163 public:
164 LwpParaSpacingProperty(LwpObjectStream* pFile);
165 virtual ~LwpParaSpacingProperty(void);
166 LwpSpacingOverride* GetSpacing(void);
167 sal_uInt32 GetType(void);
168 private:
169 LwpSpacingOverride* m_pSpacing;
173 inline LwpSpacingOverride* LwpParaSpacingProperty::GetSpacing(void)
175 return m_pSpacing;
178 //add by , 01/25/2005////////////////////////////////////////////
179 class LwpParaBorderOverride;
180 class LwpParaBorderProperty : public LwpParaProperty
182 public:
183 LwpParaBorderProperty(LwpObjectStream* pStrm);
185 inline sal_uInt32 GetType();
187 inline LwpParaBorderOverride* GetLocalParaBorder();
189 private:
190 LwpParaBorderOverride* m_pParaBorderOverride;
193 inline LwpParaBorderOverride* LwpParaBorderProperty::GetLocalParaBorder()
195 return m_pParaBorderOverride;
198 inline sal_uInt32 LwpParaBorderProperty::GetType()
200 return PP_LOCAL_BORDER;
203 class LwpParaBreaksProperty : public LwpParaProperty
205 public:
206 LwpParaBreaksProperty(LwpObjectStream* pStrm);
208 inline sal_uInt32 GetType();
210 inline LwpBreaksOverride* GetLocalParaBreaks();
212 private:
213 LwpBreaksOverride* m_pBreaks;
217 inline sal_uInt32 LwpParaBreaksProperty::GetType()
219 return PP_LOCAL_BREAKS;
221 inline LwpBreaksOverride* LwpParaBreaksProperty::GetLocalParaBreaks()
223 return m_pBreaks;
227 class LwpParaBulletProperty : public LwpParaProperty
229 public:
230 LwpParaBulletProperty(LwpObjectStream* pStrm);
232 virtual ~LwpParaBulletProperty();
234 inline sal_uInt32 GetType();
236 inline LwpBulletOverride* GetLocalParaBullet();
238 private:
239 LwpBulletOverride* m_pBullet;
242 inline sal_uInt32 LwpParaBulletProperty::GetType()
244 return PP_LOCAL_BULLET;
246 inline LwpBulletOverride* LwpParaBulletProperty::GetLocalParaBullet()
248 return m_pBullet;
252 class LwpParaNumberingProperty : public LwpParaProperty
254 public:
255 LwpParaNumberingProperty(LwpObjectStream* pStrm);
257 inline sal_uInt32 GetType();
259 inline LwpNumberingOverride* GetLocalNumbering() const;
260 private:
261 LwpNumberingOverride* m_pNumberingOverride;
263 inline sal_uInt32 LwpParaNumberingProperty::GetType()
265 return PP_LOCAL_NUMBERING;
267 inline LwpNumberingOverride* LwpParaNumberingProperty::GetLocalNumbering() const
269 return m_pNumberingOverride;
271 //end add/////////////////////////////////////////////////////////////
274 class LwpParaTabRackProperty : public LwpParaProperty
276 public:
277 LwpParaTabRackProperty(LwpObjectStream* pStrm);
278 ~LwpParaTabRackProperty(void);
279 inline sal_uInt32 GetType();
281 inline LwpTabOverride* GetTab(); //should add by , note by 1/28
283 private:
284 LwpTabOverride* m_pTabOverride;
287 inline LwpTabOverride* LwpParaTabRackProperty::GetTab()
289 return m_pTabOverride;
292 inline sal_uInt32 LwpParaTabRackProperty::GetType(void)
294 return PP_LOCAL_TABRACK;
298 class LwpParaBackGroundProperty : public LwpParaProperty
300 public:
301 LwpParaBackGroundProperty(LwpObjectStream* pFile);
302 virtual ~LwpParaBackGroundProperty(void);
303 LwpBackgroundOverride* GetBackground(void);
304 sal_uInt32 GetType(void);
305 private:
306 LwpBackgroundOverride* m_pBackground;
309 inline LwpBackgroundOverride* LwpParaBackGroundProperty::GetBackground(void)
311 return m_pBackground;
314 inline sal_uInt32 LwpParaBackGroundProperty::GetType()
316 return PP_LOCAL_BACKGROUND;
319 #endif