jassub 1.7.11 → 1.7.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +22 -22
- package/README.md +251 -251
- package/dist/COPYRIGHT +951 -951
- package/dist/jassub-worker-modern.wasm +0 -0
- package/dist/jassub-worker.js +11 -11
- package/dist/jassub-worker.wasm +0 -0
- package/dist/jassub-worker.wasm.js +1 -1
- package/dist/jassub.es.js +1 -1
- package/dist/jassub.umd.js +1 -1
- package/dist/js/jassub-worker-modern.js +119 -1
- package/dist/js/jassub-worker-modern.wasm +0 -0
- package/dist/js/jassub-worker.js +122 -4
- package/dist/js/jassub-worker.wasm +0 -0
- package/dist/js/jassub-worker.wasm.js +26 -25
- package/dist/js/jassub.js +832 -832
- package/dist/libraries/bin/brotli.js +1 -0
- package/dist/libraries/include/ass/ass.h +812 -0
- package/dist/libraries/include/ass/ass_types.h +292 -0
- package/dist/libraries/include/brotli/decode.h +344 -0
- package/dist/libraries/include/brotli/encode.h +448 -0
- package/dist/libraries/include/brotli/port.h +288 -0
- package/dist/libraries/include/brotli/types.h +83 -0
- package/dist/libraries/include/expat.h +1064 -0
- package/dist/libraries/include/expat_config.h +115 -0
- package/dist/libraries/include/expat_external.h +165 -0
- package/dist/libraries/include/fontconfig/fcfreetype.h +59 -0
- package/dist/libraries/include/fontconfig/fcprivate.h +134 -0
- package/dist/libraries/include/fontconfig/fontconfig.h +1154 -0
- package/dist/libraries/include/freetype2/freetype/config/ftconfig.h +63 -0
- package/dist/libraries/include/freetype2/freetype/config/ftheader.h +824 -0
- package/dist/libraries/include/freetype2/freetype/config/ftmodule.h +20 -0
- package/dist/libraries/include/freetype2/freetype/config/ftoption.h +1011 -0
- package/dist/libraries/include/freetype2/freetype/config/ftstdlib.h +175 -0
- package/dist/libraries/include/freetype2/freetype/config/integer-types.h +245 -0
- package/dist/libraries/include/freetype2/freetype/config/mac-support.h +49 -0
- package/dist/libraries/include/freetype2/freetype/config/public-macros.h +120 -0
- package/dist/libraries/include/freetype2/freetype/freetype.h +4833 -0
- package/dist/libraries/include/freetype2/freetype/ftadvanc.h +188 -0
- package/dist/libraries/include/freetype2/freetype/ftbbox.h +101 -0
- package/dist/libraries/include/freetype2/freetype/ftbdf.h +212 -0
- package/dist/libraries/include/freetype2/freetype/ftbitmap.h +329 -0
- package/dist/libraries/include/freetype2/freetype/ftbzip2.h +102 -0
- package/dist/libraries/include/freetype2/freetype/ftcache.h +1087 -0
- package/dist/libraries/include/freetype2/freetype/ftchapters.h +147 -0
- package/dist/libraries/include/freetype2/freetype/ftcid.h +167 -0
- package/dist/libraries/include/freetype2/freetype/ftcolor.h +1609 -0
- package/dist/libraries/include/freetype2/freetype/ftdriver.h +1193 -0
- package/dist/libraries/include/freetype2/freetype/fterrdef.h +279 -0
- package/dist/libraries/include/freetype2/freetype/fterrors.h +296 -0
- package/dist/libraries/include/freetype2/freetype/ftfntfmt.h +93 -0
- package/dist/libraries/include/freetype2/freetype/ftgasp.h +143 -0
- package/dist/libraries/include/freetype2/freetype/ftglyph.h +664 -0
- package/dist/libraries/include/freetype2/freetype/ftgxval.h +354 -0
- package/dist/libraries/include/freetype2/freetype/ftgzip.h +151 -0
- package/dist/libraries/include/freetype2/freetype/ftimage.h +1276 -0
- package/dist/libraries/include/freetype2/freetype/ftincrem.h +348 -0
- package/dist/libraries/include/freetype2/freetype/ftlcdfil.h +323 -0
- package/dist/libraries/include/freetype2/freetype/ftlist.h +296 -0
- package/dist/libraries/include/freetype2/freetype/ftlogging.h +184 -0
- package/dist/libraries/include/freetype2/freetype/ftlzw.h +100 -0
- package/dist/libraries/include/freetype2/freetype/ftmac.h +289 -0
- package/dist/libraries/include/freetype2/freetype/ftmm.h +752 -0
- package/dist/libraries/include/freetype2/freetype/ftmodapi.h +806 -0
- package/dist/libraries/include/freetype2/freetype/ftmoderr.h +204 -0
- package/dist/libraries/include/freetype2/freetype/ftotval.h +206 -0
- package/dist/libraries/include/freetype2/freetype/ftoutln.h +586 -0
- package/dist/libraries/include/freetype2/freetype/ftparams.h +203 -0
- package/dist/libraries/include/freetype2/freetype/ftpfr.h +179 -0
- package/dist/libraries/include/freetype2/freetype/ftrender.h +244 -0
- package/dist/libraries/include/freetype2/freetype/ftsizes.h +159 -0
- package/dist/libraries/include/freetype2/freetype/ftsnames.h +272 -0
- package/dist/libraries/include/freetype2/freetype/ftstroke.h +773 -0
- package/dist/libraries/include/freetype2/freetype/ftsynth.h +83 -0
- package/dist/libraries/include/freetype2/freetype/ftsystem.h +352 -0
- package/dist/libraries/include/freetype2/freetype/fttrigon.h +350 -0
- package/dist/libraries/include/freetype2/freetype/fttypes.h +615 -0
- package/dist/libraries/include/freetype2/freetype/ftwinfnt.h +276 -0
- package/dist/libraries/include/freetype2/freetype/t1tables.h +773 -0
- package/dist/libraries/include/freetype2/freetype/ttnameid.h +1235 -0
- package/dist/libraries/include/freetype2/freetype/tttables.h +855 -0
- package/dist/libraries/include/freetype2/freetype/tttags.h +123 -0
- package/dist/libraries/include/freetype2/ft2build.h +42 -0
- package/dist/libraries/include/fribidi/fribidi-arabic.h +81 -0
- package/dist/libraries/include/fribidi/fribidi-begindecls.h +3 -0
- package/dist/libraries/include/fribidi/fribidi-bidi-types-list.h +96 -0
- package/dist/libraries/include/fribidi/fribidi-bidi-types.h +405 -0
- package/dist/libraries/include/fribidi/fribidi-bidi.h +142 -0
- package/dist/libraries/include/fribidi/fribidi-brackets.h +89 -0
- package/dist/libraries/include/fribidi/fribidi-char-sets-list.h +54 -0
- package/dist/libraries/include/fribidi/fribidi-char-sets.h +106 -0
- package/dist/libraries/include/fribidi/fribidi-common.h +158 -0
- package/dist/libraries/include/fribidi/fribidi-config.h +23 -0
- package/dist/libraries/include/fribidi/fribidi-deprecated.h +175 -0
- package/dist/libraries/include/fribidi/fribidi-enddecls.h +3 -0
- package/dist/libraries/include/fribidi/fribidi-flags.h +72 -0
- package/dist/libraries/include/fribidi/fribidi-joining-types-list.h +44 -0
- package/dist/libraries/include/fribidi/fribidi-joining-types.h +249 -0
- package/dist/libraries/include/fribidi/fribidi-joining.h +74 -0
- package/dist/libraries/include/fribidi/fribidi-mirroring.h +86 -0
- package/dist/libraries/include/fribidi/fribidi-shape.h +71 -0
- package/dist/libraries/include/fribidi/fribidi-types.h +79 -0
- package/dist/libraries/include/fribidi/fribidi-unicode-version.h +10 -0
- package/dist/libraries/include/fribidi/fribidi-unicode.h +105 -0
- package/dist/libraries/include/fribidi/fribidi.h +129 -0
- package/dist/libraries/include/harfbuzz/hb-aat-layout.h +795 -0
- package/dist/libraries/include/harfbuzz/hb-aat.h +38 -0
- package/dist/libraries/include/harfbuzz/hb-blob.h +160 -0
- package/dist/libraries/include/harfbuzz/hb-buffer.h +799 -0
- package/dist/libraries/include/harfbuzz/hb-common.h +902 -0
- package/dist/libraries/include/harfbuzz/hb-cplusplus.hh +221 -0
- package/dist/libraries/include/harfbuzz/hb-deprecated.h +251 -0
- package/dist/libraries/include/harfbuzz/hb-draw.h +325 -0
- package/dist/libraries/include/harfbuzz/hb-face.h +181 -0
- package/dist/libraries/include/harfbuzz/hb-font.h +1108 -0
- package/dist/libraries/include/harfbuzz/hb-ft.h +145 -0
- package/dist/libraries/include/harfbuzz/hb-map.h +124 -0
- package/dist/libraries/include/harfbuzz/hb-ot-color.h +146 -0
- package/dist/libraries/include/harfbuzz/hb-ot-deprecated.h +141 -0
- package/dist/libraries/include/harfbuzz/hb-ot-font.h +45 -0
- package/dist/libraries/include/harfbuzz/hb-ot-layout.h +503 -0
- package/dist/libraries/include/harfbuzz/hb-ot-math.h +333 -0
- package/dist/libraries/include/harfbuzz/hb-ot-meta.h +72 -0
- package/dist/libraries/include/harfbuzz/hb-ot-metrics.h +129 -0
- package/dist/libraries/include/harfbuzz/hb-ot-name.h +158 -0
- package/dist/libraries/include/harfbuzz/hb-ot-shape.h +53 -0
- package/dist/libraries/include/harfbuzz/hb-ot-var.h +191 -0
- package/dist/libraries/include/harfbuzz/hb-ot.h +49 -0
- package/dist/libraries/include/harfbuzz/hb-set.h +200 -0
- package/dist/libraries/include/harfbuzz/hb-shape-plan.h +122 -0
- package/dist/libraries/include/harfbuzz/hb-shape.h +62 -0
- package/dist/libraries/include/harfbuzz/hb-style.h +81 -0
- package/dist/libraries/include/harfbuzz/hb-subset-repacker.h +81 -0
- package/dist/libraries/include/harfbuzz/hb-subset.h +234 -0
- package/dist/libraries/include/harfbuzz/hb-unicode.h +643 -0
- package/dist/libraries/include/harfbuzz/hb-version.h +95 -0
- package/dist/libraries/include/harfbuzz/hb.h +50 -0
- package/dist/libraries/lib/cmake/expat-2.4.7/expat-config-version.cmake +70 -0
- package/dist/libraries/lib/cmake/expat-2.4.7/expat-config.cmake +99 -0
- package/dist/libraries/lib/cmake/expat-2.4.7/expat-noconfig.cmake +19 -0
- package/dist/libraries/lib/cmake/expat-2.4.7/expat.cmake +99 -0
- package/dist/libraries/lib/libass.a +0 -0
- package/dist/libraries/lib/libass.la +41 -0
- package/dist/libraries/lib/libbrotlicommon.a +0 -0
- package/dist/libraries/lib/libbrotlidec.a +0 -0
- package/dist/libraries/lib/libbrotlienc.a +0 -0
- package/dist/libraries/lib/libexpat.a +0 -0
- package/dist/libraries/lib/libfontconfig.a +0 -0
- package/dist/libraries/lib/libfontconfig.la +41 -0
- package/dist/libraries/lib/libfreetype.a +0 -0
- package/dist/libraries/lib/libfreetype.la +41 -0
- package/dist/libraries/lib/libfribidi.a +0 -0
- package/dist/libraries/lib/libfribidi.la +41 -0
- package/dist/libraries/lib/libharfbuzz-subset.a +0 -0
- package/dist/libraries/lib/libharfbuzz-subset.la +41 -0
- package/dist/libraries/lib/libharfbuzz.a +0 -0
- package/dist/libraries/lib/libharfbuzz.la +41 -0
- package/dist/libraries/lib/pkgconfig/expat.pc +11 -0
- package/dist/libraries/lib/pkgconfig/fontconfig.pc +18 -0
- package/dist/libraries/lib/pkgconfig/freetype2.pc +14 -0
- package/dist/libraries/lib/pkgconfig/fribidi.pc +13 -0
- package/dist/libraries/lib/pkgconfig/harfbuzz-subset.pc +12 -0
- package/dist/libraries/lib/pkgconfig/harfbuzz.pc +13 -0
- package/dist/libraries/lib/pkgconfig/libass.pc +13 -0
- package/dist/libraries/lib/pkgconfig/libbrotlicommon.pc +11 -0
- package/dist/libraries/lib/pkgconfig/libbrotlidec.pc +12 -0
- package/dist/libraries/lib/pkgconfig/libbrotlienc.pc +12 -0
- package/dist/libraries/share/aclocal/freetype2.m4 +194 -0
- package/dist/libraries/share/doc/expat/AUTHORS +10 -0
- package/dist/libraries/share/doc/expat/changelog +1161 -0
- package/index.d.ts +115 -115
- package/package.json +1 -1
|
@@ -0,0 +1,203 @@
|
|
|
1
|
+
/****************************************************************************
|
|
2
|
+
*
|
|
3
|
+
* ftparams.h
|
|
4
|
+
*
|
|
5
|
+
* FreeType API for possible FT_Parameter tags (specification only).
|
|
6
|
+
*
|
|
7
|
+
* Copyright (C) 2017-2021 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 FTPARAMS_H_
|
|
20
|
+
#define FTPARAMS_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
|
+
* parameter_tags
|
|
38
|
+
*
|
|
39
|
+
* @title:
|
|
40
|
+
* Parameter Tags
|
|
41
|
+
*
|
|
42
|
+
* @abstract:
|
|
43
|
+
* Macros for driver property and font loading parameter tags.
|
|
44
|
+
*
|
|
45
|
+
* @description:
|
|
46
|
+
* This section contains macros for the @FT_Parameter structure that are
|
|
47
|
+
* used with various functions to activate some special functionality or
|
|
48
|
+
* different behaviour of various components of FreeType.
|
|
49
|
+
*
|
|
50
|
+
*/
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
/**************************************************************************
|
|
54
|
+
*
|
|
55
|
+
* @enum:
|
|
56
|
+
* FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_FAMILY
|
|
57
|
+
*
|
|
58
|
+
* @description:
|
|
59
|
+
* A tag for @FT_Parameter to make @FT_Open_Face ignore typographic
|
|
60
|
+
* family names in the 'name' table (introduced in OpenType version 1.4).
|
|
61
|
+
* Use this for backward compatibility with legacy systems that have a
|
|
62
|
+
* four-faces-per-family restriction.
|
|
63
|
+
*
|
|
64
|
+
* @since:
|
|
65
|
+
* 2.8
|
|
66
|
+
*
|
|
67
|
+
*/
|
|
68
|
+
#define FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_FAMILY \
|
|
69
|
+
FT_MAKE_TAG( 'i', 'g', 'p', 'f' )
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
/* this constant is deprecated */
|
|
73
|
+
#define FT_PARAM_TAG_IGNORE_PREFERRED_FAMILY \
|
|
74
|
+
FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_FAMILY
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
/**************************************************************************
|
|
78
|
+
*
|
|
79
|
+
* @enum:
|
|
80
|
+
* FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_SUBFAMILY
|
|
81
|
+
*
|
|
82
|
+
* @description:
|
|
83
|
+
* A tag for @FT_Parameter to make @FT_Open_Face ignore typographic
|
|
84
|
+
* subfamily names in the 'name' table (introduced in OpenType version
|
|
85
|
+
* 1.4). Use this for backward compatibility with legacy systems that
|
|
86
|
+
* have a four-faces-per-family restriction.
|
|
87
|
+
*
|
|
88
|
+
* @since:
|
|
89
|
+
* 2.8
|
|
90
|
+
*
|
|
91
|
+
*/
|
|
92
|
+
#define FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_SUBFAMILY \
|
|
93
|
+
FT_MAKE_TAG( 'i', 'g', 'p', 's' )
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
/* this constant is deprecated */
|
|
97
|
+
#define FT_PARAM_TAG_IGNORE_PREFERRED_SUBFAMILY \
|
|
98
|
+
FT_PARAM_TAG_IGNORE_TYPOGRAPHIC_SUBFAMILY
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
/**************************************************************************
|
|
102
|
+
*
|
|
103
|
+
* @enum:
|
|
104
|
+
* FT_PARAM_TAG_INCREMENTAL
|
|
105
|
+
*
|
|
106
|
+
* @description:
|
|
107
|
+
* An @FT_Parameter tag to be used with @FT_Open_Face to indicate
|
|
108
|
+
* incremental glyph loading.
|
|
109
|
+
*
|
|
110
|
+
*/
|
|
111
|
+
#define FT_PARAM_TAG_INCREMENTAL \
|
|
112
|
+
FT_MAKE_TAG( 'i', 'n', 'c', 'r' )
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
/**************************************************************************
|
|
116
|
+
*
|
|
117
|
+
* @enum:
|
|
118
|
+
* FT_PARAM_TAG_LCD_FILTER_WEIGHTS
|
|
119
|
+
*
|
|
120
|
+
* @description:
|
|
121
|
+
* An @FT_Parameter tag to be used with @FT_Face_Properties. The
|
|
122
|
+
* corresponding argument specifies the five LCD filter weights for a
|
|
123
|
+
* given face (if using @FT_LOAD_TARGET_LCD, for example), overriding the
|
|
124
|
+
* global default values or the values set up with
|
|
125
|
+
* @FT_Library_SetLcdFilterWeights.
|
|
126
|
+
*
|
|
127
|
+
* @since:
|
|
128
|
+
* 2.8
|
|
129
|
+
*
|
|
130
|
+
*/
|
|
131
|
+
#define FT_PARAM_TAG_LCD_FILTER_WEIGHTS \
|
|
132
|
+
FT_MAKE_TAG( 'l', 'c', 'd', 'f' )
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
/**************************************************************************
|
|
136
|
+
*
|
|
137
|
+
* @enum:
|
|
138
|
+
* FT_PARAM_TAG_RANDOM_SEED
|
|
139
|
+
*
|
|
140
|
+
* @description:
|
|
141
|
+
* An @FT_Parameter tag to be used with @FT_Face_Properties. The
|
|
142
|
+
* corresponding 32bit signed integer argument overrides the font
|
|
143
|
+
* driver's random seed value with a face-specific one; see @random-seed.
|
|
144
|
+
*
|
|
145
|
+
* @since:
|
|
146
|
+
* 2.8
|
|
147
|
+
*
|
|
148
|
+
*/
|
|
149
|
+
#define FT_PARAM_TAG_RANDOM_SEED \
|
|
150
|
+
FT_MAKE_TAG( 's', 'e', 'e', 'd' )
|
|
151
|
+
|
|
152
|
+
|
|
153
|
+
/**************************************************************************
|
|
154
|
+
*
|
|
155
|
+
* @enum:
|
|
156
|
+
* FT_PARAM_TAG_STEM_DARKENING
|
|
157
|
+
*
|
|
158
|
+
* @description:
|
|
159
|
+
* An @FT_Parameter tag to be used with @FT_Face_Properties. The
|
|
160
|
+
* corresponding Boolean argument specifies whether to apply stem
|
|
161
|
+
* darkening, overriding the global default values or the values set up
|
|
162
|
+
* with @FT_Property_Set (see @no-stem-darkening).
|
|
163
|
+
*
|
|
164
|
+
* This is a passive setting that only takes effect if the font driver or
|
|
165
|
+
* autohinter honors it, which the CFF, Type~1, and CID drivers always
|
|
166
|
+
* do, but the autohinter only in 'light' hinting mode (as of version
|
|
167
|
+
* 2.9).
|
|
168
|
+
*
|
|
169
|
+
* @since:
|
|
170
|
+
* 2.8
|
|
171
|
+
*
|
|
172
|
+
*/
|
|
173
|
+
#define FT_PARAM_TAG_STEM_DARKENING \
|
|
174
|
+
FT_MAKE_TAG( 'd', 'a', 'r', 'k' )
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
/**************************************************************************
|
|
178
|
+
*
|
|
179
|
+
* @enum:
|
|
180
|
+
* FT_PARAM_TAG_UNPATENTED_HINTING
|
|
181
|
+
*
|
|
182
|
+
* @description:
|
|
183
|
+
* Deprecated, no effect.
|
|
184
|
+
*
|
|
185
|
+
* Previously: A constant used as the tag of an @FT_Parameter structure
|
|
186
|
+
* to indicate that unpatented methods only should be used by the
|
|
187
|
+
* TrueType bytecode interpreter for a typeface opened by @FT_Open_Face.
|
|
188
|
+
*
|
|
189
|
+
*/
|
|
190
|
+
#define FT_PARAM_TAG_UNPATENTED_HINTING \
|
|
191
|
+
FT_MAKE_TAG( 'u', 'n', 'p', 'a' )
|
|
192
|
+
|
|
193
|
+
|
|
194
|
+
/* */
|
|
195
|
+
|
|
196
|
+
|
|
197
|
+
FT_END_HEADER
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
#endif /* FTPARAMS_H_ */
|
|
201
|
+
|
|
202
|
+
|
|
203
|
+
/* END */
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
/****************************************************************************
|
|
2
|
+
*
|
|
3
|
+
* ftpfr.h
|
|
4
|
+
*
|
|
5
|
+
* FreeType API for accessing PFR-specific data (specification only).
|
|
6
|
+
*
|
|
7
|
+
* Copyright (C) 2002-2021 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 FTPFR_H_
|
|
20
|
+
#define FTPFR_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
|
+
* pfr_fonts
|
|
38
|
+
*
|
|
39
|
+
* @title:
|
|
40
|
+
* PFR Fonts
|
|
41
|
+
*
|
|
42
|
+
* @abstract:
|
|
43
|
+
* PFR/TrueDoc-specific API.
|
|
44
|
+
*
|
|
45
|
+
* @description:
|
|
46
|
+
* This section contains the declaration of PFR-specific functions.
|
|
47
|
+
*
|
|
48
|
+
*/
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
/**************************************************************************
|
|
52
|
+
*
|
|
53
|
+
* @function:
|
|
54
|
+
* FT_Get_PFR_Metrics
|
|
55
|
+
*
|
|
56
|
+
* @description:
|
|
57
|
+
* Return the outline and metrics resolutions of a given PFR face.
|
|
58
|
+
*
|
|
59
|
+
* @input:
|
|
60
|
+
* face ::
|
|
61
|
+
* Handle to the input face. It can be a non-PFR face.
|
|
62
|
+
*
|
|
63
|
+
* @output:
|
|
64
|
+
* aoutline_resolution ::
|
|
65
|
+
* Outline resolution. This is equivalent to `face->units_per_EM` for
|
|
66
|
+
* non-PFR fonts. Optional (parameter can be `NULL`).
|
|
67
|
+
*
|
|
68
|
+
* ametrics_resolution ::
|
|
69
|
+
* Metrics resolution. This is equivalent to `outline_resolution` for
|
|
70
|
+
* non-PFR fonts. Optional (parameter can be `NULL`).
|
|
71
|
+
*
|
|
72
|
+
* ametrics_x_scale ::
|
|
73
|
+
* A 16.16 fixed-point number used to scale distance expressed in
|
|
74
|
+
* metrics units to device subpixels. This is equivalent to
|
|
75
|
+
* `face->size->x_scale`, but for metrics only. Optional (parameter
|
|
76
|
+
* can be `NULL`).
|
|
77
|
+
*
|
|
78
|
+
* ametrics_y_scale ::
|
|
79
|
+
* Same as `ametrics_x_scale` but for the vertical direction.
|
|
80
|
+
* optional (parameter can be `NULL`).
|
|
81
|
+
*
|
|
82
|
+
* @return:
|
|
83
|
+
* FreeType error code. 0~means success.
|
|
84
|
+
*
|
|
85
|
+
* @note:
|
|
86
|
+
* If the input face is not a PFR, this function will return an error.
|
|
87
|
+
* However, in all cases, it will return valid values.
|
|
88
|
+
*/
|
|
89
|
+
FT_EXPORT( FT_Error )
|
|
90
|
+
FT_Get_PFR_Metrics( FT_Face face,
|
|
91
|
+
FT_UInt *aoutline_resolution,
|
|
92
|
+
FT_UInt *ametrics_resolution,
|
|
93
|
+
FT_Fixed *ametrics_x_scale,
|
|
94
|
+
FT_Fixed *ametrics_y_scale );
|
|
95
|
+
|
|
96
|
+
|
|
97
|
+
/**************************************************************************
|
|
98
|
+
*
|
|
99
|
+
* @function:
|
|
100
|
+
* FT_Get_PFR_Kerning
|
|
101
|
+
*
|
|
102
|
+
* @description:
|
|
103
|
+
* Return the kerning pair corresponding to two glyphs in a PFR face.
|
|
104
|
+
* The distance is expressed in metrics units, unlike the result of
|
|
105
|
+
* @FT_Get_Kerning.
|
|
106
|
+
*
|
|
107
|
+
* @input:
|
|
108
|
+
* face ::
|
|
109
|
+
* A handle to the input face.
|
|
110
|
+
*
|
|
111
|
+
* left ::
|
|
112
|
+
* Index of the left glyph.
|
|
113
|
+
*
|
|
114
|
+
* right ::
|
|
115
|
+
* Index of the right glyph.
|
|
116
|
+
*
|
|
117
|
+
* @output:
|
|
118
|
+
* avector ::
|
|
119
|
+
* A kerning vector.
|
|
120
|
+
*
|
|
121
|
+
* @return:
|
|
122
|
+
* FreeType error code. 0~means success.
|
|
123
|
+
*
|
|
124
|
+
* @note:
|
|
125
|
+
* This function always return distances in original PFR metrics units.
|
|
126
|
+
* This is unlike @FT_Get_Kerning with the @FT_KERNING_UNSCALED mode,
|
|
127
|
+
* which always returns distances converted to outline units.
|
|
128
|
+
*
|
|
129
|
+
* You can use the value of the `x_scale` and `y_scale` parameters
|
|
130
|
+
* returned by @FT_Get_PFR_Metrics to scale these to device subpixels.
|
|
131
|
+
*/
|
|
132
|
+
FT_EXPORT( FT_Error )
|
|
133
|
+
FT_Get_PFR_Kerning( FT_Face face,
|
|
134
|
+
FT_UInt left,
|
|
135
|
+
FT_UInt right,
|
|
136
|
+
FT_Vector *avector );
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
/**************************************************************************
|
|
140
|
+
*
|
|
141
|
+
* @function:
|
|
142
|
+
* FT_Get_PFR_Advance
|
|
143
|
+
*
|
|
144
|
+
* @description:
|
|
145
|
+
* Return a given glyph advance, expressed in original metrics units,
|
|
146
|
+
* from a PFR font.
|
|
147
|
+
*
|
|
148
|
+
* @input:
|
|
149
|
+
* face ::
|
|
150
|
+
* A handle to the input face.
|
|
151
|
+
*
|
|
152
|
+
* gindex ::
|
|
153
|
+
* The glyph index.
|
|
154
|
+
*
|
|
155
|
+
* @output:
|
|
156
|
+
* aadvance ::
|
|
157
|
+
* The glyph advance in metrics units.
|
|
158
|
+
*
|
|
159
|
+
* @return:
|
|
160
|
+
* FreeType error code. 0~means success.
|
|
161
|
+
*
|
|
162
|
+
* @note:
|
|
163
|
+
* You can use the `x_scale` or `y_scale` results of @FT_Get_PFR_Metrics
|
|
164
|
+
* to convert the advance to device subpixels (i.e., 1/64th of pixels).
|
|
165
|
+
*/
|
|
166
|
+
FT_EXPORT( FT_Error )
|
|
167
|
+
FT_Get_PFR_Advance( FT_Face face,
|
|
168
|
+
FT_UInt gindex,
|
|
169
|
+
FT_Pos *aadvance );
|
|
170
|
+
|
|
171
|
+
/* */
|
|
172
|
+
|
|
173
|
+
|
|
174
|
+
FT_END_HEADER
|
|
175
|
+
|
|
176
|
+
#endif /* FTPFR_H_ */
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
/* END */
|
|
@@ -0,0 +1,244 @@
|
|
|
1
|
+
/****************************************************************************
|
|
2
|
+
*
|
|
3
|
+
* ftrender.h
|
|
4
|
+
*
|
|
5
|
+
* FreeType renderer modules public interface (specification).
|
|
6
|
+
*
|
|
7
|
+
* Copyright (C) 1996-2021 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 FTRENDER_H_
|
|
20
|
+
#define FTRENDER_H_
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
#include <freetype/ftmodapi.h>
|
|
24
|
+
#include <freetype/ftglyph.h>
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
FT_BEGIN_HEADER
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
/**************************************************************************
|
|
31
|
+
*
|
|
32
|
+
* @section:
|
|
33
|
+
* module_management
|
|
34
|
+
*
|
|
35
|
+
*/
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
/* create a new glyph object */
|
|
39
|
+
typedef FT_Error
|
|
40
|
+
(*FT_Glyph_InitFunc)( FT_Glyph glyph,
|
|
41
|
+
FT_GlyphSlot slot );
|
|
42
|
+
|
|
43
|
+
/* destroys a given glyph object */
|
|
44
|
+
typedef void
|
|
45
|
+
(*FT_Glyph_DoneFunc)( FT_Glyph glyph );
|
|
46
|
+
|
|
47
|
+
typedef void
|
|
48
|
+
(*FT_Glyph_TransformFunc)( FT_Glyph glyph,
|
|
49
|
+
const FT_Matrix* matrix,
|
|
50
|
+
const FT_Vector* delta );
|
|
51
|
+
|
|
52
|
+
typedef void
|
|
53
|
+
(*FT_Glyph_GetBBoxFunc)( FT_Glyph glyph,
|
|
54
|
+
FT_BBox* abbox );
|
|
55
|
+
|
|
56
|
+
typedef FT_Error
|
|
57
|
+
(*FT_Glyph_CopyFunc)( FT_Glyph source,
|
|
58
|
+
FT_Glyph target );
|
|
59
|
+
|
|
60
|
+
typedef FT_Error
|
|
61
|
+
(*FT_Glyph_PrepareFunc)( FT_Glyph glyph,
|
|
62
|
+
FT_GlyphSlot slot );
|
|
63
|
+
|
|
64
|
+
/* deprecated */
|
|
65
|
+
#define FT_Glyph_Init_Func FT_Glyph_InitFunc
|
|
66
|
+
#define FT_Glyph_Done_Func FT_Glyph_DoneFunc
|
|
67
|
+
#define FT_Glyph_Transform_Func FT_Glyph_TransformFunc
|
|
68
|
+
#define FT_Glyph_BBox_Func FT_Glyph_GetBBoxFunc
|
|
69
|
+
#define FT_Glyph_Copy_Func FT_Glyph_CopyFunc
|
|
70
|
+
#define FT_Glyph_Prepare_Func FT_Glyph_PrepareFunc
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
struct FT_Glyph_Class_
|
|
74
|
+
{
|
|
75
|
+
FT_Long glyph_size;
|
|
76
|
+
FT_Glyph_Format glyph_format;
|
|
77
|
+
|
|
78
|
+
FT_Glyph_InitFunc glyph_init;
|
|
79
|
+
FT_Glyph_DoneFunc glyph_done;
|
|
80
|
+
FT_Glyph_CopyFunc glyph_copy;
|
|
81
|
+
FT_Glyph_TransformFunc glyph_transform;
|
|
82
|
+
FT_Glyph_GetBBoxFunc glyph_bbox;
|
|
83
|
+
FT_Glyph_PrepareFunc glyph_prepare;
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
|
|
87
|
+
typedef FT_Error
|
|
88
|
+
(*FT_Renderer_RenderFunc)( FT_Renderer renderer,
|
|
89
|
+
FT_GlyphSlot slot,
|
|
90
|
+
FT_Render_Mode mode,
|
|
91
|
+
const FT_Vector* origin );
|
|
92
|
+
|
|
93
|
+
typedef FT_Error
|
|
94
|
+
(*FT_Renderer_TransformFunc)( FT_Renderer renderer,
|
|
95
|
+
FT_GlyphSlot slot,
|
|
96
|
+
const FT_Matrix* matrix,
|
|
97
|
+
const FT_Vector* delta );
|
|
98
|
+
|
|
99
|
+
|
|
100
|
+
typedef void
|
|
101
|
+
(*FT_Renderer_GetCBoxFunc)( FT_Renderer renderer,
|
|
102
|
+
FT_GlyphSlot slot,
|
|
103
|
+
FT_BBox* cbox );
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
typedef FT_Error
|
|
107
|
+
(*FT_Renderer_SetModeFunc)( FT_Renderer renderer,
|
|
108
|
+
FT_ULong mode_tag,
|
|
109
|
+
FT_Pointer mode_ptr );
|
|
110
|
+
|
|
111
|
+
/* deprecated identifiers */
|
|
112
|
+
#define FTRenderer_render FT_Renderer_RenderFunc
|
|
113
|
+
#define FTRenderer_transform FT_Renderer_TransformFunc
|
|
114
|
+
#define FTRenderer_getCBox FT_Renderer_GetCBoxFunc
|
|
115
|
+
#define FTRenderer_setMode FT_Renderer_SetModeFunc
|
|
116
|
+
|
|
117
|
+
|
|
118
|
+
/**************************************************************************
|
|
119
|
+
*
|
|
120
|
+
* @struct:
|
|
121
|
+
* FT_Renderer_Class
|
|
122
|
+
*
|
|
123
|
+
* @description:
|
|
124
|
+
* The renderer module class descriptor.
|
|
125
|
+
*
|
|
126
|
+
* @fields:
|
|
127
|
+
* root ::
|
|
128
|
+
* The root @FT_Module_Class fields.
|
|
129
|
+
*
|
|
130
|
+
* glyph_format ::
|
|
131
|
+
* The glyph image format this renderer handles.
|
|
132
|
+
*
|
|
133
|
+
* render_glyph ::
|
|
134
|
+
* A method used to render the image that is in a given glyph slot into
|
|
135
|
+
* a bitmap.
|
|
136
|
+
*
|
|
137
|
+
* transform_glyph ::
|
|
138
|
+
* A method used to transform the image that is in a given glyph slot.
|
|
139
|
+
*
|
|
140
|
+
* get_glyph_cbox ::
|
|
141
|
+
* A method used to access the glyph's cbox.
|
|
142
|
+
*
|
|
143
|
+
* set_mode ::
|
|
144
|
+
* A method used to pass additional parameters.
|
|
145
|
+
*
|
|
146
|
+
* raster_class ::
|
|
147
|
+
* For @FT_GLYPH_FORMAT_OUTLINE renderers only. This is a pointer to
|
|
148
|
+
* its raster's class.
|
|
149
|
+
*/
|
|
150
|
+
typedef struct FT_Renderer_Class_
|
|
151
|
+
{
|
|
152
|
+
FT_Module_Class root;
|
|
153
|
+
|
|
154
|
+
FT_Glyph_Format glyph_format;
|
|
155
|
+
|
|
156
|
+
FT_Renderer_RenderFunc render_glyph;
|
|
157
|
+
FT_Renderer_TransformFunc transform_glyph;
|
|
158
|
+
FT_Renderer_GetCBoxFunc get_glyph_cbox;
|
|
159
|
+
FT_Renderer_SetModeFunc set_mode;
|
|
160
|
+
|
|
161
|
+
FT_Raster_Funcs* raster_class;
|
|
162
|
+
|
|
163
|
+
} FT_Renderer_Class;
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
/**************************************************************************
|
|
167
|
+
*
|
|
168
|
+
* @function:
|
|
169
|
+
* FT_Get_Renderer
|
|
170
|
+
*
|
|
171
|
+
* @description:
|
|
172
|
+
* Retrieve the current renderer for a given glyph format.
|
|
173
|
+
*
|
|
174
|
+
* @input:
|
|
175
|
+
* library ::
|
|
176
|
+
* A handle to the library object.
|
|
177
|
+
*
|
|
178
|
+
* format ::
|
|
179
|
+
* The glyph format.
|
|
180
|
+
*
|
|
181
|
+
* @return:
|
|
182
|
+
* A renderer handle. 0~if none found.
|
|
183
|
+
*
|
|
184
|
+
* @note:
|
|
185
|
+
* An error will be returned if a module already exists by that name, or
|
|
186
|
+
* if the module requires a version of FreeType that is too great.
|
|
187
|
+
*
|
|
188
|
+
* To add a new renderer, simply use @FT_Add_Module. To retrieve a
|
|
189
|
+
* renderer by its name, use @FT_Get_Module.
|
|
190
|
+
*/
|
|
191
|
+
FT_EXPORT( FT_Renderer )
|
|
192
|
+
FT_Get_Renderer( FT_Library library,
|
|
193
|
+
FT_Glyph_Format format );
|
|
194
|
+
|
|
195
|
+
|
|
196
|
+
/**************************************************************************
|
|
197
|
+
*
|
|
198
|
+
* @function:
|
|
199
|
+
* FT_Set_Renderer
|
|
200
|
+
*
|
|
201
|
+
* @description:
|
|
202
|
+
* Set the current renderer to use, and set additional mode.
|
|
203
|
+
*
|
|
204
|
+
* @inout:
|
|
205
|
+
* library ::
|
|
206
|
+
* A handle to the library object.
|
|
207
|
+
*
|
|
208
|
+
* @input:
|
|
209
|
+
* renderer ::
|
|
210
|
+
* A handle to the renderer object.
|
|
211
|
+
*
|
|
212
|
+
* num_params ::
|
|
213
|
+
* The number of additional parameters.
|
|
214
|
+
*
|
|
215
|
+
* parameters ::
|
|
216
|
+
* Additional parameters.
|
|
217
|
+
*
|
|
218
|
+
* @return:
|
|
219
|
+
* FreeType error code. 0~means success.
|
|
220
|
+
*
|
|
221
|
+
* @note:
|
|
222
|
+
* In case of success, the renderer will be used to convert glyph images
|
|
223
|
+
* in the renderer's known format into bitmaps.
|
|
224
|
+
*
|
|
225
|
+
* This doesn't change the current renderer for other formats.
|
|
226
|
+
*
|
|
227
|
+
* Currently, no FreeType renderer module uses `parameters`; you should
|
|
228
|
+
* thus always pass `NULL` as the value.
|
|
229
|
+
*/
|
|
230
|
+
FT_EXPORT( FT_Error )
|
|
231
|
+
FT_Set_Renderer( FT_Library library,
|
|
232
|
+
FT_Renderer renderer,
|
|
233
|
+
FT_UInt num_params,
|
|
234
|
+
FT_Parameter* parameters );
|
|
235
|
+
|
|
236
|
+
/* */
|
|
237
|
+
|
|
238
|
+
|
|
239
|
+
FT_END_HEADER
|
|
240
|
+
|
|
241
|
+
#endif /* FTRENDER_H_ */
|
|
242
|
+
|
|
243
|
+
|
|
244
|
+
/* END */
|