blob: c579ebe16fd7de22a07fb2e1c5472d9c0010df35 [file] [log] [blame]
Evan Stade48f10d42007-06-08 13:44:28 -07001/*
2 * Copyright (C) 2007 Google (Evan Stade)
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 */
18
19#ifndef _GDIPLUSENUMS_H
20#define _GDIPLUSENUMS_H
21
Evan Stadec7606682007-07-13 17:51:37 -070022typedef UINT GraphicsState;
23
Evan Stade48f10d42007-06-08 13:44:28 -070024enum Unit
25{
26 UnitWorld = 0,
27 UnitDisplay = 1,
28 UnitPixel = 2,
29 UnitPoint = 3,
30 UnitInch = 4,
31 UnitDocument = 5,
32 UnitMillimeter = 6
33};
34
35enum BrushType
36{
37 BrushTypeSolidColor = 0,
38 BrushTypeHatchFill = 1,
39 BrushTypeTextureFill = 2,
40 BrushTypePathGradient = 3,
41 BrushTypeLinearGradient = 4
42};
43
Evan Stade14802872007-06-21 16:15:17 -070044enum FillMode
45{
46 FillModeAlternate = 0,
47 FillModeWinding = 1
48};
49
Evan Stade68ba30f2007-07-05 18:37:52 -070050enum LineCap
51{
52 LineCapFlat = 0x00,
53 LineCapSquare = 0x01,
54 LineCapRound = 0x02,
55 LineCapTriangle = 0x03,
56
57 LineCapNoAnchor = 0x10,
58 LineCapSquareAnchor = 0x11,
59 LineCapRoundAnchor = 0x12,
60 LineCapDiamondAnchor = 0x13,
61 LineCapArrowAnchor = 0x14,
62
63 LineCapCustom = 0xff,
64 LineCapAnchorMask = 0xf0
65};
66
Evan Stadee4118c12007-07-06 16:14:07 -070067enum PathPointType{
68 PathPointTypeStart = 0, /* start of a figure */
69 PathPointTypeLine = 1,
70 PathPointTypeBezier = 3,
71 PathPointTypePathTypeMask = 7,
72 PathPointTypePathDashMode = 16, /* not used */
73 PathPointTypePathMarker = 32,
74 PathPointTypeCloseSubpath = 128, /* end of a closed figure */
75 PathPointTypeBezier3 = 3
76};
77
Evan Stadebcd0eda2007-07-12 19:42:47 -070078enum LineJoin
79{
80 LineJoinMiter = 0,
81 LineJoinBevel = 1,
82 LineJoinRound = 2,
83 LineJoinMiterClipped = 3
84};
85
Evan Stade53e17d22007-07-13 17:51:13 -070086enum QualityMode
87{
88 QualityModeInvalid = -1,
89 QualityModeDefault = 0,
90 QualityModeLow = 1,
91 QualityModeHigh = 2
92};
93
94enum SmoothingMode
95{
96 SmoothingModeInvalid = QualityModeInvalid,
97 SmoothingModeDefault = QualityModeDefault,
98 SmoothingModeHighSpeed = QualityModeLow,
99 SmoothingModeHighQuality = QualityModeHigh,
100 SmoothingModeNone,
101 SmoothingModeAntiAlias
102};
103
Evan Stade60cad232007-07-13 17:51:25 -0700104enum CompositingQuality
105{
106 CompositingQualityInvalid = QualityModeInvalid,
107 CompositingQualityDefault = QualityModeDefault,
108 CompositingQualityHighSpeed = QualityModeLow,
109 CompositingQualityHighQuality = QualityModeHigh,
110 CompositingQualityGammaCorrected,
111 CompositingQualityAssumeLinear
112};
113
Evan Stadea87ce7a2007-07-13 17:51:29 -0700114enum InterpolationMode
115{
116 InterpolationModeInvalid = QualityModeInvalid,
117 InterpolationModeDefault = QualityModeDefault,
118 InterpolationModeLowQuality = QualityModeLow,
119 InterpolationModeHighQuality = QualityModeHigh,
120 InterpolationModeBilinear,
121 InterpolationModeBicubic,
122 InterpolationModeNearestNeighbor,
123 InterpolationModeHighQualityBilinear,
124 InterpolationModeHighQualityBicubic
125};
126
Alistair Leslie-Hughes9f0f9772008-01-30 15:46:25 +1100127enum PenAlignment
128{
129 PenAlignmentCenter = 0,
130 PenAlignmentInset = 1
131};
132
Evan Staded6bd866d2007-07-13 17:51:33 -0700133enum PixelOffsetMode
134{
135 PixelOffsetModeInvalid = QualityModeInvalid,
136 PixelOffsetModeDefault = QualityModeDefault,
137 PixelOffsetModeHighSpeed = QualityModeLow,
138 PixelOffsetModeHighQuality = QualityModeHigh,
139 PixelOffsetModeNone,
140 PixelOffsetModeHalf
141};
142
Evan Stade6893ef32007-07-16 19:44:50 -0700143enum DashCap
144{
145 DashCapFlat = 0,
146 DashCapRound = 2,
147 DashCapTriangle = 3
148};
149
Evan Stadedaf00ab2007-07-16 19:45:16 -0700150enum DashStyle
151{
152 DashStyleSolid,
153 DashStyleDash,
154 DashStyleDot,
155 DashStyleDashDot,
156 DashStyleDashDotDot,
157 DashStyleCustom
158};
159
Evan Stade12e3ead2007-07-17 19:31:15 -0700160enum MatrixOrder
161{
162 MatrixOrderPrepend = 0,
163 MatrixOrderAppend = 1
164};
165
Evan Stade8770b6e2007-07-24 17:19:12 -0700166enum ImageType
167{
168 ImageTypeUnknown,
169 ImageTypeBitmap,
170 ImageTypeMetafile
171};
172
Evan Stade5dd58252007-07-30 19:09:41 -0700173enum WrapMode
174{
175 WrapModeTile,
176 WrapModeTileFlipX,
177 WrapModeTileFlipY,
178 WrapModeTileFlipXY,
179 WrapModeClamp
180};
181
Evan Stadee91d1242007-07-31 19:15:29 -0700182enum MetafileType
183{
184 MetafileTypeInvalid,
185 MetafileTypeWmf,
186 MetafileTypeWmfPlaceable,
187 MetafileTypeEmf,
188 MetafileTypeEmfPlusOnly,
189 MetafileTypeEmfPlusDual
190};
191
Evan Staded806c672007-08-07 18:43:00 -0700192enum LinearGradientMode
193{
194 LinearGradientModeHorizontal,
195 LinearGradientModeVertical,
196 LinearGradientModeForwardDiagonal,
197 LinearGradientModeBackwardDiagonal
198};
199
Evan Stadef8b2b772007-08-09 18:25:37 -0700200enum EmfType
201{
202 EmfTypeEmfOnly = MetafileTypeEmf,
203 EmfTypeEmfPlusOnly = MetafileTypeEmfPlusOnly,
204 EmfTypeEmfPlusDual = MetafileTypeEmfPlusDual
205};
206
Evan Stadee807eb92007-08-13 18:34:27 -0700207enum CompositingMode
208{
209 CompositingModeSourceOver,
210 CompositingModeSourceCopy
211};
212
Evan Stade56628202007-08-14 19:00:09 -0700213enum TextRenderingHint
214{
215 TextRenderingHintSystemDefault = 0,
216 TextRenderingHintSingleBitPerPixelGridFit,
217 TextRenderingHintSingleBitPerPixel,
218 TextRenderingHintAntiAliasGridFit,
219 TextRenderingHintAntiAlias,
220 TextRenderingHintClearTypeGridFit
221};
222
Evan Stade16dea472007-08-14 19:00:32 -0700223enum StringAlignment
224{
225 StringAlignmentNear = 0,
226 StringAlignmentCenter = 1,
227 StringAlignmentFar = 2
228};
229
Evan Stade551a6062007-08-14 19:00:40 -0700230enum StringFormatFlags
231{
232 StringFormatFlagsDirectionRightToLeft = 0x00000001,
233 StringFormatFlagsDirectionVertical = 0x00000002,
234 StringFormatFlagsNoFitBlackBox = 0x00000004,
235 StringFormatFlagsDisplayFormatControl = 0x00000020,
236 StringFormatFlagsNoFontFallback = 0x00000400,
237 StringFormatFlagsMeasureTrailingSpaces = 0x00000800,
238 StringFormatFlagsNoWrap = 0x00001000,
239 StringFormatFlagsLineLimit = 0x00002000,
240 StringFormatFlagsNoClip = 0x00004000
241};
242
243enum StringTrimming
244{
245 StringTrimmingNone = 0,
246 StringTrimmingCharacter = 1,
247 StringTrimmingWord = 2,
248 StringTrimmingEllipsisCharacter = 3,
249 StringTrimmingEllipsisWord = 4,
250 StringTrimmingEllipsisPath = 5
251};
252
Evan Stade936f3102007-08-14 19:00:53 -0700253enum HotkeyPrefix
254{
255 HotkeyPrefixNone = 0,
256 HotkeyPrefixShow = 1,
257 HotkeyPrefixHide = 2
258};
259
Nathan Beckmann366854a2008-03-06 01:17:00 -0800260enum ImageCodecFlags
261{
262 ImageCodecFlagsEncoder = 1,
263 ImageCodecFlagsDecoder = 2,
264 ImageCodecFlagsSupportBitmap = 4,
265 ImageCodecFlagsSupportVector = 8,
266 ImageCodecFlagsSeekableEncode = 16,
267 ImageCodecFlagsBlockingDecode = 32,
268 ImageCodecFlagsBuiltin = 65536,
269 ImageCodecFlagsSystem = 131072,
270 ImageCodecFlagsUser = 262144
271};
Evan Stade936f3102007-08-14 19:00:53 -0700272
Evan Stade48f10d42007-06-08 13:44:28 -0700273#ifndef __cplusplus
274
275typedef enum Unit Unit;
276typedef enum BrushType BrushType;
Evan Stade14802872007-06-21 16:15:17 -0700277typedef enum FillMode FillMode;
Evan Stade68ba30f2007-07-05 18:37:52 -0700278typedef enum LineCap LineCap;
Evan Stadee4118c12007-07-06 16:14:07 -0700279typedef enum PathPointType PathPointType;
Evan Stadebcd0eda2007-07-12 19:42:47 -0700280typedef enum LineJoin LineJoin;
Evan Stade53e17d22007-07-13 17:51:13 -0700281typedef enum QualityMode QualityMode;
282typedef enum SmoothingMode SmoothingMode;
Evan Stade60cad232007-07-13 17:51:25 -0700283typedef enum CompositingQuality CompositingQuality;
Evan Stadea87ce7a2007-07-13 17:51:29 -0700284typedef enum InterpolationMode InterpolationMode;
Evan Staded6bd866d2007-07-13 17:51:33 -0700285typedef enum PixelOffsetMode PixelOffsetMode;
Evan Stade6893ef32007-07-16 19:44:50 -0700286typedef enum DashCap DashCap;
Evan Stadedaf00ab2007-07-16 19:45:16 -0700287typedef enum DashStyle DashStyle;
Evan Stade12e3ead2007-07-17 19:31:15 -0700288typedef enum MatrixOrder MatrixOrder;
Evan Stade8770b6e2007-07-24 17:19:12 -0700289typedef enum ImageType ImageType;
Evan Stade5dd58252007-07-30 19:09:41 -0700290typedef enum WrapMode WrapMode;
Evan Stadee91d1242007-07-31 19:15:29 -0700291typedef enum MetafileType MetafileType;
Evan Staded806c672007-08-07 18:43:00 -0700292typedef enum LinearGradientMode LinearGradientMode;
Evan Stadef8b2b772007-08-09 18:25:37 -0700293typedef enum EmfType EmfType;
Evan Stadee807eb92007-08-13 18:34:27 -0700294typedef enum CompositingMode CompositingMode;
Evan Stade56628202007-08-14 19:00:09 -0700295typedef enum TextRenderingHint TextRenderingHint;
Evan Stade16dea472007-08-14 19:00:32 -0700296typedef enum StringAlignment StringAlignment;
Evan Stade551a6062007-08-14 19:00:40 -0700297typedef enum StringTrimming StringTrimming;
298typedef enum StringFormatFlags StringFormatFlags;
Evan Stade936f3102007-08-14 19:00:53 -0700299typedef enum HotkeyPrefix HotkeyPrefix;
Alistair Leslie-Hughes9f0f9772008-01-30 15:46:25 +1100300typedef enum PenAlignment GpPenAlignment;
Nathan Beckmann366854a2008-03-06 01:17:00 -0800301typedef enum ImageCodecFlags ImageCodecFlags;
Evan Stade48f10d42007-06-08 13:44:28 -0700302
303#endif /* end of c typedefs */
304
305#endif