1 | /**************************************************************************** |
2 | * |
3 | * afstyles.h |
4 | * |
5 | * Auto-fitter styles (specification only). |
6 | * |
7 | * Copyright (C) 2013-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 | /* The following part can be included multiple times. */ |
20 | /* Define `STYLE' as needed. */ |
21 | |
22 | |
23 | /* Add new styles here. The first and second arguments are the */ |
24 | /* style name in lowercase and uppercase, respectively, followed */ |
25 | /* by a description string. The next arguments are the */ |
26 | /* corresponding writing system, script, blue stringset, and */ |
27 | /* coverage. */ |
28 | /* */ |
29 | /* Note that styles using `AF_COVERAGE_DEFAULT' should always */ |
30 | /* come after styles with other coverages. Also note that */ |
31 | /* fallback scripts only use `AF_COVERAGE_DEFAULT' for its */ |
32 | /* style. */ |
33 | /* */ |
34 | /* Example: */ |
35 | /* */ |
36 | /* STYLE( cyrl_dflt, CYRL_DFLT, */ |
37 | /* "Cyrillic default style", */ |
38 | /* AF_WRITING_SYSTEM_LATIN, */ |
39 | /* AF_SCRIPT_CYRL, */ |
40 | /* AF_BLUE_STRINGSET_CYRL, */ |
41 | /* AF_COVERAGE_DEFAULT ) */ |
42 | |
43 | #undef STYLE_LATIN |
44 | #define STYLE_LATIN( s, S, f, F, ds, df, C ) \ |
45 | STYLE( s ## _ ## f, S ## _ ## F, \ |
46 | ds " " df " style", \ |
47 | AF_WRITING_SYSTEM_LATIN, \ |
48 | AF_SCRIPT_ ## S, \ |
49 | AF_BLUE_STRINGSET_ ## S, \ |
50 | AF_COVERAGE_ ## C ) |
51 | |
52 | #undef META_STYLE_LATIN |
53 | #define META_STYLE_LATIN( s, S, ds ) \ |
54 | STYLE_LATIN( s, S, c2cp, C2CP, ds, \ |
55 | "petite capitals from capitals", \ |
56 | PETITE_CAPITALS_FROM_CAPITALS ) \ |
57 | STYLE_LATIN( s, S, c2sc, C2SC, ds, \ |
58 | "small capitals from capitals", \ |
59 | SMALL_CAPITALS_FROM_CAPITALS ) \ |
60 | STYLE_LATIN( s, S, ordn, ORDN, ds, \ |
61 | "ordinals", \ |
62 | ORDINALS ) \ |
63 | STYLE_LATIN( s, S, pcap, PCAP, ds, \ |
64 | "petite capitals", \ |
65 | PETITE_CAPITALS ) \ |
66 | STYLE_LATIN( s, S, sinf, SINF, ds, \ |
67 | "scientific inferiors", \ |
68 | SCIENTIFIC_INFERIORS ) \ |
69 | STYLE_LATIN( s, S, smcp, SMCP, ds, \ |
70 | "small capitals", \ |
71 | SMALL_CAPITALS ) \ |
72 | STYLE_LATIN( s, S, subs, SUBS, ds, \ |
73 | "subscript", \ |
74 | SUBSCRIPT ) \ |
75 | STYLE_LATIN( s, S, sups, SUPS, ds, \ |
76 | "superscript", \ |
77 | SUPERSCRIPT ) \ |
78 | STYLE_LATIN( s, S, titl, TITL, ds, \ |
79 | "titling", \ |
80 | TITLING ) \ |
81 | STYLE_LATIN( s, S, dflt, DFLT, ds, \ |
82 | "default", \ |
83 | DEFAULT ) |
84 | |
85 | |
86 | STYLE( adlm_dflt, ADLM_DFLT, |
87 | "Adlam default style" , |
88 | AF_WRITING_SYSTEM_LATIN, |
89 | AF_SCRIPT_ADLM, |
90 | AF_BLUE_STRINGSET_ADLM, |
91 | AF_COVERAGE_DEFAULT ) |
92 | |
93 | STYLE( arab_dflt, ARAB_DFLT, |
94 | "Arabic default style" , |
95 | AF_WRITING_SYSTEM_LATIN, |
96 | AF_SCRIPT_ARAB, |
97 | AF_BLUE_STRINGSET_ARAB, |
98 | AF_COVERAGE_DEFAULT ) |
99 | |
100 | STYLE( armn_dflt, ARMN_DFLT, |
101 | "Armenian default style" , |
102 | AF_WRITING_SYSTEM_LATIN, |
103 | AF_SCRIPT_ARMN, |
104 | AF_BLUE_STRINGSET_ARMN, |
105 | AF_COVERAGE_DEFAULT ) |
106 | |
107 | STYLE( avst_dflt, AVST_DFLT, |
108 | "Avestan default style" , |
109 | AF_WRITING_SYSTEM_LATIN, |
110 | AF_SCRIPT_AVST, |
111 | AF_BLUE_STRINGSET_AVST, |
112 | AF_COVERAGE_DEFAULT ) |
113 | |
114 | STYLE( bamu_dflt, BAMU_DFLT, |
115 | "Bamum default style" , |
116 | AF_WRITING_SYSTEM_LATIN, |
117 | AF_SCRIPT_BAMU, |
118 | AF_BLUE_STRINGSET_BAMU, |
119 | AF_COVERAGE_DEFAULT ) |
120 | |
121 | STYLE( beng_dflt, BENG_DFLT, |
122 | "Bengali default style" , |
123 | AF_WRITING_SYSTEM_LATIN, |
124 | AF_SCRIPT_BENG, |
125 | AF_BLUE_STRINGSET_BENG, |
126 | AF_COVERAGE_DEFAULT ) |
127 | |
128 | STYLE( buhd_dflt, BUHD_DFLT, |
129 | "Buhid default style" , |
130 | AF_WRITING_SYSTEM_LATIN, |
131 | AF_SCRIPT_BUHD, |
132 | AF_BLUE_STRINGSET_BUHD, |
133 | AF_COVERAGE_DEFAULT ) |
134 | |
135 | STYLE( cakm_dflt, CAKM_DFLT, |
136 | "Chakma default style" , |
137 | AF_WRITING_SYSTEM_LATIN, |
138 | AF_SCRIPT_CAKM, |
139 | AF_BLUE_STRINGSET_CAKM, |
140 | AF_COVERAGE_DEFAULT ) |
141 | |
142 | STYLE( cans_dflt, CANS_DFLT, |
143 | "Canadian Syllabics default style" , |
144 | AF_WRITING_SYSTEM_LATIN, |
145 | AF_SCRIPT_CANS, |
146 | AF_BLUE_STRINGSET_CANS, |
147 | AF_COVERAGE_DEFAULT ) |
148 | |
149 | STYLE( cari_dflt, CARI_DFLT, |
150 | "Carian default style" , |
151 | AF_WRITING_SYSTEM_LATIN, |
152 | AF_SCRIPT_CARI, |
153 | AF_BLUE_STRINGSET_CARI, |
154 | AF_COVERAGE_DEFAULT ) |
155 | |
156 | STYLE( cher_dflt, CHER_DFLT, |
157 | "Cherokee default style" , |
158 | AF_WRITING_SYSTEM_LATIN, |
159 | AF_SCRIPT_CHER, |
160 | AF_BLUE_STRINGSET_CHER, |
161 | AF_COVERAGE_DEFAULT ) |
162 | |
163 | STYLE( copt_dflt, COPT_DFLT, |
164 | "Coptic default style" , |
165 | AF_WRITING_SYSTEM_LATIN, |
166 | AF_SCRIPT_COPT, |
167 | AF_BLUE_STRINGSET_COPT, |
168 | AF_COVERAGE_DEFAULT ) |
169 | |
170 | STYLE( cprt_dflt, CPRT_DFLT, |
171 | "Cypriot default style" , |
172 | AF_WRITING_SYSTEM_LATIN, |
173 | AF_SCRIPT_CPRT, |
174 | AF_BLUE_STRINGSET_CPRT, |
175 | AF_COVERAGE_DEFAULT ) |
176 | |
177 | META_STYLE_LATIN( cyrl, CYRL, "Cyrillic" ) |
178 | |
179 | STYLE( deva_dflt, DEVA_DFLT, |
180 | "Devanagari default style" , |
181 | AF_WRITING_SYSTEM_LATIN, |
182 | AF_SCRIPT_DEVA, |
183 | AF_BLUE_STRINGSET_DEVA, |
184 | AF_COVERAGE_DEFAULT ) |
185 | |
186 | STYLE( dsrt_dflt, DSRT_DFLT, |
187 | "Deseret default style" , |
188 | AF_WRITING_SYSTEM_LATIN, |
189 | AF_SCRIPT_DSRT, |
190 | AF_BLUE_STRINGSET_DSRT, |
191 | AF_COVERAGE_DEFAULT ) |
192 | |
193 | STYLE( ethi_dflt, ETHI_DFLT, |
194 | "Ethiopic default style" , |
195 | AF_WRITING_SYSTEM_LATIN, |
196 | AF_SCRIPT_ETHI, |
197 | AF_BLUE_STRINGSET_ETHI, |
198 | AF_COVERAGE_DEFAULT ) |
199 | |
200 | STYLE( geor_dflt, GEOR_DFLT, |
201 | "Georgian (Mkhedruli) default style" , |
202 | AF_WRITING_SYSTEM_LATIN, |
203 | AF_SCRIPT_GEOR, |
204 | AF_BLUE_STRINGSET_GEOR, |
205 | AF_COVERAGE_DEFAULT ) |
206 | |
207 | STYLE( geok_dflt, GEOK_DFLT, |
208 | "Georgian (Khutsuri) default style" , |
209 | AF_WRITING_SYSTEM_LATIN, |
210 | AF_SCRIPT_GEOK, |
211 | AF_BLUE_STRINGSET_GEOK, |
212 | AF_COVERAGE_DEFAULT ) |
213 | |
214 | STYLE( glag_dflt, GLAG_DFLT, |
215 | "Glagolitic default style" , |
216 | AF_WRITING_SYSTEM_LATIN, |
217 | AF_SCRIPT_GLAG, |
218 | AF_BLUE_STRINGSET_GLAG, |
219 | AF_COVERAGE_DEFAULT ) |
220 | |
221 | STYLE( goth_dflt, GOTH_DFLT, |
222 | "Gothic default style" , |
223 | AF_WRITING_SYSTEM_LATIN, |
224 | AF_SCRIPT_GOTH, |
225 | AF_BLUE_STRINGSET_GOTH, |
226 | AF_COVERAGE_DEFAULT ) |
227 | |
228 | META_STYLE_LATIN( grek, GREK, "Greek" ) |
229 | |
230 | STYLE( gujr_dflt, GUJR_DFLT, |
231 | "Gujarati default style" , |
232 | AF_WRITING_SYSTEM_LATIN, |
233 | AF_SCRIPT_GUJR, |
234 | AF_BLUE_STRINGSET_GUJR, |
235 | AF_COVERAGE_DEFAULT ) |
236 | |
237 | STYLE( guru_dflt, GURU_DFLT, |
238 | "Gurmukhi default style" , |
239 | AF_WRITING_SYSTEM_LATIN, |
240 | AF_SCRIPT_GURU, |
241 | AF_BLUE_STRINGSET_GURU, |
242 | AF_COVERAGE_DEFAULT ) |
243 | |
244 | STYLE( hebr_dflt, HEBR_DFLT, |
245 | "Hebrew default style" , |
246 | AF_WRITING_SYSTEM_LATIN, |
247 | AF_SCRIPT_HEBR, |
248 | AF_BLUE_STRINGSET_HEBR, |
249 | AF_COVERAGE_DEFAULT ) |
250 | |
251 | STYLE( kali_dflt, KALI_DFLT, |
252 | "Kayah Li default style" , |
253 | AF_WRITING_SYSTEM_LATIN, |
254 | AF_SCRIPT_KALI, |
255 | AF_BLUE_STRINGSET_KALI, |
256 | AF_COVERAGE_DEFAULT ) |
257 | |
258 | STYLE( khmr_dflt, KHMR_DFLT, |
259 | "Khmer default style" , |
260 | AF_WRITING_SYSTEM_LATIN, |
261 | AF_SCRIPT_KHMR, |
262 | AF_BLUE_STRINGSET_KHMR, |
263 | AF_COVERAGE_DEFAULT ) |
264 | |
265 | STYLE( khms_dflt, KHMS_DFLT, |
266 | "Khmer Symbols default style" , |
267 | AF_WRITING_SYSTEM_LATIN, |
268 | AF_SCRIPT_KHMS, |
269 | AF_BLUE_STRINGSET_KHMS, |
270 | AF_COVERAGE_DEFAULT ) |
271 | |
272 | STYLE( knda_dflt, KNDA_DFLT, |
273 | "Kannada default style" , |
274 | AF_WRITING_SYSTEM_LATIN, |
275 | AF_SCRIPT_KNDA, |
276 | AF_BLUE_STRINGSET_KNDA, |
277 | AF_COVERAGE_DEFAULT ) |
278 | |
279 | STYLE( lao_dflt, LAO_DFLT, |
280 | "Lao default style" , |
281 | AF_WRITING_SYSTEM_LATIN, |
282 | AF_SCRIPT_LAO, |
283 | AF_BLUE_STRINGSET_LAO, |
284 | AF_COVERAGE_DEFAULT ) |
285 | |
286 | META_STYLE_LATIN( latn, LATN, "Latin" ) |
287 | |
288 | STYLE( latb_dflt, LATB_DFLT, |
289 | "Latin subscript fallback default style" , |
290 | AF_WRITING_SYSTEM_LATIN, |
291 | AF_SCRIPT_LATB, |
292 | AF_BLUE_STRINGSET_LATB, |
293 | AF_COVERAGE_DEFAULT ) |
294 | |
295 | STYLE( latp_dflt, LATP_DFLT, |
296 | "Latin superscript fallback default style" , |
297 | AF_WRITING_SYSTEM_LATIN, |
298 | AF_SCRIPT_LATP, |
299 | AF_BLUE_STRINGSET_LATP, |
300 | AF_COVERAGE_DEFAULT ) |
301 | |
302 | STYLE( lisu_dflt, LISU_DFLT, |
303 | "Lisu default style" , |
304 | AF_WRITING_SYSTEM_LATIN, |
305 | AF_SCRIPT_LISU, |
306 | AF_BLUE_STRINGSET_LISU, |
307 | AF_COVERAGE_DEFAULT ) |
308 | |
309 | STYLE( mlym_dflt, MLYM_DFLT, |
310 | "Malayalam default style" , |
311 | AF_WRITING_SYSTEM_LATIN, |
312 | AF_SCRIPT_MLYM, |
313 | AF_BLUE_STRINGSET_MLYM, |
314 | AF_COVERAGE_DEFAULT ) |
315 | |
316 | STYLE( medf_dflt, MEDF_DFLT, |
317 | "Medefaidrin default style" , |
318 | AF_WRITING_SYSTEM_LATIN, |
319 | AF_SCRIPT_MEDF, |
320 | AF_BLUE_STRINGSET_MEDF, |
321 | AF_COVERAGE_DEFAULT ) |
322 | |
323 | STYLE( mong_dflt, MONG_DFLT, |
324 | "Mongolian default style" , |
325 | AF_WRITING_SYSTEM_LATIN, |
326 | AF_SCRIPT_MONG, |
327 | AF_BLUE_STRINGSET_MONG, |
328 | AF_COVERAGE_DEFAULT ) |
329 | |
330 | STYLE( mymr_dflt, MYMR_DFLT, |
331 | "Myanmar default style" , |
332 | AF_WRITING_SYSTEM_LATIN, |
333 | AF_SCRIPT_MYMR, |
334 | AF_BLUE_STRINGSET_MYMR, |
335 | AF_COVERAGE_DEFAULT ) |
336 | |
337 | STYLE( nkoo_dflt, NKOO_DFLT, |
338 | "N'Ko default style" , |
339 | AF_WRITING_SYSTEM_LATIN, |
340 | AF_SCRIPT_NKOO, |
341 | AF_BLUE_STRINGSET_NKOO, |
342 | AF_COVERAGE_DEFAULT ) |
343 | |
344 | STYLE( none_dflt, NONE_DFLT, |
345 | "no style" , |
346 | AF_WRITING_SYSTEM_DUMMY, |
347 | AF_SCRIPT_NONE, |
348 | AF_BLUE_STRINGSET_NONE, |
349 | AF_COVERAGE_DEFAULT ) |
350 | |
351 | STYLE( olck_dflt, OLCK_DFLT, |
352 | "Ol Chiki default style" , |
353 | AF_WRITING_SYSTEM_LATIN, |
354 | AF_SCRIPT_OLCK, |
355 | AF_BLUE_STRINGSET_OLCK, |
356 | AF_COVERAGE_DEFAULT ) |
357 | |
358 | STYLE( orkh_dflt, ORKH_DFLT, |
359 | "Old Turkic default style" , |
360 | AF_WRITING_SYSTEM_LATIN, |
361 | AF_SCRIPT_ORKH, |
362 | AF_BLUE_STRINGSET_ORKH, |
363 | AF_COVERAGE_DEFAULT ) |
364 | |
365 | STYLE( osge_dflt, OSGE_DFLT, |
366 | "Osage default style" , |
367 | AF_WRITING_SYSTEM_LATIN, |
368 | AF_SCRIPT_OSGE, |
369 | AF_BLUE_STRINGSET_OSGE, |
370 | AF_COVERAGE_DEFAULT ) |
371 | |
372 | STYLE( osma_dflt, OSMA_DFLT, |
373 | "Osmanya default style" , |
374 | AF_WRITING_SYSTEM_LATIN, |
375 | AF_SCRIPT_OSMA, |
376 | AF_BLUE_STRINGSET_OSMA, |
377 | AF_COVERAGE_DEFAULT ) |
378 | |
379 | STYLE( rohg_dflt, ROHG_DFLT, |
380 | "Hanifi Rohingya default style" , |
381 | AF_WRITING_SYSTEM_LATIN, |
382 | AF_SCRIPT_ROHG, |
383 | AF_BLUE_STRINGSET_ROHG, |
384 | AF_COVERAGE_DEFAULT ) |
385 | |
386 | STYLE( saur_dflt, SAUR_DFLT, |
387 | "Saurashtra default style" , |
388 | AF_WRITING_SYSTEM_LATIN, |
389 | AF_SCRIPT_SAUR, |
390 | AF_BLUE_STRINGSET_SAUR, |
391 | AF_COVERAGE_DEFAULT ) |
392 | |
393 | STYLE( shaw_dflt, SHAW_DFLT, |
394 | "Shavian default style" , |
395 | AF_WRITING_SYSTEM_LATIN, |
396 | AF_SCRIPT_SHAW, |
397 | AF_BLUE_STRINGSET_SHAW, |
398 | AF_COVERAGE_DEFAULT ) |
399 | |
400 | STYLE( sinh_dflt, SINH_DFLT, |
401 | "Sinhala default style" , |
402 | AF_WRITING_SYSTEM_LATIN, |
403 | AF_SCRIPT_SINH, |
404 | AF_BLUE_STRINGSET_SINH, |
405 | AF_COVERAGE_DEFAULT ) |
406 | |
407 | STYLE( sund_dflt, SUND_DFLT, |
408 | "Sundanese default style" , |
409 | AF_WRITING_SYSTEM_LATIN, |
410 | AF_SCRIPT_SUND, |
411 | AF_BLUE_STRINGSET_SUND, |
412 | AF_COVERAGE_DEFAULT ) |
413 | |
414 | STYLE( taml_dflt, TAML_DFLT, |
415 | "Tamil default style" , |
416 | AF_WRITING_SYSTEM_LATIN, |
417 | AF_SCRIPT_TAML, |
418 | AF_BLUE_STRINGSET_TAML, |
419 | AF_COVERAGE_DEFAULT ) |
420 | |
421 | STYLE( tavt_dflt, TAVT_DFLT, |
422 | "Tai Viet default style" , |
423 | AF_WRITING_SYSTEM_LATIN, |
424 | AF_SCRIPT_TAVT, |
425 | AF_BLUE_STRINGSET_TAVT, |
426 | AF_COVERAGE_DEFAULT ) |
427 | |
428 | STYLE( telu_dflt, TELU_DFLT, |
429 | "Telugu default style" , |
430 | AF_WRITING_SYSTEM_LATIN, |
431 | AF_SCRIPT_TELU, |
432 | AF_BLUE_STRINGSET_TELU, |
433 | AF_COVERAGE_DEFAULT ) |
434 | |
435 | STYLE( tfng_dflt, TFNG_DFLT, |
436 | "Tifinagh default style" , |
437 | AF_WRITING_SYSTEM_LATIN, |
438 | AF_SCRIPT_TFNG, |
439 | AF_BLUE_STRINGSET_TFNG, |
440 | AF_COVERAGE_DEFAULT ) |
441 | |
442 | STYLE( thai_dflt, THAI_DFLT, |
443 | "Thai default style" , |
444 | AF_WRITING_SYSTEM_LATIN, |
445 | AF_SCRIPT_THAI, |
446 | AF_BLUE_STRINGSET_THAI, |
447 | AF_COVERAGE_DEFAULT ) |
448 | |
449 | STYLE( vaii_dflt, VAII_DFLT, |
450 | "Vai default style" , |
451 | AF_WRITING_SYSTEM_LATIN, |
452 | AF_SCRIPT_VAII, |
453 | AF_BLUE_STRINGSET_VAII, |
454 | AF_COVERAGE_DEFAULT ) |
455 | |
456 | #ifdef AF_CONFIG_OPTION_INDIC |
457 | |
458 | /* no blue stringset support for the Indic writing system yet */ |
459 | #undef STYLE_DEFAULT_INDIC |
460 | #define STYLE_DEFAULT_INDIC( s, S, d ) \ |
461 | STYLE( s ## _dflt, S ## _DFLT, \ |
462 | d " default style", \ |
463 | AF_WRITING_SYSTEM_INDIC, \ |
464 | AF_SCRIPT_ ## S, \ |
465 | (AF_Blue_Stringset)0, \ |
466 | AF_COVERAGE_DEFAULT ) |
467 | |
468 | STYLE_DEFAULT_INDIC( limb, LIMB, "Limbu" ) |
469 | STYLE_DEFAULT_INDIC( orya, ORYA, "Oriya" ) |
470 | STYLE_DEFAULT_INDIC( sylo, SYLO, "Syloti Nagri" ) |
471 | STYLE_DEFAULT_INDIC( tibt, TIBT, "Tibetan" ) |
472 | |
473 | #endif /* AF_CONFIG_OPTION_INDIC */ |
474 | |
475 | #ifdef AF_CONFIG_OPTION_CJK |
476 | |
477 | STYLE( hani_dflt, HANI_DFLT, |
478 | "CJKV ideographs default style" , |
479 | AF_WRITING_SYSTEM_CJK, |
480 | AF_SCRIPT_HANI, |
481 | AF_BLUE_STRINGSET_HANI, |
482 | AF_COVERAGE_DEFAULT ) |
483 | |
484 | #endif /* AF_CONFIG_OPTION_CJK */ |
485 | |
486 | |
487 | /* END */ |
488 | |