1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*************************************************************************
4 * The Contents of this file are made available subject to the terms of
5 * either of the following licenses
7 * - GNU Lesser General Public License Version 2.1
8 * - Sun Industry Standards Source License Version 1.1
10 * Sun Microsystems Inc., October, 2000
12 * GNU Lesser General Public License Version 2.1
13 * =============================================
14 * Copyright 2000 by Sun Microsystems, Inc.
15 * 901 San Antonio Road, Palo Alto, CA 94303, USA
17 * This library is free software; you can redistribute it and/or
18 * modify it under the terms of the GNU Lesser General Public
19 * License version 2.1, as published by the Free Software Foundation.
21 * This library is distributed in the hope that it will be useful,
22 * but WITHOUT ANY WARRANTY; without even the implied warranty of
23 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
24 * Lesser General Public License for more details.
26 * You should have received a copy of the GNU Lesser General Public
27 * License along with this library; if not, write to the Free Software
28 * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
32 * Sun Industry Standards Source License Version 1.1
33 * =================================================
34 * The contents of this file are subject to the Sun Industry Standards
35 * Source License Version 1.1 (the "License"); You may not use this file
36 * except in compliance with the License. You may obtain a copy of the
37 * License at http://www.openoffice.org/license.html.
39 * Software provided under this License is provided on an "AS IS" basis,
40 * WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING,
41 * WITHOUT LIMITATION, WARRANTIES THAT THE SOFTWARE IS FREE OF DEFECTS,
42 * MERCHANTABLE, FIT FOR A PARTICULAR PURPOSE, OR NON-INFRINGING.
43 * See the License for the specific provisions governing your rights and
44 * obligations concerning the Software.
46 * The Initial Developer of the Original Code is: IBM Corporation
48 * Copyright: 2008 by IBM Corporation
50 * All Rights Reserved.
52 * Contributor(s): _______________________________________
55 ************************************************************************/
56 /*************************************************************************
58 * For LWP filter architecture prototype
59 ************************************************************************/
60 /*************************************************************************
63 ************************************************************************/
64 #ifndef INCLUDED_LOTUSWORDPRO_SOURCE_FILTER_LWPPARAPROPERTY_HXX
65 #define INCLUDED_LOTUSWORDPRO_SOURCE_FILTER_LWPPARAPROPERTY_HXX
68 #include "lwpobjstrm.hxx"
69 #include "lwpdllist.hxx"
71 #include "lwpoverride.hxx"
72 #include "lwppiece.hxx"
74 /* paragraph property ID's */
75 #define PP_OUTLINE_SHOW 0x53484f4cUL /* "SHOW" */
76 #define PP_OUTLINE_HIDE 0x48494445UL /* "HIDE" */
77 #define PP_LOCAL_ALIGN 0x414c494eUL /* "ALIN" */
78 #define PP_LOCAL_INDENT 0x494e444eUL /* "INDN" */
79 #define PP_LOCAL_SPACING 0x5350434eUL /* "SPCN" */
80 #define PP_LOCAL_TABRACK 0x54414253UL /* "TABS" */
81 #define PP_LOCAL_BREAKS 0x42524b53UL /* "BRKS" */
82 #define PP_LOCAL_BULLET 0x42554c4cUL /* "BULL" */
83 #define PP_LOCAL_BORDER 0x424f5244UL /* "BORD" */
84 #define PP_LOCAL_BACKGROUND 0x4241434bUL /* "BACK" */
85 #define PP_LOCAL_NUMBERING 0x4e4d4252UL /* "NMBR" */
86 #define PP_LOCAL_KINSOKU 0x4b494e53UL /* "KINS" */
87 #define PP_PROPLIST 0x50524f50UL /* "PROP" */
89 class LwpParaProperty
: public LwpDLList
93 virtual ~LwpParaProperty(void){}
94 virtual sal_uInt32
GetType(void) = 0;
95 inline LwpParaProperty
* GetNext(void);
96 inline LwpParaProperty
* GetPrevious(void);
98 static LwpParaProperty
* ReadPropertyList(LwpObjectStream
* pFile
,LwpObject
* Whole
);
102 inline LwpParaProperty
* LwpParaProperty::GetNext(void)
104 return static_cast<LwpParaProperty
*>(LwpDLList::GetNext());
107 inline LwpParaProperty
* LwpParaProperty::GetPrevious(void)
109 return static_cast<LwpParaProperty
*>(LwpDLList::GetPrevious());
112 //align/indent/spacing
113 //TO DO:border/backgroud etc
115 class LwpParaAlignProperty
: public LwpParaProperty
118 // LwpParaAlignProperty(LwpParaAlignProperty* pOther);
119 LwpParaAlignProperty(LwpObjectStream
* pFile
);
120 virtual ~LwpParaAlignProperty(void);
121 LwpAlignmentOverride
* GetAlignment(void);
122 sal_uInt32
GetType(void) SAL_OVERRIDE
;
125 LwpAlignmentOverride
* m_pAlignment
;
128 inline LwpAlignmentOverride
* LwpParaAlignProperty::GetAlignment(void)
133 class LwpParaIndentProperty
: public LwpParaProperty
136 LwpParaIndentProperty(LwpObjectStream
* pFile
);
137 virtual ~LwpParaIndentProperty(void);
138 LwpIndentOverride
* GetIndent(void);
139 sal_uInt32
GetType(void) SAL_OVERRIDE
;
140 inline LwpObjectID
GetIndentID();
143 LwpObjectID m_aIndentID
;
144 LwpIndentOverride
* m_pIndent
;
146 inline LwpObjectID
LwpParaIndentProperty::GetIndentID()
150 inline LwpIndentOverride
* LwpParaIndentProperty::GetIndent(void)
155 class LwpParaSpacingProperty
: public LwpParaProperty
158 LwpParaSpacingProperty(LwpObjectStream
* pFile
);
159 virtual ~LwpParaSpacingProperty(void);
160 LwpSpacingOverride
* GetSpacing(void);
161 sal_uInt32
GetType(void) SAL_OVERRIDE
;
163 LwpSpacingOverride
* m_pSpacing
;
167 inline LwpSpacingOverride
* LwpParaSpacingProperty::GetSpacing(void)
172 class LwpParaBorderOverride
;
173 class LwpParaBorderProperty
: public LwpParaProperty
176 LwpParaBorderProperty(LwpObjectStream
* pStrm
);
178 sal_uInt32
GetType() SAL_OVERRIDE
{ return PP_LOCAL_BORDER
; }
180 inline LwpParaBorderOverride
* GetLocalParaBorder();
183 LwpParaBorderOverride
* m_pParaBorderOverride
;
186 inline LwpParaBorderOverride
* LwpParaBorderProperty::GetLocalParaBorder()
188 return m_pParaBorderOverride
;
191 class LwpParaBreaksProperty
: public LwpParaProperty
194 LwpParaBreaksProperty(LwpObjectStream
* pStrm
);
196 sal_uInt32
GetType() SAL_OVERRIDE
{ return PP_LOCAL_BREAKS
; }
198 inline LwpBreaksOverride
* GetLocalParaBreaks();
201 LwpBreaksOverride
* m_pBreaks
;
205 inline LwpBreaksOverride
* LwpParaBreaksProperty::GetLocalParaBreaks()
210 class LwpParaBulletProperty
: public LwpParaProperty
213 LwpParaBulletProperty(LwpObjectStream
* pStrm
);
215 virtual ~LwpParaBulletProperty();
217 sal_uInt32
GetType() SAL_OVERRIDE
{ return PP_LOCAL_BULLET
; }
219 inline LwpBulletOverride
* GetLocalParaBullet();
222 LwpBulletOverride
* m_pBullet
;
225 inline LwpBulletOverride
* LwpParaBulletProperty::GetLocalParaBullet()
230 class LwpParaNumberingProperty
: public LwpParaProperty
233 LwpParaNumberingProperty(LwpObjectStream
* pStrm
);
235 sal_uInt32
GetType() SAL_OVERRIDE
{ return PP_LOCAL_NUMBERING
; }
237 inline LwpNumberingOverride
* GetLocalNumbering() const;
239 LwpNumberingOverride
* m_pNumberingOverride
;
242 inline LwpNumberingOverride
* LwpParaNumberingProperty::GetLocalNumbering() const
244 return m_pNumberingOverride
;
247 class LwpParaTabRackProperty
: public LwpParaProperty
250 LwpParaTabRackProperty(LwpObjectStream
* pStrm
);
251 virtual ~LwpParaTabRackProperty(void);
252 sal_uInt32
GetType() SAL_OVERRIDE
{ return PP_LOCAL_TABRACK
; }
254 inline LwpTabOverride
* GetTab();
257 LwpTabOverride
* m_pTabOverride
;
260 inline LwpTabOverride
* LwpParaTabRackProperty::GetTab()
262 return m_pTabOverride
;
265 class LwpParaBackGroundProperty
: public LwpParaProperty
268 LwpParaBackGroundProperty(LwpObjectStream
* pFile
);
269 virtual ~LwpParaBackGroundProperty(void);
270 LwpBackgroundOverride
* GetBackground(void);
271 sal_uInt32
GetType(void) SAL_OVERRIDE
;
273 LwpBackgroundOverride
* m_pBackground
;
276 inline LwpBackgroundOverride
* LwpParaBackGroundProperty::GetBackground(void)
278 return m_pBackground
;
281 inline sal_uInt32
LwpParaBackGroundProperty::GetType()
283 return PP_LOCAL_BACKGROUND
;
288 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */