3 Copyright 1990, 1994, 1998 The Open Group
5 Permission to use, copy, modify, distribute, and sell this software and its
6 documentation for any purpose is hereby granted without fee, provided that
7 the above copyright notice appear in all copies and that both that
8 copyright notice and this permission notice appear in supporting
11 The above copyright notice and this permission notice shall be included
12 in all copies or substantial portions of the Software.
14 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
15 OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
16 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
17 IN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
18 OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
19 ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
20 OTHER DEALINGS IN THE SOFTWARE.
22 Except as contained in this notice, the name of The Open Group shall
23 not be used in advertising or otherwise to promote the sale, use or
24 other dealings in this Software without prior written authorization
30 * Author: Keith Packard, MIT X Consortium
36 #include <X11/fonts/FSproto.h>
38 /* Constants for values_supplied bitmap */
40 #define SIZE_SPECIFY_MASK 0xf
42 #define PIXELSIZE_MASK 0x3
43 #define PIXELSIZE_UNDEFINED 0
44 #define PIXELSIZE_SCALAR 0x1
45 #define PIXELSIZE_ARRAY 0x2
46 #define PIXELSIZE_SCALAR_NORMALIZED 0x3 /* Adjusted for resolution */
48 #define POINTSIZE_MASK 0xc
49 #define POINTSIZE_UNDEFINED 0
50 #define POINTSIZE_SCALAR 0x4
51 #define POINTSIZE_ARRAY 0x8
53 #define PIXELSIZE_WILDCARD 0x10
54 #define POINTSIZE_WILDCARD 0x20
56 #define ENHANCEMENT_SPECIFY_MASK 0x40
58 #define CHARSUBSET_SPECIFIED 0x40
61 #define XLFD_NDIGITS 3 /* Round numbers in pixel and
62 point arrays to this many
63 digits for repeatability */
65 typedef struct _FontScalable {
66 int values_supplied; /* Bitmap identifying what advanced
67 capabilities or enhancements
68 were specified in the font name */
69 double pixel_matrix[4];
70 double point_matrix[4];
72 /* Pixel and point fields are deprecated in favor of the
73 transformation matrices. They are provided and filled in for the
74 benefit of rasterizers that do not handle the matrices. */
85 } FontScalableRec, *FontScalablePtr;
88 extern double xlfd_round_double ( double x );
89 extern Bool FontParseXLFDName ( char *fname, FontScalablePtr vals, int subst );
90 extern fsRange *FontParseRanges ( char *name, int *nranges );
92 #define FONT_XLFD_REPLACE_NONE 0
93 #define FONT_XLFD_REPLACE_STAR 1
94 #define FONT_XLFD_REPLACE_ZERO 2
95 #define FONT_XLFD_REPLACE_VALUE 3
97 #endif /* _FONTXLFD_H_ */