1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: elements.hxx,v $
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 CGM_ELEMENTS_HXX_
31 #define CGM_ELEMENTS_HXX_
34 #include <tools/table.hxx>
36 #define nBackGroundColor aColorTable[ 0 ]
40 void ImplInsertHatch( sal_Int32 Key
, int Style
, long Distance
, long Angle
);
43 long nMetaFileVersion
;
45 sal_uInt32 nIntegerPrecision
; // maybe 1, 2, 4 Bytes
46 sal_uInt32 nIndexPrecision
; // " " "
47 RealPrecision eRealPrecision
;
48 sal_uInt32 nRealSize
; // maybe 4 or 8 bytes
49 sal_uInt32 nColorPrecision
; // " " "
50 sal_uInt32 nColorIndexPrecision
;// " " "
52 ScalingMode eScalingMode
;
53 double nScalingFactor
;
55 VDCType eVDCType
; // Integer / Real
56 sal_uInt32 nVDCIntegerPrecision
;
57 RealPrecision eVDCRealPrecision
;
58 sal_uInt32 nVDCRealSize
;
60 FloatRect aVDCExtentMaximum
;
62 DeviceViewPortMode eDeviceViewPortMode
;
63 double nDeviceViewPortScale
;
64 DeviceViewPortMap eDeviceViewPortMap
;
65 DeviceViewPortMapH eDeviceViewPortMapH
;
66 DeviceViewPortMapV eDeviceViewPortMapV
;
67 FloatRect aDeviceViewPort
;
71 ClipIndicator eClipIndicator
;
74 ColorSelectionMode eColorSelectionMode
;
75 ColorModel eColorModel
;
76 sal_uInt32 nColorMaximumIndex
; // default 63
77 sal_uInt32 nLatestColorMaximumIndex
; // default 63
78 sal_Int8 aColorTableEntryIs
[ 256 ];
79 sal_uInt32 aColorTable
[ 256 ];
80 sal_uInt32 aLatestColorTable
[ 256 ];
81 sal_uInt32 nColorValueExtent
[ 8 ]; // RGB, CMYK
83 // ASPECT SOURCE FLAGS
84 sal_uInt32 nAspectSourceFlags
; // bit = 0 -> INDIVIDUAL
87 LineBundle
* pLineBundle
; // Pointer to the current LineBundleIndex
88 LineBundle aLineBundle
;
90 SpecMode eLineWidthSpecMode
;
91 LineCapType eLineCapType
;
92 LineJoinType eLineJoinType
;
94 MarkerBundle
* pMarkerBundle
; // Pointer to the current MarkerBundleIndex
95 MarkerBundle aMarkerBundle
;
97 SpecMode eMarkerSizeSpecMode
;
99 EdgeBundle
* pEdgeBundle
; // Pointer to the current EdgeBundleIndex
100 EdgeBundle aEdgeBundle
;
102 EdgeVisibility eEdgeVisibility
;
103 SpecMode eEdgeWidthSpecMode
;
105 TextBundle
* pTextBundle
; // Pointer to the current TextBundleIndex
106 TextBundle aTextBundle
;
108 double nCharacterHeight
;
109 double nCharacterOrientation
[ 4 ];
110 UnderlineMode eUnderlineMode
;
111 sal_uInt32 nUnderlineColor
;
113 TextAlignmentH eTextAlignmentH
;
114 TextAlignmentV eTextAlignmentV
;
115 double nTextAlignmentHCont
;
116 double nTextAlignmentVCont
;
117 long nCharacterSetIndex
;
118 long nAlternateCharacterSetIndex
;
119 CharacterCodingA eCharacterCodingA
;
122 FillBundle
* pFillBundle
; // Pointer to the current EdgeBundleIndex
123 FillBundle aFillBundle
;
125 FloatPoint aFillRefPoint
;
128 Transparency eTransparency
;
130 sal_uInt32 nAuxiliaryColor
;
132 // Delimiter Counts -> which will be increased by each 'begin' operation
133 // and decreased by each 'end' operation
134 sal_Bool bSegmentCount
;
135 CGMElements( CGM
& rCGM
);
137 CGMElements
& operator=( CGMElements
& );
139 void DeleteTable( Table
& );
140 Bundle
* GetBundleIndex( sal_uInt32 nIndex
, List
&, Bundle
& );
141 Bundle
* GetBundle( List
& rList
, long nIndex
);
142 Bundle
* InsertBundle( List
&, Bundle
& );
143 void DeleteAllBundles( List
& );
144 void CopyAllBundles( List
& Source
, List
& Dest
);