merge the formfield patch from ooo-build
[ooovba.git] / sd / inc / sdattr.hxx
blob99dca48068e5a990e6bf73b3c507754459d01ebc
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: sdattr.hxx,v $
10 * $Revision: 1.5 $
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 ************************************************************************/
31 #ifndef _SDATTR_HXX
32 #define _SDATTR_HXX
34 #include <com/sun/star/presentation/FadeEffect.hpp>
35 #include <svtools/intitem.hxx>
36 #include <svtools/eitem.hxx>
37 #include <svtools/stritem.hxx>
38 #include <sfx2/sfx.hrc>
40 #ifndef _SDATTR_HRC
41 #include "sdattr.hrc"
42 #endif
43 #include "glob.hxx"
44 #include "fadedef.h"
45 #include "diadef.h"
47 //------------------------------------------------------------------
50 //==================================================================
51 // Layer-Attribute
52 //==================================================================
54 class SdAttrLayerName : public SfxStringItem
56 public:
57 SdAttrLayerName() :
58 SfxStringItem( ATTR_LAYER_NAME, String( RTL_CONSTASCII_USTRINGPARAM( "neue Ebene" ))) {}
59 SdAttrLayerName( const String& aStr ) :
60 SfxStringItem( ATTR_LAYER_NAME, aStr ) {}
63 //------------------------------------------------------------------
65 class SdAttrLayerTitle : public SfxStringItem
67 public:
68 SdAttrLayerTitle() : SfxStringItem( ATTR_LAYER_TITLE, XubString()) {}
69 SdAttrLayerTitle( const String& aStr ) : SfxStringItem( ATTR_LAYER_TITLE, aStr ) {}
72 //------------------------------------------------------------------
74 class SdAttrLayerDesc : public SfxStringItem
76 public:
77 SdAttrLayerDesc() : SfxStringItem( ATTR_LAYER_DESC, XubString()) {}
78 SdAttrLayerDesc( const String& aStr ) : SfxStringItem( ATTR_LAYER_DESC, aStr ) {}
81 //------------------------------------------------------------------
83 class SdAttrLayerVisible : public SfxBoolItem
85 public:
86 SdAttrLayerVisible( BOOL bValue = TRUE ) :
87 SfxBoolItem( ATTR_LAYER_VISIBLE, bValue ) {}
90 //------------------------------------------------------------------
92 class SdAttrLayerPrintable : public SfxBoolItem
94 public:
95 SdAttrLayerPrintable( BOOL bValue = TRUE ) :
96 SfxBoolItem( ATTR_LAYER_PRINTABLE, bValue ) {}
99 //------------------------------------------------------------------
101 class SdAttrLayerLocked : public SfxBoolItem
103 public:
104 SdAttrLayerLocked( BOOL bValue = FALSE ) :
105 SfxBoolItem( ATTR_LAYER_LOCKED, bValue ) {}
108 //------------------------------------------------------------------
110 class SdAttrLayerThisPage : public SfxBoolItem
112 public:
113 SdAttrLayerThisPage( BOOL bValue = FALSE ) :
114 SfxBoolItem( ATTR_LAYER_THISPAGE, bValue ) {}
117 //------------------------------------------------------------------
119 class DiaEffectItem : public SfxEnumItem
121 public:
122 TYPEINFO();
123 DiaEffectItem( ::com::sun::star::presentation::FadeEffect eFade = com::sun::star::presentation::FadeEffect_NONE );
124 DiaEffectItem( SvStream& rIn );
126 virtual SfxPoolItem* Clone( SfxItemPool* pPool = 0 ) const;
127 virtual SfxPoolItem* Create( SvStream& rIn, USHORT nVer ) const;
128 USHORT GetValueCount() const { return FADE_EFFECT_COUNT; }
129 ::com::sun::star::presentation::FadeEffect GetValue() const
130 { return (::com::sun::star::presentation::FadeEffect) SfxEnumItem::GetValue(); }
133 //------------------------------------------------------------------
135 class DiaSpeedItem : public SfxEnumItem
137 public:
138 TYPEINFO();
139 DiaSpeedItem( FadeSpeed = FADE_SPEED_MEDIUM );
140 DiaSpeedItem( SvStream& rIn );
142 virtual SfxPoolItem* Clone( SfxItemPool* pPool = 0 ) const;
143 virtual SfxPoolItem* Create( SvStream& rIn, USHORT nVer ) const;
144 USHORT GetValueCount() const { return FADE_SPEED_COUNT; }
145 FadeSpeed GetValue() const
146 { return (FadeSpeed) SfxEnumItem::GetValue(); }
149 //------------------------------------------------------------------
151 class DiaAutoItem : public SfxEnumItem
153 public:
154 TYPEINFO();
155 DiaAutoItem( PresChange = PRESCHANGE_MANUAL );
156 DiaAutoItem( SvStream& rIn );
158 virtual SfxPoolItem* Clone( SfxItemPool* pPool = 0 ) const;
159 virtual SfxPoolItem* Create( SvStream& rIn, USHORT nVer ) const;
160 USHORT GetValueCount() const { return PRESCHANGE_COUNT; }
161 PresChange GetValue() const { return (PresChange) SfxEnumItem::GetValue(); }
164 //------------------------------------------------------------------
166 class DiaTimeItem : public SfxUInt32Item
168 public:
169 TYPEINFO();
170 DiaTimeItem( UINT32 nValue = 0L );
172 virtual SfxPoolItem* Clone( SfxItemPool* pPool = 0 ) const;
173 virtual int operator==( const SfxPoolItem& ) const;
176 #endif // _SDATTR_HXX