added concrete implementations of putc(), getc(), getchar() and gets()
[tangerine.git] / compiler / include / intuition / preferences.h
blob1447df00c6e9a3a78618fd3c329d8571bd199cbd
1 #ifndef INTUITION_PREFERENCES_H
2 #define INTUITION_PREFERENCES_H
4 /*
5 Copyright © 1995-2004, The AROS Development Team. All rights reserved.
6 $Id$
8 Old-style preferences structures and defines.
9 */
11 #ifndef EXEC_TYPES_H
12 # include <exec/types.h>
13 #endif
14 #ifndef DEVICES_TIMER_H
15 # include <devices/timer.h>
16 #endif
18 /* Printer configurations */
19 #define FILENAME_SIZE 30
20 #define DEVNAME_SIZE 16
22 /* Size of Pointer data buffer */
23 #define POINTERSIZE ((1+16+1)*2)
26 /* Default font sizes */
27 /* (Height of default font topaz in 60/80 column mode */
28 #define TOPAZ_EIGHTY 8
29 #define TOPAZ_SIXTY 9
31 /* NOTE: From V36 on fields of struct Preferences are ignored by SetPrefs().
32 * Generally elements are added or replaced as new hard- and software arise.
33 * Some fields can only be set by initial SetPrefs() using
34 * DEVS:system-configuration. Some data must be truncated so applications
35 * calling GetPrefs() modifying parts of the struct References and calling
36 * SetPrefs() do not kill data.
37 * See GetPrefs() and SetPrefs() for further information.
40 struct Preferences
42 BYTE FontHeight;
43 UBYTE PrinterPort; /* Printer port connection */
44 UWORD BaudRate; /* Baud rate for the serial port */
46 /* Timing rates */
47 struct timeval KeyRptSpeed; /* Repeat speed for keyboard */
48 struct timeval KeyRptDelay; /* Delay before keys repeat */
49 struct timeval DoubleClick; /* Interval allowed between clicks */
51 /* Intuition Mouse-Pointer data */
52 UWORD PointerMatrix[POINTERSIZE]; /* Definition of pointer sprite */
53 BYTE XOffset; /* X-Offset for hot spot */
54 BYTE YOffset; /* Y-Offset for hot spot */
55 UWORD color17; /* Colors for pointer sprite */
56 UWORD color18; /* " " " " */
57 UWORD color19; /* " " " " */
58 UWORD PointerTicks; /* Sensitivity of the pointer */
60 /* Standard 4 Workbench-Screen colors */
61 UWORD color0;
62 UWORD color1;
63 UWORD color2;
64 UWORD color3;
66 /* Positioning data for the Intuition View */
67 BYTE ViewXOffset; /* Offset for top-left corner */
68 BYTE ViewYOffset;
69 WORD ViewInitX; /* Initial offset values of View */
70 WORD ViewInitY;
72 BOOL EnableCLI; /* CLI availability switch */
74 /* Printer configurations */
75 UWORD PrinterType; /* printer type */
76 UBYTE PrinterFilename[FILENAME_SIZE]; /* file for printer */
78 /* Print format and quality configurations */
79 UWORD PrintPitch; /* Print pitch */
80 UWORD PrintQuality; /* Print quality */
81 UWORD PrintSpacing; /* Number of lines per inch */
82 UWORD PrintLeftMargin; /* Left margin in characters */
83 UWORD PrintRightMargin; /* Right margin in characters */
84 UWORD PrintImage; /* Positive or negative */
85 UWORD PrintAspect; /* Horizontal or vertical */
86 UWORD PrintShade; /* B&W, half-tone, or color */
87 WORD PrintThreshold; /* Darkness control for b/w dumps */
89 /* Print-paper description */
90 UWORD PaperSize; /* Paper size */
91 UWORD PaperLength; /* Paper length in number of lines */
92 UWORD PaperType; /* Continuous or single sheet */
94 /* Serial device settings:
95 * six nibble-fields in three bytes
97 UBYTE SerRWBits; /* Upper nibble = (8-number of read bits) */
98 /* Lower nibble = (8-number of write bits) */
99 UBYTE SerStopBuf; /* Upper nibble = (number of stop bits - 1) */
100 /* Lower nibble = (table value for BufSize) */
101 UBYTE SerParShk; /* Upper nibble = (value for Parity setting) */
102 /* Lower nibble = (value for Handshake mode) */
103 UBYTE LaceWB; /* If workbench is to be interlaced */
105 UBYTE Pad[12];
106 UBYTE PrtDevName[DEVNAME_SIZE]; /* Device used by printer.device
107 * (leave out the ".device")
109 UBYTE DefaultPrtUnit; /* Default unit opened by printer.device */
110 UBYTE DefaultSerUnit; /* Default serial unit */
112 BYTE RowSizeChange; /* Affect NormalDisplayRows/Columns */
113 BYTE ColumnSizeChange;
115 UWORD PrintFlags; /* User preference flags */
116 UWORD PrintMaxWidth; /* Max width of printed picture in 0.1 inch */
117 UWORD PrintMaxHeight; /* Max height of printed picture in 0.1 inch */
118 UBYTE PrintDensity; /* Print density */
119 UBYTE PrintXOffset; /* Offset of printed picture in 0.1 inch */
121 UWORD wb_Width; /* Override default Workbench width */
122 UWORD wb_Height; /* Override default Workbench height */
123 UBYTE wb_Depth; /* Override default Workbench depth */
125 UBYTE ext_size; /* Internal value 'extension information'
126 * = extension size in blocks of 64 bytes
127 * DO NOT TOUCH !!!
132 /* Workbench Interlace (uses one bit) */
133 #define LACEWB (1<<0)
134 #define LW_RESERVED 1 /* internal use only */
136 #define SCREEN_DRAG (1<<14)
137 #define MOUSE_ACCEL (1L<<15)
139 /* PrinterPort */
140 #define PARALLEL_PRINTER 0x00
141 #define SERIAL_PRINTER 0x01
143 /* BaudRates */
144 #define BAUD_110 0x00
145 #define BAUD_300 0x01
146 #define BAUD_1200 0x02
147 #define BAUD_2400 0x03
148 #define BAUD_4800 0x04
149 #define BAUD_9600 0x05
150 #define BAUD_19200 0x06
151 #define BAUD_MIDI 0x07
153 /* PaperType */
154 #define FANFOLD 0x00
155 #define SINGLE 0x80
157 /* PrintPitch */
158 #define PICA 0x000
159 #define ELITE 0x400
160 #define FINE 0x800
162 /* PrintQuality */
163 #define DRAFT 0x000
164 #define LETTER 0x100
166 /* PrintSpacing */
167 #define SIX_LPI 0x000
168 #define EIGHT_LPI 0x200
170 /* Print Image */
171 #define IMAGE_POSITIVE 0x00
172 #define IMAGE_NEGATIVE 0x01
174 /* PrintAspect */
175 #define ASPECT_HORIZ 0x00
176 #define ASPECT_VERT 0x01
178 /* PrintShade */
179 #define SHADE_BW 0x00
180 #define SHADE_GREYSCALE 0x01
181 #define SHADE_COLOR 0x02
183 /* PaperSize (All paper sizes must have a zero in the lowest nibble) */
184 #define US_LETTER 0x00
185 #define US_LEGAL 0x10
186 #define N_TRACTOR 0x20
187 #define W_TRACTOR 0x30
188 #define CUSTOM 0x40
190 /* European sizes */
191 #define EURO_A0 0x50 /* A0: 841 x 1189 */
192 #define EURO_A1 0x60 /* A1: 594 x 841 */
193 #define EURO_A2 0x70 /* A2: 420 x 594 */
194 #define EURO_A3 0x80 /* A3: 297 x 420 */
195 #define EURO_A4 0x90 /* A4: 210 x 297 */
196 #define EURO_A5 0xA0 /* A5: 148 x 210 */
197 #define EURO_A6 0xB0 /* A6: 105 x 148 */
198 #define EURO_A7 0xC0 /* A7: 74 x 105 */
199 #define EURO_A8 0xD0 /* A8: 52 x 74 */
201 /* PrinterType */
202 #define CUSTOM_NAME 0x00
203 #define ALPHA_P_101 0x01
204 #define BROTHER_15XL 0x02
205 #define CBM_MPS1000 0x03
206 #define DIAB_630 0x04
207 #define DIAB_ADV_D25 0x05
208 #define DIAB_C_150 0x06
209 #define EPSON 0x07
210 #define EPSON_JX_80 0x08
211 #define OKIMATE_20 0x09
212 #define QUME_LP_20 0x0A
213 #define HP_LASERJET 0x0B
214 #define HP_LASERJET_PLUS 0x0C
216 /* Serial Input Buffer Sizes */
217 #define SBUF_512 0x00
218 #define SBUF_1024 0x01
219 #define SBUF_2048 0x02
220 #define SBUF_4096 0x03
221 #define SBUF_8000 0x04
222 #define SBUF_16000 0x05
224 /* Serial Bit Masks */
225 #define SREAD_BITS 0xF0 /* SerRWBits */
226 #define SWRITE_BITS 0x0F
228 #define SSTOP_BITS 0xF0 /* SerStopBuf */
229 #define SBUFSIZE_BITS 0x0F
231 #define SPARITY_BITS 0xF0 /* SerParShk */
232 #define SHSHAKE_BITS 0x0F
234 /* Serial Parity
235 * (upper nibble, after being shifted by macro SPARNUM() )
237 #define SPARITY_NONE 0
238 #define SPARITY_EVEN 1
239 #define SPARITY_ODD 2
240 #define SPARITY_MARK 3
241 #define SPARITY_SPACE 4
243 /* Serial Handshake Mode
244 * (lower nibble, after masking using macro SHANKNUM() )
246 #define SHSHAKE_XON 0
247 #define SHSHAKE_RTS 1
248 #define SHSHAKE_NONE 2
251 /* New defines for PrintFlags */
253 #define CORRECT_RED 0x0001 /* Color correct red shades */
254 #define CORRECT_GREEN 0x0002 /* Color correct green shades */
255 #define CORRECT_BLUE 0x0004 /* Color correct blue shades */
257 #define CENTER_IMAGE 0x0008 /* Center image on paper */
259 #define IGNORE_DIMENSIONS 0x0000 /* Ignore max width/height settings */
260 #define BOUNDED_DIMENSIONS 0x0010 /* Use max width/height as boundaries */
261 #define ABSOLUTE_DIMENSIONS 0x0020 /* Use max width/height as absolutes */
262 #define PIXEL_DIMENSIONS 0x0040 /* Use max width/height as printer pixels */
263 #define MULTIPLY_DIMENSIONS 0x0080 /* Use max width/height as multipliers */
265 #define INTEGER_SCALING 0x0100 /* Force integer scaling */
267 #define ORDERED_DITHERING 0x0000 /* Ordered dithering */
268 #define HALFTONE_DITHERING 0x0200 /* Halftone dithering */
269 #define FLOYD_DITHERING 0x0400 /* Floyd-Steinberg dithering */
271 #define ANTI_ALIAS 0x0800 /* Anti-alias image */
272 #define GREY_SCALE2 0x1000 /* For use with HI-Res monitor */
274 /* masks used for checking bits */
275 #define CORRECT_RGB_MASK (CORRECT_RED|CORRECT_GREEN|CORRECT_BLUE)
276 #define DIMENSIONS_MASK (BOUNDED_DIMENSIONS|ABSOLUTE_DIMENSIONS|PIXEL_DIMENSIONS|MULTIPLY_DIMENSIONS)
277 #define DITHERING_MASK (HALFTONE_DITHERING|FLOYD_DITHERING)
279 #endif /* INTUITION_PREFERENCES_H */