Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

1077 lines
47 KiB

  1. /**************************************************************************\
  2. *
  3. * Copyright (c) 1998-2001, Microsoft Corp. All Rights Reserved.
  4. *
  5. * Module Name:
  6. *
  7. * GdiplusEnums.h
  8. *
  9. * Abstract:
  10. *
  11. * GDI+ Enumeration Types
  12. *
  13. \**************************************************************************/
  14. #ifndef _GDIPLUSENUMS_H
  15. #define _GDIPLUSENUMS_H
  16. //--------------------------------------------------------------------------
  17. // Default bezier flattening tolerance in device pixels.
  18. //--------------------------------------------------------------------------
  19. const float FlatnessDefault = 1.0f/4.0f;
  20. //--------------------------------------------------------------------------
  21. // Graphics and Container State cookies
  22. //--------------------------------------------------------------------------
  23. typedef UINT GraphicsState;
  24. typedef UINT GraphicsContainer;
  25. //--------------------------------------------------------------------------
  26. // Fill mode constants
  27. //--------------------------------------------------------------------------
  28. enum FillMode
  29. {
  30. FillModeAlternate, // 0
  31. FillModeWinding // 1
  32. };
  33. //--------------------------------------------------------------------------
  34. // Quality mode constants
  35. //--------------------------------------------------------------------------
  36. enum QualityMode
  37. {
  38. QualityModeInvalid = -1,
  39. QualityModeDefault = 0,
  40. QualityModeLow = 1, // Best performance
  41. QualityModeHigh = 2 // Best rendering quality
  42. };
  43. //--------------------------------------------------------------------------
  44. // Alpha Compositing mode constants
  45. //--------------------------------------------------------------------------
  46. enum CompositingMode
  47. {
  48. CompositingModeSourceOver, // 0
  49. CompositingModeSourceCopy // 1
  50. };
  51. //--------------------------------------------------------------------------
  52. // Alpha Compositing quality constants
  53. //--------------------------------------------------------------------------
  54. enum CompositingQuality
  55. {
  56. CompositingQualityInvalid = QualityModeInvalid,
  57. CompositingQualityDefault = QualityModeDefault,
  58. CompositingQualityHighSpeed = QualityModeLow,
  59. CompositingQualityHighQuality = QualityModeHigh,
  60. CompositingQualityGammaCorrected,
  61. CompositingQualityAssumeLinear
  62. };
  63. //--------------------------------------------------------------------------
  64. // Unit constants
  65. //--------------------------------------------------------------------------
  66. enum Unit
  67. {
  68. UnitWorld, // 0 -- World coordinate (non-physical unit)
  69. UnitDisplay, // 1 -- Variable -- for PageTransform only
  70. UnitPixel, // 2 -- Each unit is one device pixel.
  71. UnitPoint, // 3 -- Each unit is a printer's point, or 1/72 inch.
  72. UnitInch, // 4 -- Each unit is 1 inch.
  73. UnitDocument, // 5 -- Each unit is 1/300 inch.
  74. UnitMillimeter // 6 -- Each unit is 1 millimeter.
  75. };
  76. //--------------------------------------------------------------------------
  77. // MetafileFrameUnit
  78. //
  79. // The frameRect for creating a metafile can be specified in any of these
  80. // units. There is an extra frame unit value (MetafileFrameUnitGdi) so
  81. // that units can be supplied in the same units that GDI expects for
  82. // frame rects -- these units are in .01 (1/100ths) millimeter units
  83. // as defined by GDI.
  84. //--------------------------------------------------------------------------
  85. enum MetafileFrameUnit
  86. {
  87. MetafileFrameUnitPixel = UnitPixel,
  88. MetafileFrameUnitPoint = UnitPoint,
  89. MetafileFrameUnitInch = UnitInch,
  90. MetafileFrameUnitDocument = UnitDocument,
  91. MetafileFrameUnitMillimeter = UnitMillimeter,
  92. MetafileFrameUnitGdi // GDI compatible .01 MM units
  93. };
  94. //--------------------------------------------------------------------------
  95. // Coordinate space identifiers
  96. //--------------------------------------------------------------------------
  97. enum CoordinateSpace
  98. {
  99. CoordinateSpaceWorld, // 0
  100. CoordinateSpacePage, // 1
  101. CoordinateSpaceDevice // 2
  102. };
  103. //--------------------------------------------------------------------------
  104. // Various wrap modes for brushes
  105. //--------------------------------------------------------------------------
  106. enum WrapMode
  107. {
  108. WrapModeTile, // 0
  109. WrapModeTileFlipX, // 1
  110. WrapModeTileFlipY, // 2
  111. WrapModeTileFlipXY, // 3
  112. WrapModeClamp // 4
  113. };
  114. //--------------------------------------------------------------------------
  115. // Various hatch styles
  116. //--------------------------------------------------------------------------
  117. enum HatchStyle
  118. {
  119. HatchStyleHorizontal, // 0
  120. HatchStyleVertical, // 1
  121. HatchStyleForwardDiagonal, // 2
  122. HatchStyleBackwardDiagonal, // 3
  123. HatchStyleCross, // 4
  124. HatchStyleDiagonalCross, // 5
  125. HatchStyle05Percent, // 6
  126. HatchStyle10Percent, // 7
  127. HatchStyle20Percent, // 8
  128. HatchStyle25Percent, // 9
  129. HatchStyle30Percent, // 10
  130. HatchStyle40Percent, // 11
  131. HatchStyle50Percent, // 12
  132. HatchStyle60Percent, // 13
  133. HatchStyle70Percent, // 14
  134. HatchStyle75Percent, // 15
  135. HatchStyle80Percent, // 16
  136. HatchStyle90Percent, // 17
  137. HatchStyleLightDownwardDiagonal, // 18
  138. HatchStyleLightUpwardDiagonal, // 19
  139. HatchStyleDarkDownwardDiagonal, // 20
  140. HatchStyleDarkUpwardDiagonal, // 21
  141. HatchStyleWideDownwardDiagonal, // 22
  142. HatchStyleWideUpwardDiagonal, // 23
  143. HatchStyleLightVertical, // 24
  144. HatchStyleLightHorizontal, // 25
  145. HatchStyleNarrowVertical, // 26
  146. HatchStyleNarrowHorizontal, // 27
  147. HatchStyleDarkVertical, // 28
  148. HatchStyleDarkHorizontal, // 29
  149. HatchStyleDashedDownwardDiagonal, // 30
  150. HatchStyleDashedUpwardDiagonal, // 31
  151. HatchStyleDashedHorizontal, // 32
  152. HatchStyleDashedVertical, // 33
  153. HatchStyleSmallConfetti, // 34
  154. HatchStyleLargeConfetti, // 35
  155. HatchStyleZigZag, // 36
  156. HatchStyleWave, // 37
  157. HatchStyleDiagonalBrick, // 38
  158. HatchStyleHorizontalBrick, // 39
  159. HatchStyleWeave, // 40
  160. HatchStylePlaid, // 41
  161. HatchStyleDivot, // 42
  162. HatchStyleDottedGrid, // 43
  163. HatchStyleDottedDiamond, // 44
  164. HatchStyleShingle, // 45
  165. HatchStyleTrellis, // 46
  166. HatchStyleSphere, // 47
  167. HatchStyleSmallGrid, // 48
  168. HatchStyleSmallCheckerBoard, // 49
  169. HatchStyleLargeCheckerBoard, // 50
  170. HatchStyleOutlinedDiamond, // 51
  171. HatchStyleSolidDiamond, // 52
  172. HatchStyleTotal,
  173. HatchStyleLargeGrid = HatchStyleCross, // 4
  174. HatchStyleMin = HatchStyleHorizontal,
  175. HatchStyleMax = HatchStyleTotal - 1,
  176. };
  177. //--------------------------------------------------------------------------
  178. // Dash style constants
  179. //--------------------------------------------------------------------------
  180. enum DashStyle
  181. {
  182. DashStyleSolid, // 0
  183. DashStyleDash, // 1
  184. DashStyleDot, // 2
  185. DashStyleDashDot, // 3
  186. DashStyleDashDotDot, // 4
  187. DashStyleCustom // 5
  188. };
  189. //--------------------------------------------------------------------------
  190. // Dash cap constants
  191. //--------------------------------------------------------------------------
  192. enum DashCap
  193. {
  194. DashCapFlat = 0,
  195. DashCapRound = 2,
  196. DashCapTriangle = 3
  197. };
  198. //--------------------------------------------------------------------------
  199. // Line cap constants (only the lowest 8 bits are used).
  200. //--------------------------------------------------------------------------
  201. enum LineCap
  202. {
  203. LineCapFlat = 0,
  204. LineCapSquare = 1,
  205. LineCapRound = 2,
  206. LineCapTriangle = 3,
  207. LineCapNoAnchor = 0x10, // corresponds to flat cap
  208. LineCapSquareAnchor = 0x11, // corresponds to square cap
  209. LineCapRoundAnchor = 0x12, // corresponds to round cap
  210. LineCapDiamondAnchor = 0x13, // corresponds to triangle cap
  211. LineCapArrowAnchor = 0x14, // no correspondence
  212. LineCapCustom = 0xff, // custom cap
  213. LineCapAnchorMask = 0xf0 // mask to check for anchor or not.
  214. };
  215. //--------------------------------------------------------------------------
  216. // Custom Line cap type constants
  217. //--------------------------------------------------------------------------
  218. enum CustomLineCapType
  219. {
  220. CustomLineCapTypeDefault = 0,
  221. CustomLineCapTypeAdjustableArrow = 1
  222. };
  223. //--------------------------------------------------------------------------
  224. // Line join constants
  225. //--------------------------------------------------------------------------
  226. enum LineJoin
  227. {
  228. LineJoinMiter = 0,
  229. LineJoinBevel = 1,
  230. LineJoinRound = 2,
  231. LineJoinMiterClipped = 3
  232. };
  233. //--------------------------------------------------------------------------
  234. // Path point types (only the lowest 8 bits are used.)
  235. // The lowest 3 bits are interpreted as point type
  236. // The higher 5 bits are reserved for flags.
  237. //--------------------------------------------------------------------------
  238. enum PathPointType
  239. {
  240. PathPointTypeStart = 0, // move
  241. PathPointTypeLine = 1, // line
  242. PathPointTypeBezier = 3, // default Bezier (= cubic Bezier)
  243. PathPointTypePathTypeMask = 0x07, // type mask (lowest 3 bits).
  244. PathPointTypeDashMode = 0x10, // currently in dash mode.
  245. PathPointTypePathMarker = 0x20, // a marker for the path.
  246. PathPointTypeCloseSubpath = 0x80, // closed flag
  247. // Path types used for advanced path.
  248. PathPointTypeBezier3 = 3, // cubic Bezier
  249. };
  250. //--------------------------------------------------------------------------
  251. // WarpMode constants
  252. //--------------------------------------------------------------------------
  253. enum WarpMode
  254. {
  255. WarpModePerspective, // 0
  256. WarpModeBilinear // 1
  257. };
  258. //--------------------------------------------------------------------------
  259. // LineGradient Mode
  260. //--------------------------------------------------------------------------
  261. enum LinearGradientMode
  262. {
  263. LinearGradientModeHorizontal, // 0
  264. LinearGradientModeVertical, // 1
  265. LinearGradientModeForwardDiagonal, // 2
  266. LinearGradientModeBackwardDiagonal // 3
  267. };
  268. //--------------------------------------------------------------------------
  269. // Region Comine Modes
  270. //--------------------------------------------------------------------------
  271. enum CombineMode
  272. {
  273. CombineModeReplace, // 0
  274. CombineModeIntersect, // 1
  275. CombineModeUnion, // 2
  276. CombineModeXor, // 3
  277. CombineModeExclude, // 4
  278. CombineModeComplement // 5 (Exclude From)
  279. };
  280. //--------------------------------------------------------------------------
  281. // Image types
  282. //--------------------------------------------------------------------------
  283. enum ImageType
  284. {
  285. ImageTypeUnknown, // 0
  286. ImageTypeBitmap, // 1
  287. ImageTypeMetafile // 2
  288. };
  289. //--------------------------------------------------------------------------
  290. // Interpolation modes
  291. //--------------------------------------------------------------------------
  292. enum InterpolationMode
  293. {
  294. InterpolationModeInvalid = QualityModeInvalid,
  295. InterpolationModeDefault = QualityModeDefault,
  296. InterpolationModeLowQuality = QualityModeLow,
  297. InterpolationModeHighQuality = QualityModeHigh,
  298. InterpolationModeBilinear,
  299. InterpolationModeBicubic,
  300. InterpolationModeNearestNeighbor,
  301. InterpolationModeHighQualityBilinear,
  302. InterpolationModeHighQualityBicubic
  303. };
  304. //--------------------------------------------------------------------------
  305. // Pen types
  306. //--------------------------------------------------------------------------
  307. enum PenAlignment
  308. {
  309. PenAlignmentCenter = 0,
  310. PenAlignmentInset = 1
  311. };
  312. //--------------------------------------------------------------------------
  313. // Brush types
  314. //--------------------------------------------------------------------------
  315. enum BrushType
  316. {
  317. BrushTypeSolidColor = 0,
  318. BrushTypeHatchFill = 1,
  319. BrushTypeTextureFill = 2,
  320. BrushTypePathGradient = 3,
  321. BrushTypeLinearGradient = 4
  322. };
  323. //--------------------------------------------------------------------------
  324. // Pen's Fill types
  325. //--------------------------------------------------------------------------
  326. enum PenType
  327. {
  328. PenTypeSolidColor = BrushTypeSolidColor,
  329. PenTypeHatchFill = BrushTypeHatchFill,
  330. PenTypeTextureFill = BrushTypeTextureFill,
  331. PenTypePathGradient = BrushTypePathGradient,
  332. PenTypeLinearGradient = BrushTypeLinearGradient,
  333. PenTypeUnknown = -1
  334. };
  335. //--------------------------------------------------------------------------
  336. // Matrix Order
  337. //--------------------------------------------------------------------------
  338. enum MatrixOrder
  339. {
  340. MatrixOrderPrepend = 0,
  341. MatrixOrderAppend = 1
  342. };
  343. //--------------------------------------------------------------------------
  344. // Generic font families
  345. //--------------------------------------------------------------------------
  346. enum GenericFontFamily
  347. {
  348. GenericFontFamilySerif,
  349. GenericFontFamilySansSerif,
  350. GenericFontFamilyMonospace
  351. };
  352. //--------------------------------------------------------------------------
  353. // FontStyle: face types and common styles
  354. //--------------------------------------------------------------------------
  355. enum FontStyle
  356. {
  357. FontStyleRegular = 0,
  358. FontStyleBold = 1,
  359. FontStyleItalic = 2,
  360. FontStyleBoldItalic = 3,
  361. FontStyleUnderline = 4,
  362. FontStyleStrikeout = 8
  363. };
  364. //---------------------------------------------------------------------------
  365. // Smoothing Mode
  366. //---------------------------------------------------------------------------
  367. enum SmoothingMode
  368. {
  369. SmoothingModeInvalid = QualityModeInvalid,
  370. SmoothingModeDefault = QualityModeDefault,
  371. SmoothingModeHighSpeed = QualityModeLow,
  372. SmoothingModeHighQuality = QualityModeHigh,
  373. SmoothingModeNone,
  374. SmoothingModeAntiAlias
  375. };
  376. //---------------------------------------------------------------------------
  377. // Pixel Format Mode
  378. //---------------------------------------------------------------------------
  379. enum PixelOffsetMode
  380. {
  381. PixelOffsetModeInvalid = QualityModeInvalid,
  382. PixelOffsetModeDefault = QualityModeDefault,
  383. PixelOffsetModeHighSpeed = QualityModeLow,
  384. PixelOffsetModeHighQuality = QualityModeHigh,
  385. PixelOffsetModeNone, // No pixel offset
  386. PixelOffsetModeHalf // Offset by -0.5, -0.5 for fast anti-alias perf
  387. };
  388. //---------------------------------------------------------------------------
  389. // Text Rendering Hint
  390. //---------------------------------------------------------------------------
  391. enum TextRenderingHint
  392. {
  393. TextRenderingHintSystemDefault = 0, // Glyph with system default rendering hint
  394. TextRenderingHintSingleBitPerPixelGridFit, // Glyph bitmap with hinting
  395. TextRenderingHintSingleBitPerPixel, // Glyph bitmap without hinting
  396. TextRenderingHintAntiAliasGridFit, // Glyph anti-alias bitmap with hinting
  397. TextRenderingHintAntiAlias, // Glyph anti-alias bitmap without hinting
  398. TextRenderingHintClearTypeGridFit // Glyph CT bitmap with hinting
  399. };
  400. //---------------------------------------------------------------------------
  401. // Metafile Types
  402. //---------------------------------------------------------------------------
  403. enum MetafileType
  404. {
  405. MetafileTypeInvalid, // Invalid metafile
  406. MetafileTypeWmf, // Standard WMF
  407. MetafileTypeWmfPlaceable, // Placeable WMF
  408. MetafileTypeEmf, // EMF (not EMF+)
  409. MetafileTypeEmfPlusOnly, // EMF+ without dual, down-level records
  410. MetafileTypeEmfPlusDual // EMF+ with dual, down-level records
  411. };
  412. //---------------------------------------------------------------------------
  413. // Specifies the type of EMF to record
  414. //---------------------------------------------------------------------------
  415. enum EmfType
  416. {
  417. EmfTypeEmfOnly = MetafileTypeEmf, // no EMF+, only EMF
  418. EmfTypeEmfPlusOnly = MetafileTypeEmfPlusOnly, // no EMF, only EMF+
  419. EmfTypeEmfPlusDual = MetafileTypeEmfPlusDual // both EMF+ and EMF
  420. };
  421. //---------------------------------------------------------------------------
  422. // EMF+ Persistent object types
  423. //---------------------------------------------------------------------------
  424. enum ObjectType
  425. {
  426. ObjectTypeInvalid,
  427. ObjectTypeBrush,
  428. ObjectTypePen,
  429. ObjectTypePath,
  430. ObjectTypeRegion,
  431. ObjectTypeImage,
  432. ObjectTypeFont,
  433. ObjectTypeStringFormat,
  434. ObjectTypeImageAttributes,
  435. ObjectTypeCustomLineCap,
  436. ObjectTypeMax = ObjectTypeCustomLineCap,
  437. ObjectTypeMin = ObjectTypeBrush
  438. };
  439. inline BOOL
  440. ObjectTypeIsValid(
  441. ObjectType type
  442. )
  443. {
  444. return ((type >= ObjectTypeMin) && (type <= ObjectTypeMax));
  445. }
  446. //---------------------------------------------------------------------------
  447. // EMF+ Records
  448. //---------------------------------------------------------------------------
  449. // We have to change the WMF record numbers so that they don't conflict with
  450. // the EMF and EMF+ record numbers.
  451. enum EmfPlusRecordType;
  452. #define GDIP_EMFPLUS_RECORD_BASE 0x00004000
  453. #define GDIP_WMF_RECORD_BASE 0x00010000
  454. #define GDIP_WMF_RECORD_TO_EMFPLUS(n) ((EmfPlusRecordType)((n) | GDIP_WMF_RECORD_BASE))
  455. #define GDIP_EMFPLUS_RECORD_TO_WMF(n) ((n) & (~GDIP_WMF_RECORD_BASE))
  456. #define GDIP_IS_WMF_RECORDTYPE(n) (((n) & GDIP_WMF_RECORD_BASE) != 0)
  457. enum EmfPlusRecordType
  458. {
  459. // Since we have to enumerate GDI records right along with GDI+ records,
  460. // We list all the GDI records here so that they can be part of the
  461. // same enumeration type which is used in the enumeration callback.
  462. WmfRecordTypeSetBkColor = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETBKCOLOR),
  463. WmfRecordTypeSetBkMode = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETBKMODE),
  464. WmfRecordTypeSetMapMode = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETMAPMODE),
  465. WmfRecordTypeSetROP2 = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETROP2),
  466. WmfRecordTypeSetRelAbs = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETRELABS),
  467. WmfRecordTypeSetPolyFillMode = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETPOLYFILLMODE),
  468. WmfRecordTypeSetStretchBltMode = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETSTRETCHBLTMODE),
  469. WmfRecordTypeSetTextCharExtra = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETTEXTCHAREXTRA),
  470. WmfRecordTypeSetTextColor = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETTEXTCOLOR),
  471. WmfRecordTypeSetTextJustification = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETTEXTJUSTIFICATION),
  472. WmfRecordTypeSetWindowOrg = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETWINDOWORG),
  473. WmfRecordTypeSetWindowExt = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETWINDOWEXT),
  474. WmfRecordTypeSetViewportOrg = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETVIEWPORTORG),
  475. WmfRecordTypeSetViewportExt = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETVIEWPORTEXT),
  476. WmfRecordTypeOffsetWindowOrg = GDIP_WMF_RECORD_TO_EMFPLUS(META_OFFSETWINDOWORG),
  477. WmfRecordTypeScaleWindowExt = GDIP_WMF_RECORD_TO_EMFPLUS(META_SCALEWINDOWEXT),
  478. WmfRecordTypeOffsetViewportOrg = GDIP_WMF_RECORD_TO_EMFPLUS(META_OFFSETVIEWPORTORG),
  479. WmfRecordTypeScaleViewportExt = GDIP_WMF_RECORD_TO_EMFPLUS(META_SCALEVIEWPORTEXT),
  480. WmfRecordTypeLineTo = GDIP_WMF_RECORD_TO_EMFPLUS(META_LINETO),
  481. WmfRecordTypeMoveTo = GDIP_WMF_RECORD_TO_EMFPLUS(META_MOVETO),
  482. WmfRecordTypeExcludeClipRect = GDIP_WMF_RECORD_TO_EMFPLUS(META_EXCLUDECLIPRECT),
  483. WmfRecordTypeIntersectClipRect = GDIP_WMF_RECORD_TO_EMFPLUS(META_INTERSECTCLIPRECT),
  484. WmfRecordTypeArc = GDIP_WMF_RECORD_TO_EMFPLUS(META_ARC),
  485. WmfRecordTypeEllipse = GDIP_WMF_RECORD_TO_EMFPLUS(META_ELLIPSE),
  486. WmfRecordTypeFloodFill = GDIP_WMF_RECORD_TO_EMFPLUS(META_FLOODFILL),
  487. WmfRecordTypePie = GDIP_WMF_RECORD_TO_EMFPLUS(META_PIE),
  488. WmfRecordTypeRectangle = GDIP_WMF_RECORD_TO_EMFPLUS(META_RECTANGLE),
  489. WmfRecordTypeRoundRect = GDIP_WMF_RECORD_TO_EMFPLUS(META_ROUNDRECT),
  490. WmfRecordTypePatBlt = GDIP_WMF_RECORD_TO_EMFPLUS(META_PATBLT),
  491. WmfRecordTypeSaveDC = GDIP_WMF_RECORD_TO_EMFPLUS(META_SAVEDC),
  492. WmfRecordTypeSetPixel = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETPIXEL),
  493. WmfRecordTypeOffsetClipRgn = GDIP_WMF_RECORD_TO_EMFPLUS(META_OFFSETCLIPRGN),
  494. WmfRecordTypeTextOut = GDIP_WMF_RECORD_TO_EMFPLUS(META_TEXTOUT),
  495. WmfRecordTypeBitBlt = GDIP_WMF_RECORD_TO_EMFPLUS(META_BITBLT),
  496. WmfRecordTypeStretchBlt = GDIP_WMF_RECORD_TO_EMFPLUS(META_STRETCHBLT),
  497. WmfRecordTypePolygon = GDIP_WMF_RECORD_TO_EMFPLUS(META_POLYGON),
  498. WmfRecordTypePolyline = GDIP_WMF_RECORD_TO_EMFPLUS(META_POLYLINE),
  499. WmfRecordTypeEscape = GDIP_WMF_RECORD_TO_EMFPLUS(META_ESCAPE),
  500. WmfRecordTypeRestoreDC = GDIP_WMF_RECORD_TO_EMFPLUS(META_RESTOREDC),
  501. WmfRecordTypeFillRegion = GDIP_WMF_RECORD_TO_EMFPLUS(META_FILLREGION),
  502. WmfRecordTypeFrameRegion = GDIP_WMF_RECORD_TO_EMFPLUS(META_FRAMEREGION),
  503. WmfRecordTypeInvertRegion = GDIP_WMF_RECORD_TO_EMFPLUS(META_INVERTREGION),
  504. WmfRecordTypePaintRegion = GDIP_WMF_RECORD_TO_EMFPLUS(META_PAINTREGION),
  505. WmfRecordTypeSelectClipRegion = GDIP_WMF_RECORD_TO_EMFPLUS(META_SELECTCLIPREGION),
  506. WmfRecordTypeSelectObject = GDIP_WMF_RECORD_TO_EMFPLUS(META_SELECTOBJECT),
  507. WmfRecordTypeSetTextAlign = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETTEXTALIGN),
  508. WmfRecordTypeDrawText = GDIP_WMF_RECORD_TO_EMFPLUS(0x062F), // META_DRAWTEXT
  509. WmfRecordTypeChord = GDIP_WMF_RECORD_TO_EMFPLUS(META_CHORD),
  510. WmfRecordTypeSetMapperFlags = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETMAPPERFLAGS),
  511. WmfRecordTypeExtTextOut = GDIP_WMF_RECORD_TO_EMFPLUS(META_EXTTEXTOUT),
  512. WmfRecordTypeSetDIBToDev = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETDIBTODEV),
  513. WmfRecordTypeSelectPalette = GDIP_WMF_RECORD_TO_EMFPLUS(META_SELECTPALETTE),
  514. WmfRecordTypeRealizePalette = GDIP_WMF_RECORD_TO_EMFPLUS(META_REALIZEPALETTE),
  515. WmfRecordTypeAnimatePalette = GDIP_WMF_RECORD_TO_EMFPLUS(META_ANIMATEPALETTE),
  516. WmfRecordTypeSetPalEntries = GDIP_WMF_RECORD_TO_EMFPLUS(META_SETPALENTRIES),
  517. WmfRecordTypePolyPolygon = GDIP_WMF_RECORD_TO_EMFPLUS(META_POLYPOLYGON),
  518. WmfRecordTypeResizePalette = GDIP_WMF_RECORD_TO_EMFPLUS(META_RESIZEPALETTE),
  519. WmfRecordTypeDIBBitBlt = GDIP_WMF_RECORD_TO_EMFPLUS(META_DIBBITBLT),
  520. WmfRecordTypeDIBStretchBlt = GDIP_WMF_RECORD_TO_EMFPLUS(META_DIBSTRETCHBLT),
  521. WmfRecordTypeDIBCreatePatternBrush = GDIP_WMF_RECORD_TO_EMFPLUS(META_DIBCREATEPATTERNBRUSH),
  522. WmfRecordTypeStretchDIB = GDIP_WMF_RECORD_TO_EMFPLUS(META_STRETCHDIB),
  523. WmfRecordTypeExtFloodFill = GDIP_WMF_RECORD_TO_EMFPLUS(META_EXTFLOODFILL),
  524. WmfRecordTypeSetLayout = GDIP_WMF_RECORD_TO_EMFPLUS(0x0149), // META_SETLAYOUT
  525. WmfRecordTypeResetDC = GDIP_WMF_RECORD_TO_EMFPLUS(0x014C), // META_RESETDC
  526. WmfRecordTypeStartDoc = GDIP_WMF_RECORD_TO_EMFPLUS(0x014D), // META_STARTDOC
  527. WmfRecordTypeStartPage = GDIP_WMF_RECORD_TO_EMFPLUS(0x004F), // META_STARTPAGE
  528. WmfRecordTypeEndPage = GDIP_WMF_RECORD_TO_EMFPLUS(0x0050), // META_ENDPAGE
  529. WmfRecordTypeAbortDoc = GDIP_WMF_RECORD_TO_EMFPLUS(0x0052), // META_ABORTDOC
  530. WmfRecordTypeEndDoc = GDIP_WMF_RECORD_TO_EMFPLUS(0x005E), // META_ENDDOC
  531. WmfRecordTypeDeleteObject = GDIP_WMF_RECORD_TO_EMFPLUS(META_DELETEOBJECT),
  532. WmfRecordTypeCreatePalette = GDIP_WMF_RECORD_TO_EMFPLUS(META_CREATEPALETTE),
  533. WmfRecordTypeCreateBrush = GDIP_WMF_RECORD_TO_EMFPLUS(0x00F8), // META_CREATEBRUSH
  534. WmfRecordTypeCreatePatternBrush = GDIP_WMF_RECORD_TO_EMFPLUS(META_CREATEPATTERNBRUSH),
  535. WmfRecordTypeCreatePenIndirect = GDIP_WMF_RECORD_TO_EMFPLUS(META_CREATEPENINDIRECT),
  536. WmfRecordTypeCreateFontIndirect = GDIP_WMF_RECORD_TO_EMFPLUS(META_CREATEFONTINDIRECT),
  537. WmfRecordTypeCreateBrushIndirect = GDIP_WMF_RECORD_TO_EMFPLUS(META_CREATEBRUSHINDIRECT),
  538. WmfRecordTypeCreateBitmapIndirect = GDIP_WMF_RECORD_TO_EMFPLUS(0x02FD), // META_CREATEBITMAPINDIRECT
  539. WmfRecordTypeCreateBitmap = GDIP_WMF_RECORD_TO_EMFPLUS(0x06FE), // META_CREATEBITMAP
  540. WmfRecordTypeCreateRegion = GDIP_WMF_RECORD_TO_EMFPLUS(META_CREATEREGION),
  541. EmfRecordTypeHeader = EMR_HEADER,
  542. EmfRecordTypePolyBezier = EMR_POLYBEZIER,
  543. EmfRecordTypePolygon = EMR_POLYGON,
  544. EmfRecordTypePolyline = EMR_POLYLINE,
  545. EmfRecordTypePolyBezierTo = EMR_POLYBEZIERTO,
  546. EmfRecordTypePolyLineTo = EMR_POLYLINETO,
  547. EmfRecordTypePolyPolyline = EMR_POLYPOLYLINE,
  548. EmfRecordTypePolyPolygon = EMR_POLYPOLYGON,
  549. EmfRecordTypeSetWindowExtEx = EMR_SETWINDOWEXTEX,
  550. EmfRecordTypeSetWindowOrgEx = EMR_SETWINDOWORGEX,
  551. EmfRecordTypeSetViewportExtEx = EMR_SETVIEWPORTEXTEX,
  552. EmfRecordTypeSetViewportOrgEx = EMR_SETVIEWPORTORGEX,
  553. EmfRecordTypeSetBrushOrgEx = EMR_SETBRUSHORGEX,
  554. EmfRecordTypeEOF = EMR_EOF,
  555. EmfRecordTypeSetPixelV = EMR_SETPIXELV,
  556. EmfRecordTypeSetMapperFlags = EMR_SETMAPPERFLAGS,
  557. EmfRecordTypeSetMapMode = EMR_SETMAPMODE,
  558. EmfRecordTypeSetBkMode = EMR_SETBKMODE,
  559. EmfRecordTypeSetPolyFillMode = EMR_SETPOLYFILLMODE,
  560. EmfRecordTypeSetROP2 = EMR_SETROP2,
  561. EmfRecordTypeSetStretchBltMode = EMR_SETSTRETCHBLTMODE,
  562. EmfRecordTypeSetTextAlign = EMR_SETTEXTALIGN,
  563. EmfRecordTypeSetColorAdjustment = EMR_SETCOLORADJUSTMENT,
  564. EmfRecordTypeSetTextColor = EMR_SETTEXTCOLOR,
  565. EmfRecordTypeSetBkColor = EMR_SETBKCOLOR,
  566. EmfRecordTypeOffsetClipRgn = EMR_OFFSETCLIPRGN,
  567. EmfRecordTypeMoveToEx = EMR_MOVETOEX,
  568. EmfRecordTypeSetMetaRgn = EMR_SETMETARGN,
  569. EmfRecordTypeExcludeClipRect = EMR_EXCLUDECLIPRECT,
  570. EmfRecordTypeIntersectClipRect = EMR_INTERSECTCLIPRECT,
  571. EmfRecordTypeScaleViewportExtEx = EMR_SCALEVIEWPORTEXTEX,
  572. EmfRecordTypeScaleWindowExtEx = EMR_SCALEWINDOWEXTEX,
  573. EmfRecordTypeSaveDC = EMR_SAVEDC,
  574. EmfRecordTypeRestoreDC = EMR_RESTOREDC,
  575. EmfRecordTypeSetWorldTransform = EMR_SETWORLDTRANSFORM,
  576. EmfRecordTypeModifyWorldTransform = EMR_MODIFYWORLDTRANSFORM,
  577. EmfRecordTypeSelectObject = EMR_SELECTOBJECT,
  578. EmfRecordTypeCreatePen = EMR_CREATEPEN,
  579. EmfRecordTypeCreateBrushIndirect = EMR_CREATEBRUSHINDIRECT,
  580. EmfRecordTypeDeleteObject = EMR_DELETEOBJECT,
  581. EmfRecordTypeAngleArc = EMR_ANGLEARC,
  582. EmfRecordTypeEllipse = EMR_ELLIPSE,
  583. EmfRecordTypeRectangle = EMR_RECTANGLE,
  584. EmfRecordTypeRoundRect = EMR_ROUNDRECT,
  585. EmfRecordTypeArc = EMR_ARC,
  586. EmfRecordTypeChord = EMR_CHORD,
  587. EmfRecordTypePie = EMR_PIE,
  588. EmfRecordTypeSelectPalette = EMR_SELECTPALETTE,
  589. EmfRecordTypeCreatePalette = EMR_CREATEPALETTE,
  590. EmfRecordTypeSetPaletteEntries = EMR_SETPALETTEENTRIES,
  591. EmfRecordTypeResizePalette = EMR_RESIZEPALETTE,
  592. EmfRecordTypeRealizePalette = EMR_REALIZEPALETTE,
  593. EmfRecordTypeExtFloodFill = EMR_EXTFLOODFILL,
  594. EmfRecordTypeLineTo = EMR_LINETO,
  595. EmfRecordTypeArcTo = EMR_ARCTO,
  596. EmfRecordTypePolyDraw = EMR_POLYDRAW,
  597. EmfRecordTypeSetArcDirection = EMR_SETARCDIRECTION,
  598. EmfRecordTypeSetMiterLimit = EMR_SETMITERLIMIT,
  599. EmfRecordTypeBeginPath = EMR_BEGINPATH,
  600. EmfRecordTypeEndPath = EMR_ENDPATH,
  601. EmfRecordTypeCloseFigure = EMR_CLOSEFIGURE,
  602. EmfRecordTypeFillPath = EMR_FILLPATH,
  603. EmfRecordTypeStrokeAndFillPath = EMR_STROKEANDFILLPATH,
  604. EmfRecordTypeStrokePath = EMR_STROKEPATH,
  605. EmfRecordTypeFlattenPath = EMR_FLATTENPATH,
  606. EmfRecordTypeWidenPath = EMR_WIDENPATH,
  607. EmfRecordTypeSelectClipPath = EMR_SELECTCLIPPATH,
  608. EmfRecordTypeAbortPath = EMR_ABORTPATH,
  609. EmfRecordTypeReserved_069 = 69, // Not Used
  610. EmfRecordTypeGdiComment = EMR_GDICOMMENT,
  611. EmfRecordTypeFillRgn = EMR_FILLRGN,
  612. EmfRecordTypeFrameRgn = EMR_FRAMERGN,
  613. EmfRecordTypeInvertRgn = EMR_INVERTRGN,
  614. EmfRecordTypePaintRgn = EMR_PAINTRGN,
  615. EmfRecordTypeExtSelectClipRgn = EMR_EXTSELECTCLIPRGN,
  616. EmfRecordTypeBitBlt = EMR_BITBLT,
  617. EmfRecordTypeStretchBlt = EMR_STRETCHBLT,
  618. EmfRecordTypeMaskBlt = EMR_MASKBLT,
  619. EmfRecordTypePlgBlt = EMR_PLGBLT,
  620. EmfRecordTypeSetDIBitsToDevice = EMR_SETDIBITSTODEVICE,
  621. EmfRecordTypeStretchDIBits = EMR_STRETCHDIBITS,
  622. EmfRecordTypeExtCreateFontIndirect = EMR_EXTCREATEFONTINDIRECTW,
  623. EmfRecordTypeExtTextOutA = EMR_EXTTEXTOUTA,
  624. EmfRecordTypeExtTextOutW = EMR_EXTTEXTOUTW,
  625. EmfRecordTypePolyBezier16 = EMR_POLYBEZIER16,
  626. EmfRecordTypePolygon16 = EMR_POLYGON16,
  627. EmfRecordTypePolyline16 = EMR_POLYLINE16,
  628. EmfRecordTypePolyBezierTo16 = EMR_POLYBEZIERTO16,
  629. EmfRecordTypePolylineTo16 = EMR_POLYLINETO16,
  630. EmfRecordTypePolyPolyline16 = EMR_POLYPOLYLINE16,
  631. EmfRecordTypePolyPolygon16 = EMR_POLYPOLYGON16,
  632. EmfRecordTypePolyDraw16 = EMR_POLYDRAW16,
  633. EmfRecordTypeCreateMonoBrush = EMR_CREATEMONOBRUSH,
  634. EmfRecordTypeCreateDIBPatternBrushPt = EMR_CREATEDIBPATTERNBRUSHPT,
  635. EmfRecordTypeExtCreatePen = EMR_EXTCREATEPEN,
  636. EmfRecordTypePolyTextOutA = EMR_POLYTEXTOUTA,
  637. EmfRecordTypePolyTextOutW = EMR_POLYTEXTOUTW,
  638. EmfRecordTypeSetICMMode = 98, // EMR_SETICMMODE,
  639. EmfRecordTypeCreateColorSpace = 99, // EMR_CREATECOLORSPACE,
  640. EmfRecordTypeSetColorSpace = 100, // EMR_SETCOLORSPACE,
  641. EmfRecordTypeDeleteColorSpace = 101, // EMR_DELETECOLORSPACE,
  642. EmfRecordTypeGLSRecord = 102, // EMR_GLSRECORD,
  643. EmfRecordTypeGLSBoundedRecord = 103, // EMR_GLSBOUNDEDRECORD,
  644. EmfRecordTypePixelFormat = 104, // EMR_PIXELFORMAT,
  645. EmfRecordTypeDrawEscape = 105, // EMR_RESERVED_105,
  646. EmfRecordTypeExtEscape = 106, // EMR_RESERVED_106,
  647. EmfRecordTypeStartDoc = 107, // EMR_RESERVED_107,
  648. EmfRecordTypeSmallTextOut = 108, // EMR_RESERVED_108,
  649. EmfRecordTypeForceUFIMapping = 109, // EMR_RESERVED_109,
  650. EmfRecordTypeNamedEscape = 110, // EMR_RESERVED_110,
  651. EmfRecordTypeColorCorrectPalette = 111, // EMR_COLORCORRECTPALETTE,
  652. EmfRecordTypeSetICMProfileA = 112, // EMR_SETICMPROFILEA,
  653. EmfRecordTypeSetICMProfileW = 113, // EMR_SETICMPROFILEW,
  654. EmfRecordTypeAlphaBlend = 114, // EMR_ALPHABLEND,
  655. EmfRecordTypeSetLayout = 115, // EMR_SETLAYOUT,
  656. EmfRecordTypeTransparentBlt = 116, // EMR_TRANSPARENTBLT,
  657. EmfRecordTypeReserved_117 = 117, // Not Used
  658. EmfRecordTypeGradientFill = 118, // EMR_GRADIENTFILL,
  659. EmfRecordTypeSetLinkedUFIs = 119, // EMR_RESERVED_119,
  660. EmfRecordTypeSetTextJustification = 120, // EMR_RESERVED_120,
  661. EmfRecordTypeColorMatchToTargetW = 121, // EMR_COLORMATCHTOTARGETW,
  662. EmfRecordTypeCreateColorSpaceW = 122, // EMR_CREATECOLORSPACEW,
  663. EmfRecordTypeMax = 122,
  664. EmfRecordTypeMin = 1,
  665. // That is the END of the GDI EMF records.
  666. // Now we start the list of EMF+ records. We leave quite
  667. // a bit of room here for the addition of any new GDI
  668. // records that may be added later.
  669. EmfPlusRecordTypeInvalid = GDIP_EMFPLUS_RECORD_BASE,
  670. EmfPlusRecordTypeHeader,
  671. EmfPlusRecordTypeEndOfFile,
  672. EmfPlusRecordTypeComment,
  673. EmfPlusRecordTypeGetDC,
  674. EmfPlusRecordTypeMultiFormatStart,
  675. EmfPlusRecordTypeMultiFormatSection,
  676. EmfPlusRecordTypeMultiFormatEnd,
  677. // For all persistent objects
  678. EmfPlusRecordTypeObject,
  679. // Drawing Records
  680. EmfPlusRecordTypeClear,
  681. EmfPlusRecordTypeFillRects,
  682. EmfPlusRecordTypeDrawRects,
  683. EmfPlusRecordTypeFillPolygon,
  684. EmfPlusRecordTypeDrawLines,
  685. EmfPlusRecordTypeFillEllipse,
  686. EmfPlusRecordTypeDrawEllipse,
  687. EmfPlusRecordTypeFillPie,
  688. EmfPlusRecordTypeDrawPie,
  689. EmfPlusRecordTypeDrawArc,
  690. EmfPlusRecordTypeFillRegion,
  691. EmfPlusRecordTypeFillPath,
  692. EmfPlusRecordTypeDrawPath,
  693. EmfPlusRecordTypeFillClosedCurve,
  694. EmfPlusRecordTypeDrawClosedCurve,
  695. EmfPlusRecordTypeDrawCurve,
  696. EmfPlusRecordTypeDrawBeziers,
  697. EmfPlusRecordTypeDrawImage,
  698. EmfPlusRecordTypeDrawImagePoints,
  699. EmfPlusRecordTypeDrawString,
  700. // Graphics State Records
  701. EmfPlusRecordTypeSetRenderingOrigin,
  702. EmfPlusRecordTypeSetAntiAliasMode,
  703. EmfPlusRecordTypeSetTextRenderingHint,
  704. EmfPlusRecordTypeSetTextContrast,
  705. EmfPlusRecordTypeSetInterpolationMode,
  706. EmfPlusRecordTypeSetPixelOffsetMode,
  707. EmfPlusRecordTypeSetCompositingMode,
  708. EmfPlusRecordTypeSetCompositingQuality,
  709. EmfPlusRecordTypeSave,
  710. EmfPlusRecordTypeRestore,
  711. EmfPlusRecordTypeBeginContainer,
  712. EmfPlusRecordTypeBeginContainerNoParams,
  713. EmfPlusRecordTypeEndContainer,
  714. EmfPlusRecordTypeSetWorldTransform,
  715. EmfPlusRecordTypeResetWorldTransform,
  716. EmfPlusRecordTypeMultiplyWorldTransform,
  717. EmfPlusRecordTypeTranslateWorldTransform,
  718. EmfPlusRecordTypeScaleWorldTransform,
  719. EmfPlusRecordTypeRotateWorldTransform,
  720. EmfPlusRecordTypeSetPageTransform,
  721. EmfPlusRecordTypeResetClip,
  722. EmfPlusRecordTypeSetClipRect,
  723. EmfPlusRecordTypeSetClipPath,
  724. EmfPlusRecordTypeSetClipRegion,
  725. EmfPlusRecordTypeOffsetClip,
  726. EmfPlusRecordTypeDrawDriverString,
  727. EmfPlusRecordTotal,
  728. EmfPlusRecordTypeMax = EmfPlusRecordTotal-1,
  729. EmfPlusRecordTypeMin = EmfPlusRecordTypeHeader,
  730. };
  731. //---------------------------------------------------------------------------
  732. // StringFormatFlags
  733. //---------------------------------------------------------------------------
  734. //---------------------------------------------------------------------------
  735. // String format flags
  736. //
  737. // DirectionRightToLeft - For horizontal text, the reading order is
  738. // right to left. This value is called
  739. // the base embedding level by the Unicode
  740. // bidirectional engine.
  741. // For vertical text, columns are read from
  742. // right to left.
  743. // By default, horizontal or vertical text is
  744. // read from left to right.
  745. //
  746. // DirectionVertical - Individual lines of text are vertical. In
  747. // each line, characters progress from top to
  748. // bottom.
  749. // By default, lines of text are horizontal,
  750. // each new line below the previous line.
  751. //
  752. // NoFitBlackBox - Allows parts of glyphs to overhang the
  753. // bounding rectangle.
  754. // By default glyphs are first aligned
  755. // inside the margines, then any glyphs which
  756. // still overhang the bounding box are
  757. // repositioned to avoid any overhang.
  758. // For example when an italic
  759. // lower case letter f in a font such as
  760. // Garamond is aligned at the far left of a
  761. // rectangle, the lower part of the f will
  762. // reach slightly further left than the left
  763. // edge of the rectangle. Setting this flag
  764. // will ensure the character aligns visually
  765. // with the lines above and below, but may
  766. // cause some pixels outside the formatting
  767. // rectangle to be clipped or painted.
  768. //
  769. // DisplayFormatControl - Causes control characters such as the
  770. // left-to-right mark to be shown in the
  771. // output with a representative glyph.
  772. //
  773. // NoFontFallback - Disables fallback to alternate fonts for
  774. // characters not supported in the requested
  775. // font. Any missing characters will be
  776. // be displayed with the fonts missing glyph,
  777. // usually an open square.
  778. //
  779. // NoWrap - Disables wrapping of text between lines
  780. // when formatting within a rectangle.
  781. // NoWrap is implied when a point is passed
  782. // instead of a rectangle, or when the
  783. // specified rectangle has a zero line length.
  784. //
  785. // NoClip - By default text is clipped to the
  786. // formatting rectangle. Setting NoClip
  787. // allows overhanging pixels to affect the
  788. // device outside the formatting rectangle.
  789. // Pixels at the end of the line may be
  790. // affected if the glyphs overhang their
  791. // cells, and either the NoFitBlackBox flag
  792. // has been set, or the glyph extends to far
  793. // to be fitted.
  794. // Pixels above/before the first line or
  795. // below/after the last line may be affected
  796. // if the glyphs extend beyond their cell
  797. // ascent / descent. This can occur rarely
  798. // with unusual diacritic mark combinations.
  799. //---------------------------------------------------------------------------
  800. enum StringFormatFlags
  801. {
  802. StringFormatFlagsDirectionRightToLeft = 0x00000001,
  803. StringFormatFlagsDirectionVertical = 0x00000002,
  804. StringFormatFlagsNoFitBlackBox = 0x00000004,
  805. StringFormatFlagsDisplayFormatControl = 0x00000020,
  806. StringFormatFlagsNoFontFallback = 0x00000400,
  807. StringFormatFlagsMeasureTrailingSpaces = 0x00000800,
  808. StringFormatFlagsNoWrap = 0x00001000,
  809. StringFormatFlagsLineLimit = 0x00002000,
  810. StringFormatFlagsNoClip = 0x00004000
  811. };
  812. //---------------------------------------------------------------------------
  813. // StringTrimming
  814. //---------------------------------------------------------------------------
  815. enum StringTrimming {
  816. StringTrimmingNone = 0,
  817. StringTrimmingCharacter = 1,
  818. StringTrimmingWord = 2,
  819. StringTrimmingEllipsisCharacter = 3,
  820. StringTrimmingEllipsisWord = 4,
  821. StringTrimmingEllipsisPath = 5
  822. };
  823. //---------------------------------------------------------------------------
  824. // National language digit substitution
  825. //---------------------------------------------------------------------------
  826. enum StringDigitSubstitute
  827. {
  828. StringDigitSubstituteUser = 0, // As NLS setting
  829. StringDigitSubstituteNone = 1,
  830. StringDigitSubstituteNational = 2,
  831. StringDigitSubstituteTraditional = 3
  832. };
  833. //---------------------------------------------------------------------------
  834. // Hotkey prefix interpretation
  835. //---------------------------------------------------------------------------
  836. enum HotkeyPrefix
  837. {
  838. HotkeyPrefixNone = 0,
  839. HotkeyPrefixShow = 1,
  840. HotkeyPrefixHide = 2
  841. };
  842. //---------------------------------------------------------------------------
  843. // String alignment flags
  844. //---------------------------------------------------------------------------
  845. enum StringAlignment
  846. {
  847. // Left edge for left-to-right text,
  848. // right for right-to-left text,
  849. // and top for vertical
  850. StringAlignmentNear = 0,
  851. StringAlignmentCenter = 1,
  852. StringAlignmentFar = 2
  853. };
  854. //---------------------------------------------------------------------------
  855. // DriverStringOptions
  856. //---------------------------------------------------------------------------
  857. enum DriverStringOptions
  858. {
  859. DriverStringOptionsCmapLookup = 1,
  860. DriverStringOptionsVertical = 2,
  861. DriverStringOptionsRealizedAdvance = 4,
  862. DriverStringOptionsLimitSubpixel = 8
  863. };
  864. //---------------------------------------------------------------------------
  865. // Flush Intention flags
  866. //---------------------------------------------------------------------------
  867. enum FlushIntention
  868. {
  869. FlushIntentionFlush = 0, // Flush all batched rendering operations
  870. FlushIntentionSync = 1 // Flush all batched rendering operations
  871. // and wait for them to complete
  872. };
  873. //---------------------------------------------------------------------------
  874. // Image encoder parameter related types
  875. //---------------------------------------------------------------------------
  876. enum EncoderParameterValueType
  877. {
  878. EncoderParameterValueTypeByte = 1, // 8-bit unsigned int
  879. EncoderParameterValueTypeASCII = 2, // 8-bit byte containing one 7-bit ASCII
  880. // code. NULL terminated.
  881. EncoderParameterValueTypeShort = 3, // 16-bit unsigned int
  882. EncoderParameterValueTypeLong = 4, // 32-bit unsigned int
  883. EncoderParameterValueTypeRational = 5, // Two Longs. The first Long is the
  884. // numerator, the second Long expresses the
  885. // denomintor.
  886. EncoderParameterValueTypeLongRange = 6, // Two longs which specify a range of
  887. // integer values. The first Long specifies
  888. // the lower end and the second one
  889. // specifies the higher end. All values
  890. // are inclusive at both ends
  891. EncoderParameterValueTypeUndefined = 7, // 8-bit byte that can take any value
  892. // depending on field definition
  893. EncoderParameterValueTypeRationalRange = 8 // Two Rationals. The first Rational
  894. // specifies the lower end and the second
  895. // specifies the higher end. All values
  896. // are inclusive at both ends
  897. };
  898. //---------------------------------------------------------------------------
  899. // Image encoder value types
  900. //---------------------------------------------------------------------------
  901. enum EncoderValue
  902. {
  903. EncoderValueColorTypeCMYK,
  904. EncoderValueColorTypeYCCK,
  905. EncoderValueCompressionLZW,
  906. EncoderValueCompressionCCITT3,
  907. EncoderValueCompressionCCITT4,
  908. EncoderValueCompressionRle,
  909. EncoderValueCompressionNone,
  910. EncoderValueScanMethodInterlaced,
  911. EncoderValueScanMethodNonInterlaced,
  912. EncoderValueVersionGif87,
  913. EncoderValueVersionGif89,
  914. EncoderValueRenderProgressive,
  915. EncoderValueRenderNonProgressive,
  916. EncoderValueTransformRotate90,
  917. EncoderValueTransformRotate180,
  918. EncoderValueTransformRotate270,
  919. EncoderValueTransformFlipHorizontal,
  920. EncoderValueTransformFlipVertical,
  921. EncoderValueMultiFrame,
  922. EncoderValueLastFrame,
  923. EncoderValueFlush,
  924. EncoderValueFrameDimensionTime,
  925. EncoderValueFrameDimensionResolution,
  926. EncoderValueFrameDimensionPage
  927. };
  928. //---------------------------------------------------------------------------
  929. // Conversion of Emf To WMF Bits flags
  930. //---------------------------------------------------------------------------
  931. enum EmfToWmfBitsFlags
  932. {
  933. EmfToWmfBitsFlagsDefault = 0x00000000,
  934. EmfToWmfBitsFlagsEmbedEmf = 0x00000001,
  935. EmfToWmfBitsFlagsIncludePlaceable = 0x00000002,
  936. EmfToWmfBitsFlagsNoXORClip = 0x00000004
  937. };
  938. //---------------------------------------------------------------------------
  939. // Test Control flags
  940. //---------------------------------------------------------------------------
  941. enum GpTestControlEnum
  942. {
  943. TestControlForceBilinear = 0,
  944. TestControlNoICM = 1,
  945. TestControlGetBuildNumber = 2
  946. };
  947. #endif // !_GDIPLUSENUMS_H