1 | /**************************************************************************** |
2 | * |
3 | * ftfntfmt.h |
4 | * |
5 | * Support functions for font formats. |
6 | * |
7 | * Copyright (C) 2002-2023 by |
8 | * David Turner, Robert Wilhelm, and Werner Lemberg. |
9 | * |
10 | * This file is part of the FreeType project, and may only be used, |
11 | * modified, and distributed under the terms of the FreeType project |
12 | * license, LICENSE.TXT. By continuing to use, modify, or distribute |
13 | * this file you indicate that you have read the license and |
14 | * understand and accept it fully. |
15 | * |
16 | */ |
17 | |
18 | |
19 | #ifndef FTFNTFMT_H_ |
20 | #define FTFNTFMT_H_ |
21 | |
22 | #include <freetype/freetype.h> |
23 | |
24 | #ifdef FREETYPE_H |
25 | #error "freetype.h of FreeType 1 has been loaded!" |
26 | #error "Please fix the directory search order for header files" |
27 | #error "so that freetype.h of FreeType 2 is found first." |
28 | #endif |
29 | |
30 | |
31 | FT_BEGIN_HEADER |
32 | |
33 | |
34 | /************************************************************************** |
35 | * |
36 | * @section: |
37 | * font_formats |
38 | * |
39 | * @title: |
40 | * Font Formats |
41 | * |
42 | * @abstract: |
43 | * Getting the font format. |
44 | * |
45 | * @description: |
46 | * The single function in this section can be used to get the font format. |
47 | * Note that this information is not needed normally; however, there are |
48 | * special cases (like in PDF devices) where it is important to |
49 | * differentiate, in spite of FreeType's uniform API. |
50 | * |
51 | */ |
52 | |
53 | |
54 | /************************************************************************** |
55 | * |
56 | * @function: |
57 | * FT_Get_Font_Format |
58 | * |
59 | * @description: |
60 | * Return a string describing the format of a given face. Possible values |
61 | * are 'TrueType', 'Type~1', 'BDF', 'PCF', 'Type~42', 'CID~Type~1', 'CFF', |
62 | * 'PFR', and 'Windows~FNT'. |
63 | * |
64 | * The return value is suitable to be used as an X11 FONT_PROPERTY. |
65 | * |
66 | * @input: |
67 | * face :: |
68 | * Input face handle. |
69 | * |
70 | * @return: |
71 | * Font format string. `NULL` in case of error. |
72 | * |
73 | * @note: |
74 | * A deprecated name for the same function is `FT_Get_X11_Font_Format`. |
75 | */ |
76 | FT_EXPORT( const char* ) |
77 | FT_Get_Font_Format( FT_Face face ); |
78 | |
79 | |
80 | /* deprecated */ |
81 | FT_EXPORT( const char* ) |
82 | FT_Get_X11_Font_Format( FT_Face face ); |
83 | |
84 | |
85 | /* */ |
86 | |
87 | |
88 | FT_END_HEADER |
89 | |
90 | #endif /* FTFNTFMT_H_ */ |
91 | |
92 | |
93 | /* END */ |
94 | |