|
|
1.1 root 1: /*********************** MODULE HEADER ************************************
2: * fontfile.h
3: * Definitions used in the font file. This is the file which holds
4: * information about cartridge and download fonts. The file format
5: * is quite basic: a header for verification; then an array of
6: * records, each with a header. These records contain FONTMAP
7: * information. Cartridges have an array of these, one for each
8: * font. Finally, the tail of the file contains extra data, as
9: * required. For download fonts, this would be the download data.
10: *
11: * Copyright (C) 1992 Microsoft Corporation
12: *
13: ***************************************************************************/
14:
15: /*
16: * The file header. One of these is located at the beginning of the file.
17: * The ulVarData field is relative to the beginning of the file. This
18: * makes it easier to regenerate the file when fonts are deleted.
19: */
20:
21: typedef struct
22: {
23: ULONG ulID; /* ID info - see value below */
24: ULONG ulVersion; /* Version information - see below */
25: ULONG ulFixData; /* Start of FF_REC_HEADER array */
26: ULONG ulFixSize; /* Number of bytes in fixed section */
27: ULONG ulRecCount; /* Number of records in fixed part */
28: ULONG ulVarData; /* Start of variable data, rel to 0 */
29: ULONG ulVarSize; /* Numbier of bytes in variable portion */
30: } FF_HEADER;
31:
32: /*
33: * Values for the ID and Version fields.
34: */
35:
36: #define FF_ID 0x6c666e66 /* "fnfl" - fOnTfIlE */
37: #define FF_VERSION 1 /* Start at the bottom */
38:
39: /*
40: * Each entry in the file starts with the following header. Typically
41: * there will be one of these for a softfont, and one per cartridge.
42: * In the case of a cartridge, there will be an array of these, within
43: * the master entry. Each sub-entry will be for one specific font.
44: *
45: * Note that there is a dummy entry at the end. This contains a 0
46: * in the ulSize field - it is to mark the last one, and makes it
47: * easier to manipulate the file.
48: */
49:
50: typedef struct
51: {
52: ULONG ulRID; /* Record ID */
53: ULONG ulNextOff; /* Offset from here to next record: 0 == end */
54: ULONG ulSize; /* Bytes in this record */
55: ULONG ulVarOff; /* Offset from start of variable data */
56: ULONG ulVarSize; /* Number of bytes in variable part */
57: } FF_REC_HEADER;
58:
59: #define FR_ID 0x63657266 /* "frec" - fONT recORD */
60:
61: /*
62: * Define the file extensions used. The first is the name of the
63: * font installer file; the others are temporaries used during update
64: * of the (possibly) existing file.
65: */
66:
67:
68: #define FILE_FONTS L"fi_" /* "Existing" single file */
69: #define TFILE_FIX L"fiX" /* Fixed part of file */
70: #define TFILE_VAR L"fiV" /* Variable (optional) portion */
This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.