ReactOS 0.4.16-dev-303-g11d5cb8
prntfont.h
Go to the documentation of this file.
1/*
2 * prntfont.h
3 *
4 * Declarations for Windows NT printer driver font metrics
5 *
6 * This file is part of the w32api package.
7 *
8 * Contributors:
9 * Created by Filip Navara <xnavara@volny.cz>
10 *
11 * THIS SOFTWARE IS NOT COPYRIGHTED
12 *
13 * This source code is offered for use in the public domain. You may
14 * use, modify or distribute it freely.
15 *
16 * This code is distributed in the hope that it will be useful but
17 * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY
18 * DISCLAIMED. This includes but is not limited to warranties of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
20 *
21 */
22
23#ifndef __PRNTFONT_H
24#define __PRNTFONT_H
25
26#define UNIFM_VERSION_1_0 0x10000
27#define UNI_GLYPHSETDATA_VERSION_1_0 0x10000
28
29#define UFM_SOFT 1
30#define UFM_CART 2
31#define UFM_SCALABLE 4
32
33#define DF_TYPE_HPINTELLIFONT 0
34#define DF_TYPE_TRUETYPE 1
35#define DF_TYPE_PST1 2
36#define DF_TYPE_CAPSL 3
37#define DF_TYPE_OEM1 4
38#define DF_TYPE_OEM2 5
39#define DF_NOITALIC 1
40#define DF_NOUNDER 2
41#define DF_XM_CR 4
42#define DF_NO_BOLD 8
43#define DF_NO_DOUBLE_UNDERLINE 16
44#define DF_NO_STRIKETHRU 32
45#define DF_BKSP_OK 64
46
47#define MTYPE_COMPOSE 1
48#define MTYPE_DIRECT 2
49#define MTYPE_PAIRED 4
50#define MTYPE_FORMAT_MASK 7
51#define MTYPE_SINGLE 8
52#define MTYPE_DOUBLE 16
53#define MTYPE_DOUBLEBYTECHAR_MASK 24
54#define MTYPE_REPLACE 32
55#define MTYPE_ADD 64
56#define MTYPE_DISABLE 128
57#define MTYPE_PREDEFIN_MASK 192
58
59#define CC_NOPRECNV 0x0000FFFF
60#define CC_DEFAULT 0
61#define CC_CP437 -1
62#define CC_CP850 -2
63#define CC_CP863 -3
64#define CC_BIG5 -10
65#define CC_ISC -11
66#define CC_JIS -12
67#define CC_JIS_ANK -13
68#define CC_NS86 -14
69#define CC_TCA -15
70#define CC_GB2312 -16
71#define CC_SJIS -17
72#define CC_WANSUNG -18
73
74#define UFF_FILE_MAGIC 'UFF1'
75#define UFF_VERSION_NUMBER 0x10001
76#define FONT_DIR_SORTED 1
77#define FONT_REC_SIG 'CERF'
78#define WINNT_INSTALLER_SIG 'IFTN'
79
80#define FONT_FL_UFM 0x0001
81#define FONT_FL_IFI 0x0002
82#define FONT_FL_SOFTFONT 0x0004
83#define FONT_FL_PERMANENT_SF 0x0008
84#define FONT_FL_DEVICEFONT 0x0010
85#define FONT_FL_GLYPHSET_GTT 0x0020
86#define FONT_FL_GLYPHSET_RLE 0x0040
87#define FONT_FL_RESERVED 0x8000
88
89#define DATA_UFM_SIG 'MFUD'
90#define DATA_IFI_SIG 'IFID'
91#define DATA_GTT_SIG 'TTGD'
92#define DATA_CTT_SIG 'TTCD'
93#define DATA_VAR_SIG 'RAVD'
94
95#define FG_CANCHANGE 128
96#define WM_FI_FILENAME 900
97
98#define GET_UNIDRVINFO(pUFM) ((PUNIDRVINFO)((ULONG_PTR)(pUFM) + (pUFM)->loUnidrvInfo))
99#define GET_IFIMETRICS(pUFM) ((IFIMETRICS*)((ULONG_PTR)(pUFM) + (pUFM)->loIFIMetrics))
100#define GET_EXTTEXTMETRIC(pUFM) ((EXTTEXTMETRIC*)((ULONG_PTR)(pUFM) + (pUFM)->loExtTextMetric))
101#define GET_WIDTHTABLE(pUFM) ((PWIDTHTABLE)((ULONG_PTR)(pUFM) + (pUFM)->loWidthTable))
102#define GET_KERNDATA(pUFM) ((PKERNDATA)((ULONG_PTR)(pUFM) + (pUFM)->loKernPair))
103#define GET_SELECT_CMD(pUni) ((PCHAR)(pUni) + (pUni)->SelectFont.loOffset)
104#define GET_UNSELECT_CMD(pUni) ((PCHAR)(pUni) + (pUni)->UnSelectFont.loOffset)
105#define GET_GLYPHRUN(pGTT) ((PGLYPHRUN)((ULONG_PTR)(pGTT) + ((PUNI_GLYPHSETDATA)pGTT)->loRunOffset))
106#define GET_CODEPAGEINFO(pGTT) ((PUNI_CODEPAGEINFO)((ULONG_PTR)(pGTT) + ((PUNI_GLYPHSETDATA)pGTT)->loCodePageOffset))
107#define GET_MAPTABLE(pGTT) ((PMAPTABLE)((ULONG_PTR)(pGTT) + ((PUNI_GLYPHSETDATA)pGTT)->loMapTableOffset))
108
109typedef struct _UNIFM_HDR
110{
122
123typedef struct _INVOC
124{
128
129typedef struct _UNIDRVINFO
130{
145
146typedef struct _EXTTEXTMETRIC
147{
175
176typedef struct _WIDTHRUN
177{
182
183typedef struct _WIDTHTABLE
184{
189
190typedef struct _KERNDATA
191{
196
197typedef struct _UNI_GLYPHSETDATA
198{
211
212typedef struct _UNI_CODEPAGEINFO
213{
218
219typedef struct _GLYPHRUN
220{
224
225typedef struct _TRANSDATA
226{
229 union
230 {
236
237typedef struct _MAPTABLE {
242
243typedef struct _UFF_FILEHEADER {
254
255typedef struct _UFF_FONTDIRECTORY {
268
269typedef struct _DATA_HEADER {
276
277typedef struct _OEMFONTINSTPARAM {
285
286#endif /* __PRNTFONT_H */
unsigned long DWORD
Definition: ntddk_ex.h:95
unsigned short WORD
Definition: ntddk_ex.h:93
_In_ HANDLE _In_ DWORD _In_ DWORD _Inout_opt_ LPOVERLAPPED _In_opt_ LPTRANSMIT_FILE_BUFFERS _In_ DWORD dwReserved
Definition: mswsock.h:95
short SHORT
Definition: pedump.c:59
long LONG
Definition: pedump.c:60
struct _UFF_FILEHEADER UFF_FILEHEADER
struct _UNI_CODEPAGEINFO * PUNI_CODEPAGEINFO
struct _UNI_GLYPHSETDATA UNI_GLYPHSETDATA
struct _GLYPHRUN * PGLYPHRUN
struct _UNIDRVINFO UNIDRVINFO
struct _GLYPHRUN GLYPHRUN
struct _WIDTHRUN WIDTHRUN
struct _TRANSDATA TRANSDATA
struct _TRANSDATA * PTRANSDATA
struct _EXTTEXTMETRIC * PEXTTEXTMETRIC
struct _KERNDATA * PKERNDATA
struct _DATA_HEADER * PDATA_HEADER
struct _DATA_HEADER DATA_HEADER
struct _UNIFM_HDR UNIFM_HDR
struct _UFF_FONTDIRECTORY * PUFF_FONTDIRECTORY
struct _EXTTEXTMETRIC EXTTEXTMETRIC
struct _UNI_CODEPAGEINFO UNI_CODEPAGEINFO
struct _WIDTHRUN * PWIDTHRUN
struct _INVOC INVOC
struct _UFF_FILEHEADER * PUFF_FILEHEADER
struct _UNI_GLYPHSETDATA * PUNI_GLYPHSETDATA
struct _INVOC * PINVOC
struct _UNIFM_HDR * PUNIFM_HDR
struct _MAPTABLE * PMAPTABLE
struct _OEMFONTINSTPARAM OEMFONTINSTPARAM
struct _KERNDATA KERNDATA
struct _WIDTHTABLE WIDTHTABLE
struct _OEMFONTINSTPARAM * POEMFONTINSTPARAM
struct _WIDTHTABLE * PWIDTHTABLE
struct _MAPTABLE MAPTABLE
struct _UFF_FONTDIRECTORY UFF_FONTDIRECTORY
struct _UNIDRVINFO * PUNIDRVINFO
DWORD dwSignature
Definition: prntfont.h:270
DWORD dwReserved
Definition: prntfont.h:274
WORD wSize
Definition: prntfont.h:271
WORD wDataID
Definition: prntfont.h:272
DWORD dwDataSize
Definition: prntfont.h:273
SHORT emDoubleLowerUnderlineWidth
Definition: prntfont.h:169
SHORT emXHeight
Definition: prntfont.h:156
SHORT emSuperScript
Definition: prntfont.h:160
SHORT emMasterHeight
Definition: prntfont.h:151
WORD emKernTracks
Definition: prntfont.h:173
SHORT emMaxScale
Definition: prntfont.h:153
SHORT emUnderlineOffset
Definition: prntfont.h:164
SHORT emLowerCaseAscent
Definition: prntfont.h:157
SHORT emSubScript
Definition: prntfont.h:161
SHORT emLowerCaseDescent
Definition: prntfont.h:158
SHORT emStrikeOutOffset
Definition: prntfont.h:170
SHORT emDoubleUpperUnderlineWidth
Definition: prntfont.h:168
SHORT emSuperScriptSize
Definition: prntfont.h:162
SHORT emDoubleUpperUnderlineOffset
Definition: prntfont.h:166
SHORT emStrikeOutWidth
Definition: prntfont.h:171
SHORT emSlant
Definition: prntfont.h:159
SHORT emDoubleLowerUnderlineOffset
Definition: prntfont.h:167
SHORT emSize
Definition: prntfont.h:148
SHORT emCapHeight
Definition: prntfont.h:155
SHORT emPointSize
Definition: prntfont.h:149
WORD emKernPairs
Definition: prntfont.h:172
SHORT emUnderlineWidth
Definition: prntfont.h:165
SHORT emMasterUnits
Definition: prntfont.h:154
SHORT emMinScale
Definition: prntfont.h:152
SHORT emSubScriptSize
Definition: prntfont.h:163
SHORT emOrientation
Definition: prntfont.h:150
WCHAR wcLow
Definition: prntfont.h:221
WORD wGlyphCount
Definition: prntfont.h:222
DWORD loOffset
Definition: prntfont.h:126
DWORD dwCount
Definition: prntfont.h:125
DWORD dwKernPairNum
Definition: prntfont.h:193
DWORD dwSize
Definition: prntfont.h:192
FD_KERNINGPAIR KernPair[1]
Definition: prntfont.h:194
DWORD dwSize
Definition: prntfont.h:238
TRANSDATA Trans[1]
Definition: prntfont.h:240
DWORD dwGlyphNum
Definition: prntfont.h:239
PWSTR pFontInstallerName
Definition: prntfont.h:283
SHORT sCode
Definition: prntfont.h:231
union _TRANSDATA::@3197 uCode
BYTE ubCode
Definition: prntfont.h:232
BYTE ubPairs[2]
Definition: prntfont.h:233
BYTE ubCodePageID
Definition: prntfont.h:227
BYTE ubType
Definition: prntfont.h:228
DWORD dwVersion
Definition: prntfont.h:245
DWORD offFontDir
Definition: prntfont.h:250
DWORD dwSignature
Definition: prntfont.h:244
DWORD nGlyphSets
Definition: prntfont.h:248
DWORD nVarData
Definition: prntfont.h:249
DWORD dwInstallerSig
Definition: prntfont.h:261
DWORD offCartridgeName
Definition: prntfont.h:263
INVOC UnSelectFont
Definition: prntfont.h:142
WORD wXRes
Definition: prntfont.h:135
WORD fCaps
Definition: prntfont.h:134
SHORT sYMoved
Definition: prntfont.h:138
WORD wYRes
Definition: prntfont.h:136
SHORT sShift
Definition: prntfont.h:140
WORD wReserved[4]
Definition: prntfont.h:143
INVOC SelectFont
Definition: prntfont.h:141
DWORD dwSize
Definition: prntfont.h:131
WORD wPrivateData
Definition: prntfont.h:139
SHORT sYAdjust
Definition: prntfont.h:137
WORD wType
Definition: prntfont.h:133
DWORD flGenFlags
Definition: prntfont.h:132
LONG lGlyphSetDataRCID
Definition: prntfont.h:114
DWORD loWidthTable
Definition: prntfont.h:118
DWORD loExtTextMetric
Definition: prntfont.h:117
DWORD dwVersion
Definition: prntfont.h:112
DWORD loKernPair
Definition: prntfont.h:119
ULONG ulDefaultCodepage
Definition: prntfont.h:113
DWORD loIFIMetrics
Definition: prntfont.h:116
DWORD dwSize
Definition: prntfont.h:111
DWORD loUnidrvInfo
Definition: prntfont.h:115
INVOC UnSelectSymbolSet
Definition: prntfont.h:216
INVOC SelectSymbolSet
Definition: prntfont.h:215
DWORD dwCodePageCount
Definition: prntfont.h:206
DWORD dwGlyphCount
Definition: prntfont.h:203
DWORD loCodePageOffset
Definition: prntfont.h:207
DWORD loMapTableOffset
Definition: prntfont.h:208
WORD wGlyphCount
Definition: prntfont.h:179
DWORD loCharWidthOffset
Definition: prntfont.h:180
WORD wStartGlyph
Definition: prntfont.h:178
DWORD dwRunNum
Definition: prntfont.h:186
WIDTHRUN WidthRun[1]
Definition: prntfont.h:187
DWORD dwSize
Definition: prntfont.h:185
uint16_t * PWSTR
Definition: typedefs.h:56
uint32_t ULONG
Definition: typedefs.h:59
__wchar_t WCHAR
Definition: xmlstorage.h:180
unsigned char BYTE
Definition: xxhash.c:193