merge the formfield patch from ooo-build
[ooovba.git] / binfilter / inc / bf_svx / svdfield.hxx
blob84c015f49db866f5cbd33c0eb3bf999feb0b808f
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: svdfield.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 ************************************************************************/
31 #ifndef _SVDFIELD_HXX
32 #define _SVDFIELD_HXX
34 #ifndef _FLDITEM_HXX
35 #ifndef ITEMID_FIELD
36 #ifndef _EDITDATA_HXX
37 #include <bf_svx/editdata.hxx> /* das include wird wg. EE_FEATURE_FIELD benoetigt */
38 #endif
39 #define ITEMID_FIELD EE_FEATURE_FIELD /* wird fuer #include <bf_svx/flditem.hxx> benoetigt */
40 #endif
41 #include <bf_svx/flditem.hxx>
42 #endif
43 namespace binfilter {
45 ////////////////////////////////////////////////////////////////////////////////////////////////////
46 // Do not remove this, it is still used in src536a!
47 void SdrRegisterFieldClasses();
48 ////////////////////////////////////////////////////////////////////////////////////////////////////
50 #define SDR_MEASUREFIELD 50
52 class SdrMeasureObj;
54 enum SdrMeasureFieldKind {SDRMEASUREFIELD_VALUE,SDRMEASUREFIELD_UNIT,SDRMEASUREFIELD_ROTA90BLANCS};
56 class SdrMeasureField: public SvxFieldData {
57 SdrMeasureFieldKind eMeasureFieldKind;
58 public:
59 SV_DECL_PERSIST1(SdrMeasureField,SvxFieldData,SDR_MEASUREFIELD)
60 SdrMeasureField(): eMeasureFieldKind(SDRMEASUREFIELD_VALUE) {}
61 SdrMeasureField(SdrMeasureFieldKind eNewKind): eMeasureFieldKind(eNewKind) {}
62 virtual ~SdrMeasureField();
63 virtual SvxFieldData* Clone() const;
64 virtual int operator==(const SvxFieldData&) const;
65 SdrMeasureFieldKind GetMeasureFieldKind() const { return eMeasureFieldKind; }
66 void SetMeasureFieldKind(SdrMeasureFieldKind eNewKind) { eMeasureFieldKind=eNewKind; }
67 void TakeRepresentation(const SdrMeasureObj& rObj, XubString& rStr) const;
70 ////////////////////////////////////////////////////////////////////////////////////////////////////
72 }//end of namespace binfilter
73 #endif //_SVDFIELD_HXX