Update ooo320-m1
[ooovba.git] / svx / inc / svx / pageitem.hxx
blob79f9f6443d5c5340d56b67a15c0848014d62c44f
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: pageitem.hxx,v $
10 * $Revision: 1.4 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef _SVX_PAGEITEM_HXX
31 #define _SVX_PAGEITEM_HXX
33 // include ---------------------------------------------------------------
35 #include <svtools/poolitem.hxx>
36 #include <tools/string.hxx>
37 #include "svx/svxdllapi.h"
40 /*--------------------------------------------------------------------
41 Beschreibung: SvxNumType
42 --------------------------------------------------------------------*/
44 enum SvxNumType
46 SVX_CHARS_UPPER_LETTER,
47 SVX_CHARS_LOWER_LETTER,
48 SVX_ROMAN_UPPER,
49 SVX_ROMAN_LOWER,
50 SVX_ARABIC,
51 SVX_NUMBER_NONE,
52 SVX_CHAR_SPECIAL,
53 SVX_PAGEDESC
56 /*--------------------------------------------------------------------
57 Beschreibung: Benutzung der Seite
58 --------------------------------------------------------------------*/
60 enum SvxPageUsage
62 SVX_PAGE_LEFT = 0x0001,
63 SVX_PAGE_RIGHT = 0x0002,
64 SVX_PAGE_ALL = 0x0003,
65 SVX_PAGE_MIRROR = 0x0007,
66 SVX_PAGE_HEADERSHARE = 0x0040,
67 SVX_PAGE_FOOTERSHARE = 0x0080
70 /*--------------------------------------------------------------------
71 Beschreibung: Teile der Seitenbeschreibung
72 --------------------------------------------------------------------*/
77 [Beschreibung]
78 Dieses Item beschreibt ein Seiten-Attribut (Name der Vorlage, Numerierung,
79 Portrait oder Landscape, Layout).
82 class SVX_DLLPUBLIC SvxPageItem: public SfxPoolItem
84 private:
85 String aDescName; // Name der Vorlage
86 SvxNumType eNumType; // Numerierung
87 BOOL bLandscape; // Portrait / Landscape
88 USHORT eUse; // Layout
90 public:
92 TYPEINFO();
93 SvxPageItem( const USHORT nId );
94 SvxPageItem( const SvxPageItem& rItem );
96 virtual SfxPoolItem* Clone( SfxItemPool *pPool = 0 ) const;
97 virtual int operator==( const SfxPoolItem& ) const;
99 virtual SfxItemPresentation GetPresentation( SfxItemPresentation ePres,
100 SfxMapUnit eCoreMetric,
101 SfxMapUnit ePresMetric,
102 String &rText, const IntlWrapper * = 0 ) const;
104 virtual sal_Bool QueryValue( com::sun::star::uno::Any& rVal, BYTE nMemberId = 0 ) const;
105 virtual sal_Bool PutValue( const com::sun::star::uno::Any& rVal, BYTE nMemberId = 0 );
106 virtual SfxPoolItem* Create( SvStream&, USHORT ) const;
107 virtual SvStream& Store( SvStream& , USHORT nItemVersion ) const;
109 // Ausrichtung
110 USHORT GetPageUsage() const { return eUse; }
111 void SetPageUsage(USHORT eU) { eUse= eU; }
113 BOOL IsLandscape() const { return bLandscape; }
114 void SetLandscape(BOOL bL) { bLandscape = bL; }
116 // Numerierung
117 SvxNumType GetNumType() const { return eNumType; }
118 void SetNumType(SvxNumType eNum) { eNumType = eNum; }
120 // Name des Descriptors
121 const String& GetDescName() const { return aDescName; }
122 void SetDescName(const String& rStr) { aDescName = rStr; }
127 /*--------------------------------------------------------------------
128 Beschreibung: Container fuer Header/Footer-Attribute
129 --------------------------------------------------------------------*/
134 [Beschreibung]
135 Dieses Item dient als Container fuer Header- und Footer-Attribute.
138 class SVX_DLLPUBLIC SvxSetItem: public SfxSetItem
140 public:
141 SvxSetItem( const USHORT nId, const SfxItemSet& rSet );
142 SvxSetItem( const SvxSetItem& rItem );
143 SvxSetItem( const USHORT nId, SfxItemSet* pSet );
145 virtual SfxPoolItem* Clone( SfxItemPool *pPool = 0 ) const;
147 virtual SfxItemPresentation GetPresentation( SfxItemPresentation ePres,
148 SfxMapUnit eCoreMetric,
149 SfxMapUnit ePresMetric,
150 String &rText, const IntlWrapper * = 0 ) const;
152 virtual SfxPoolItem* Create( SvStream&, USHORT nVersion ) const;
153 virtual SvStream& Store( SvStream&, USHORT nItemVersion ) const;
159 #endif