global.ppi 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219
  1. {
  2. $Id$
  3. This file is part of the Free Pascal run time library.
  4. Copyright (c) 1993,97 by the Free Pascal development team.
  5. See the file COPYING.FPC, included in this distribution,
  6. for details about the copyright.
  7. This program is distributed in the hope that it will be useful,
  8. but WITHOUT ANY WARRANTY; without even the implied warranty of
  9. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  10. **********************************************************************}
  11. {$E-}
  12. {$PACKRECORDS NORMAL}
  13. const
  14. { error codes }
  15. grOk = 0;
  16. grNoInitGraph = -1;
  17. grNotDetected = -2;
  18. grFileNotFound = -3;
  19. grInvalidDriver = -4;
  20. grNoLoadMem = -5;
  21. grNoScanMem = -6;
  22. grNoFloodMem = -7;
  23. grFontNotFound = -8;
  24. grNoFontMem = -9;
  25. grInvalidMode = -10;
  26. grError = -11;
  27. grIOerror = -12;
  28. grInvalidFont = -13;
  29. grInvalidFontNum = -14;
  30. grInvalidVersion = -18;
  31. { graphic drivers }
  32. CurrentDriver = -128;
  33. Detect = 0;
  34. { graph modes }
  35. Default = 0;
  36. { Farben f�r setpalette und setallpalette }
  37. black = 0;
  38. blue = 1;
  39. green = 2;
  40. cyan = 3;
  41. red = 4;
  42. magenta = 5;
  43. brown = 6;
  44. lightgray = 7;
  45. darkgray = 8;
  46. lightblue = 9;
  47. lightgreen = 10;
  48. lightcyan = 11;
  49. lightred = 12;
  50. lightmagenta = 13;
  51. yellow = 14;
  52. white = 15;
  53. { Linenart f�r Get/SetLineStyle: }
  54. SolidLn = 0;
  55. DottedLn = 1;
  56. CenterLn = 2;
  57. DashedLn = 3;
  58. UserBitLn = 4;
  59. NormWidth = 1;
  60. ThickWidth = 3;
  61. { Set/GetTextStyle Konstanten: }
  62. DefaultFont = 0;
  63. TriplexFont = 1;
  64. SmallFont = 2;
  65. SansSerifFont = 3;
  66. GothicFont = 4;
  67. ScriptFont = 5;
  68. SimpleFont = 6;
  69. TSCRFont = 7;
  70. LCOMFont = 8;
  71. EuroFont = 9;
  72. BoldFont = 10;
  73. HorizDir = 0;
  74. VertDir = 1;
  75. UserCharSize = 0;
  76. ClipOn = true;
  77. ClipOff = false;
  78. { Bar3D constants }
  79. TopOn = true;
  80. TopOff = false;
  81. { fill pattern for Get/SetFillStyle: }
  82. EmptyFill = 0;
  83. SolidFill = 1;
  84. LineFill = 2;
  85. LtSlashFill = 3;
  86. SlashFill = 4;
  87. BkSlashFill = 5;
  88. LtBkSlashFill = 6;
  89. HatchFill = 7;
  90. XHatchFill = 8;
  91. InterleaveFill = 9;
  92. WideDotFill = 10;
  93. CloseDotFill = 11;
  94. UserFill = 12;
  95. { bitblt operators }
  96. NormalPut = 0;
  97. CopyPut = 0;
  98. XORPut = 1;
  99. OrPut = 2;
  100. AndPut = 3;
  101. NotPut = 4;
  102. { SetTextJustify constants }
  103. LeftText = 0;
  104. CenterText = 1;
  105. RightText = 2;
  106. BottomText = 0;
  107. TopText = 2;
  108. type
  109. RGBColor = record
  110. r,g,b,i : byte;
  111. end;
  112. PaletteType = record
  113. Size : integer;
  114. Colors : array[0..767]of Byte;
  115. end;
  116. LineSettingsType = record
  117. linestyle : word;
  118. pattern : word;
  119. thickness : word;
  120. end;
  121. TextSettingsType = record
  122. font : word;
  123. direction : word;
  124. charsize : word;
  125. horiz : word;
  126. vert : word;
  127. end;
  128. FillSettingsType = record
  129. pattern : word;
  130. color : longint;
  131. end;
  132. FillPatternType = array[1..8] of byte;
  133. PointType = record
  134. x,y : integer;
  135. end;
  136. ViewPortType = record
  137. x1,y1,x2,y2 : integer;
  138. Clip : boolean;
  139. end;
  140. ArcCoordsType = record
  141. x,y : integer;
  142. xstart,ystart : integer;
  143. xend,yend : integer;
  144. end;
  145. const
  146. fillpattern : array[0..12] of FillPatternType = (
  147. ($00,$00,$00,$00,$00,$00,$00,$00), { Hintergrundfarbe }
  148. ($ff,$ff,$ff,$ff,$ff,$ff,$ff,$ff), { Vordergrundfarbe }
  149. ($ff,$ff,$00,$00,$ff,$ff,$00,$00), { === }
  150. ($01,$02,$04,$08,$10,$20,$40,$80), { /// }
  151. ($07,$0e,$1c,$38,$70,$e0,$c1,$83), { /// als dicke Linien }
  152. ($07,$83,$c1,$e0,$70,$38,$1c,$0e), { \\\ als dicke Linien }
  153. ($5a,$2d,$96,$4b,$a5,$d2,$69,$b4), { \ \\ \ }
  154. ($ff,$88,$88,$88,$ff,$88,$88,$88), { K„stchen }
  155. ($18,$24,$42,$81,$81,$42,$24,$18), { Rauten }
  156. ($cc,$33,$cc,$33,$cc,$33,$cc,$33), { "Mauermuster" }
  157. ($80,$00,$08,$00,$80,$00,$08,$00), { weit auseinanderliegende Punkte }
  158. ($88,$00,$22,$00,$88,$00,$22,$00), { dichte Punkte}
  159. (0,0,0,0,0,0,0,0) { benutzerdefiniert }
  160. );
  161. {
  162. $Log$
  163. Revision 1.1.1.1 1998-03-25 11:18:42 root
  164. * Restored version
  165. Revision 1.4 1998/03/03 22:48:42 florian
  166. + graph.drawpoly procedure
  167. + putimage with xorput uses mmx if available
  168. Revision 1.3 1998/01/26 11:58:05 michael
  169. + Added log at the end
  170. Working file: rtl/dos/ppi/global.ppi
  171. description:
  172. ----------------------------
  173. revision 1.2
  174. date: 1997/12/01 12:21:30; author: michael; state: Exp; lines: +13 -0
  175. + added copyright reference in header.
  176. ----------------------------
  177. revision 1.1
  178. date: 1997/11/27 08:33:51; author: michael; state: Exp;
  179. Initial revision
  180. ----------------------------
  181. revision 1.1.1.1
  182. date: 1997/11/27 08:33:51; author: michael; state: Exp; lines: +0 -0
  183. FPC RTL CVS start
  184. =============================================================================
  185. }