[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
/***************************************************************************/
|
|
|
|
/* */
|
|
|
|
/* afstyles.h */
|
|
|
|
/* */
|
|
|
|
/* Auto-fitter styles (specification only). */
|
|
|
|
/* */
|
2017-01-04 20:16:34 +01:00
|
|
|
/* Copyright 2013-2017 by */
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
|
|
|
|
/* */
|
|
|
|
/* This file is part of the FreeType project, and may only be used, */
|
|
|
|
/* modified, and distributed under the terms of the FreeType project */
|
|
|
|
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
|
|
|
|
/* this file you indicate that you have read the license and */
|
|
|
|
/* understand and accept it fully. */
|
|
|
|
/* */
|
|
|
|
/***************************************************************************/
|
|
|
|
|
|
|
|
|
|
|
|
/* The following part can be included multiple times. */
|
|
|
|
/* Define `STYLE' as needed. */
|
|
|
|
|
|
|
|
|
2013-12-21 21:31:38 +01:00
|
|
|
/* Add new styles here. The first and second arguments are the */
|
|
|
|
/* style name in lowercase and uppercase, respectively, followed */
|
|
|
|
/* by a description string. The next arguments are the */
|
|
|
|
/* corresponding writing system, script, blue stringset, and */
|
|
|
|
/* coverage. */
|
2014-01-01 16:34:42 +01:00
|
|
|
/* */
|
|
|
|
/* Note that styles using `AF_COVERAGE_DEFAULT' should always */
|
2015-09-04 10:28:53 +02:00
|
|
|
/* come after styles with other coverages. Also note that */
|
|
|
|
/* fallback scripts only use `AF_COVERAGE_DEFAULT' for its */
|
|
|
|
/* style. */
|
2014-01-01 16:34:42 +01:00
|
|
|
/* */
|
|
|
|
/* Example: */
|
|
|
|
/* */
|
|
|
|
/* STYLE( cyrl_dflt, CYRL_DFLT, */
|
|
|
|
/* "Cyrillic default style", */
|
|
|
|
/* AF_WRITING_SYSTEM_LATIN, */
|
|
|
|
/* AF_SCRIPT_CYRL, */
|
|
|
|
/* AF_BLUE_STRINGSET_CYRL, */
|
|
|
|
/* AF_COVERAGE_DEFAULT ) */
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
|
2014-01-01 16:34:42 +01:00
|
|
|
#undef STYLE_LATIN
|
|
|
|
#define STYLE_LATIN( s, S, f, F, ds, df, C ) \
|
|
|
|
STYLE( s ## _ ## f, S ## _ ## F, \
|
|
|
|
ds " " df " style", \
|
|
|
|
AF_WRITING_SYSTEM_LATIN, \
|
|
|
|
AF_SCRIPT_ ## S, \
|
|
|
|
AF_BLUE_STRINGSET_ ## S, \
|
|
|
|
AF_COVERAGE_ ## C )
|
|
|
|
|
|
|
|
#undef META_STYLE_LATIN
|
|
|
|
#define META_STYLE_LATIN( s, S, ds ) \
|
|
|
|
STYLE_LATIN( s, S, c2cp, C2CP, ds, \
|
2016-04-09 05:21:34 +02:00
|
|
|
"petite capitals from capitals", \
|
2014-01-01 16:34:42 +01:00
|
|
|
PETITE_CAPITALS_FROM_CAPITALS ) \
|
|
|
|
STYLE_LATIN( s, S, c2sc, C2SC, ds, \
|
2016-04-09 05:21:34 +02:00
|
|
|
"small capitals from capitals", \
|
2014-01-01 16:34:42 +01:00
|
|
|
SMALL_CAPITALS_FROM_CAPITALS ) \
|
|
|
|
STYLE_LATIN( s, S, ordn, ORDN, ds, \
|
|
|
|
"ordinals", \
|
|
|
|
ORDINALS ) \
|
|
|
|
STYLE_LATIN( s, S, pcap, PCAP, ds, \
|
|
|
|
"petite capitals", \
|
|
|
|
PETITE_CAPITALS ) \
|
|
|
|
STYLE_LATIN( s, S, sinf, SINF, ds, \
|
|
|
|
"scientific inferiors", \
|
|
|
|
SCIENTIFIC_INFERIORS ) \
|
|
|
|
STYLE_LATIN( s, S, smcp, SMCP, ds, \
|
|
|
|
"small capitals", \
|
|
|
|
SMALL_CAPITALS ) \
|
|
|
|
STYLE_LATIN( s, S, subs, SUBS, ds, \
|
|
|
|
"subscript", \
|
|
|
|
SUBSCRIPT ) \
|
|
|
|
STYLE_LATIN( s, S, sups, SUPS, ds, \
|
|
|
|
"superscript", \
|
|
|
|
SUPERSCRIPT ) \
|
|
|
|
STYLE_LATIN( s, S, titl, TITL, ds, \
|
|
|
|
"titling", \
|
|
|
|
TITLING ) \
|
|
|
|
STYLE_LATIN( s, S, dflt, DFLT, ds, \
|
|
|
|
"default", \
|
|
|
|
DEFAULT )
|
|
|
|
|
2015-03-11 16:45:58 +01:00
|
|
|
|
2017-04-06 05:50:44 +02:00
|
|
|
STYLE( adlm_dflt, ADLM_DFLT,
|
|
|
|
"Adlam default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_ADLM,
|
|
|
|
AF_BLUE_STRINGSET_ADLM,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2015-03-11 16:45:58 +01:00
|
|
|
STYLE( arab_dflt, ARAB_DFLT,
|
|
|
|
"Arabic default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_ARAB,
|
|
|
|
AF_BLUE_STRINGSET_ARAB,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2016-05-24 18:27:18 +02:00
|
|
|
STYLE( armn_dflt, ARMN_DFLT,
|
|
|
|
"Armenian default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_ARMN,
|
|
|
|
AF_BLUE_STRINGSET_ARMN,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2015-12-15 17:53:46 +01:00
|
|
|
STYLE( beng_dflt, BENG_DFLT,
|
|
|
|
"Bengali default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_BENG,
|
|
|
|
AF_BLUE_STRINGSET_BENG,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2016-06-13 12:16:45 +02:00
|
|
|
STYLE( cher_dflt, CHER_DFLT,
|
|
|
|
"Cherokee default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_CHER,
|
|
|
|
AF_BLUE_STRINGSET_CHER,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2014-01-01 16:34:42 +01:00
|
|
|
META_STYLE_LATIN( cyrl, CYRL, "Cyrillic" )
|
2014-05-01 17:24:19 +02:00
|
|
|
|
2015-09-04 10:28:53 +02:00
|
|
|
STYLE( deva_dflt, DEVA_DFLT,
|
|
|
|
"Devanagari default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_DEVA,
|
|
|
|
AF_BLUE_STRINGSET_DEVA,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2016-06-07 13:52:14 +02:00
|
|
|
STYLE( ethi_dflt, ETHI_DFLT,
|
|
|
|
"Ethiopic default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_ETHI,
|
|
|
|
AF_BLUE_STRINGSET_ETHI,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
[autofit] Add support for Georgian scripts.
Georgian is problematic, since `uppercase' forms of Mkhedruli
(called Mtavruli) are not yet defined in Unicode, which means that
proper blue zones can't be defined. However, there is already a
proposal submitted to Unicode; see
http://www.unicode.org/L2/L2016/16034-n4707-georgian.pdf
Additionally, due to historical reasons, Unicode treats Khutsuri as
the same script as Mkhedruli, and so does OpenType. However, since
the two scripts have completely different shapes it can happen that
blue zones differ considerably. The tag `geok' used here (derived
from ISO 15924) to differentiate the two scripts is not an OpenType
tag in use. If we now have a font that contains both glyphs for
Mkhedruli and Khutsuri, and it uses OpenType features for both also,
HarfBuzz unavoidably treats all glyphs as `geor'. As a consequence,
blue zones for `geok' are not used for glyphs involved in the
OpenType features.
An issue not yet resolved is which OpenType feature should be used
to access Mtavruli glyph shapes; right now, FreeType doesn't set up
support for them, but it is easy to add them later on as soon as
more information is available.
* src/autofit/afblue.dat: Add blue zone data for Georgian.
* src/autofit/afblue.c, src/autofit/afblue.h: Regenerated.
* src/autofit/afscript.h: Add Georgian standard characters.
* src/autofit/afranges.c: Add Georgian data.
* src/autofit/afstyles.h: Add Georgian data.
2016-04-09 08:24:00 +02:00
|
|
|
STYLE( geor_dflt, GEOR_DFLT,
|
|
|
|
"Georgian (Mkhedruli) default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_GEOR,
|
|
|
|
AF_BLUE_STRINGSET_GEOR,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
|
|
|
STYLE( geok_dflt, GEOK_DFLT,
|
|
|
|
"Georgian (Khutsuri) default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_GEOK,
|
|
|
|
AF_BLUE_STRINGSET_GEOK,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2014-01-01 16:34:42 +01:00
|
|
|
META_STYLE_LATIN( grek, GREK, "Greek" )
|
2014-05-01 17:24:19 +02:00
|
|
|
|
2016-04-25 21:18:24 +02:00
|
|
|
STYLE( gujr_dflt, GUJR_DFLT,
|
|
|
|
"Gujarati default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_GUJR,
|
|
|
|
AF_BLUE_STRINGSET_GUJR,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2016-05-22 08:38:41 +02:00
|
|
|
STYLE( guru_dflt, GURU_DFLT,
|
|
|
|
"Gurmukhi default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_GURU,
|
|
|
|
AF_BLUE_STRINGSET_GURU,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2013-12-31 09:45:10 +01:00
|
|
|
STYLE( hebr_dflt, HEBR_DFLT,
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
"Hebrew default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_HEBR,
|
2013-12-21 21:31:38 +01:00
|
|
|
AF_BLUE_STRINGSET_HEBR,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
2015-09-04 10:28:53 +02:00
|
|
|
|
2016-01-28 10:13:24 +01:00
|
|
|
STYLE( knda_dflt, KNDA_DFLT,
|
2016-01-30 11:16:04 +01:00
|
|
|
"Kannada default style",
|
2016-01-28 10:13:24 +01:00
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_KNDA,
|
|
|
|
AF_BLUE_STRINGSET_KNDA,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2015-12-06 19:34:59 +01:00
|
|
|
STYLE( khmr_dflt, KHMR_DFLT,
|
|
|
|
"Khmer default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_KHMR,
|
|
|
|
AF_BLUE_STRINGSET_KHMR,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
|
|
|
STYLE( khms_dflt, KHMS_DFLT,
|
|
|
|
"Khmer Symbols default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_KHMS,
|
|
|
|
AF_BLUE_STRINGSET_KHMS,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2015-09-28 09:45:56 +02:00
|
|
|
STYLE( lao_dflt, LAO_DFLT,
|
|
|
|
"Lao default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_LAO,
|
|
|
|
AF_BLUE_STRINGSET_LAO,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2014-01-01 16:34:42 +01:00
|
|
|
META_STYLE_LATIN( latn, LATN, "Latin" )
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
|
2015-09-04 10:28:53 +02:00
|
|
|
STYLE( latb_dflt, LATB_DFLT,
|
|
|
|
"Latin subscript fallback default style",
|
2014-05-01 17:24:19 +02:00
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
2015-09-04 10:28:53 +02:00
|
|
|
AF_SCRIPT_LATB,
|
|
|
|
AF_BLUE_STRINGSET_LATB,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
|
|
|
STYLE( latp_dflt, LATP_DFLT,
|
|
|
|
"Latin superscript fallback default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_LATP,
|
|
|
|
AF_BLUE_STRINGSET_LATP,
|
2014-05-01 17:24:19 +02:00
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
#ifdef FT_OPTION_AUTOFIT2
|
2013-12-31 09:45:10 +01:00
|
|
|
STYLE( ltn2_dflt, LTN2_DFLT,
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
"Latin 2 default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN2,
|
|
|
|
AF_SCRIPT_LATN,
|
2013-12-21 21:31:38 +01:00
|
|
|
AF_BLUE_STRINGSET_LATN,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
#endif
|
|
|
|
|
2016-02-18 12:56:38 +01:00
|
|
|
STYLE( mlym_dflt, MLYM_DFLT,
|
|
|
|
"Malayalam default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_MLYM,
|
|
|
|
AF_BLUE_STRINGSET_MLYM,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2015-12-13 15:54:17 +01:00
|
|
|
STYLE( mymr_dflt, MYMR_DFLT,
|
|
|
|
"Myanmar default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_MYMR,
|
|
|
|
AF_BLUE_STRINGSET_MYMR,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2017-04-06 07:06:32 +02:00
|
|
|
STYLE( nkoo_dflt, NKOO_DFLT,
|
|
|
|
"N'Ko default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_NKOO,
|
|
|
|
AF_BLUE_STRINGSET_NKOO,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2013-12-31 09:45:10 +01:00
|
|
|
STYLE( none_dflt, NONE_DFLT,
|
2013-12-21 21:31:38 +01:00
|
|
|
"no style",
|
|
|
|
AF_WRITING_SYSTEM_DUMMY,
|
|
|
|
AF_SCRIPT_NONE,
|
2016-04-05 11:43:58 +02:00
|
|
|
AF_BLUE_STRINGSET_NONE,
|
2013-12-21 21:31:38 +01:00
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2017-04-06 05:39:51 +02:00
|
|
|
STYLE( olck_dflt, OLCK_DFLT,
|
|
|
|
"Ol Chiki default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_OLCK,
|
|
|
|
AF_BLUE_STRINGSET_OLCK,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2016-02-29 09:12:35 +01:00
|
|
|
STYLE( sinh_dflt, SINH_DFLT,
|
|
|
|
"Sinhala default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_SINH,
|
|
|
|
AF_BLUE_STRINGSET_SINH,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2016-02-25 06:58:47 +01:00
|
|
|
STYLE( taml_dflt, TAML_DFLT,
|
|
|
|
"Tamil default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_TAML,
|
|
|
|
AF_BLUE_STRINGSET_TAML,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2014-10-18 11:01:14 +02:00
|
|
|
STYLE( telu_dflt, TELU_DFLT,
|
|
|
|
"Telugu default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_TELU,
|
|
|
|
AF_BLUE_STRINGSET_TELU,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2015-01-31 11:01:33 +01:00
|
|
|
STYLE( thai_dflt, THAI_DFLT,
|
|
|
|
"Thai default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_THAI,
|
|
|
|
AF_BLUE_STRINGSET_THAI,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
2017-04-06 08:44:08 +02:00
|
|
|
STYLE( tfng_dflt, TFNG_DFLT,
|
|
|
|
"Tifinagh default style",
|
|
|
|
AF_WRITING_SYSTEM_LATIN,
|
|
|
|
AF_SCRIPT_TFNG,
|
|
|
|
AF_BLUE_STRINGSET_TFNG,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
[autofit] Fix Indic scripts.
Split the single, incorrect Indic entry into separate scripts so
that the covered ranges are the same: Bengali, Devanagari, Gujarati,
Gurmukhi, Kannada, Limbu, Malayalam, Oriya, Sinhala, Sundanese,
Syloti Nagri, Tamil, Telugu, and Tibetan. At the same time, remove
entries for Meetai Mayak and Sharada – the Unicode ranges were
incorrect (and nobody has complained about that), fonts are scarce
for those scripts, and the Indic auto-hinter support is rudimentary
anyways.
* src/autofit/afscript.h: Updated, using AF_CONFIG_OPTION_INDIC and
AF_CONFIG_OPTION_CJK.
* src/autofit/afstyles.h (STYLE_DEFAULT_INDIC): New auxiliary macro.
Use it, together with AF_CONFIG_OPTION_INDIC and
AF_CONFIG_OPTION_CJK, to update.
* src/autofit/afranges.c [AF_CONFIG_OPTION_INDIC]: Updated.
[!AF_CONFIG_OPTION_INDIC, !AF_CONFIG_OPTION_CJK]: Removed.
Sort entries by tags.
2014-01-04 11:46:34 +01:00
|
|
|
#ifdef AF_CONFIG_OPTION_INDIC
|
|
|
|
|
|
|
|
/* no blue stringset support for the Indic writing system yet */
|
|
|
|
#undef STYLE_DEFAULT_INDIC
|
|
|
|
#define STYLE_DEFAULT_INDIC( s, S, d ) \
|
|
|
|
STYLE( s ## _dflt, S ## _DFLT, \
|
|
|
|
d " default style", \
|
|
|
|
AF_WRITING_SYSTEM_INDIC, \
|
|
|
|
AF_SCRIPT_ ## S, \
|
|
|
|
(AF_Blue_Stringset)0, \
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
|
|
|
STYLE_DEFAULT_INDIC( limb, LIMB, "Limbu" )
|
|
|
|
STYLE_DEFAULT_INDIC( orya, ORYA, "Oriya" )
|
|
|
|
STYLE_DEFAULT_INDIC( sund, SUND, "Sundanese" )
|
|
|
|
STYLE_DEFAULT_INDIC( sylo, SYLO, "Syloti Nagri" )
|
|
|
|
STYLE_DEFAULT_INDIC( tibt, TIBT, "Tibetan" )
|
|
|
|
|
|
|
|
#endif /* AF_CONFIG_OPTION_INDIC */
|
|
|
|
|
|
|
|
#ifdef AF_CONFIG_OPTION_CJK
|
|
|
|
|
|
|
|
STYLE( hani_dflt, HANI_DFLT,
|
|
|
|
"CJKV ideographs default style",
|
|
|
|
AF_WRITING_SYSTEM_CJK,
|
|
|
|
AF_SCRIPT_HANI,
|
|
|
|
AF_BLUE_STRINGSET_HANI,
|
|
|
|
AF_COVERAGE_DEFAULT )
|
|
|
|
|
|
|
|
#endif /* AF_CONFIG_OPTION_CJK */
|
|
|
|
|
[autofit] Introduce `styles'.
This is the new top-level structure for handling glyph input data;
scripts are now defined separately.
* src/autofit/aftypes.h (SCRIPT): Updated.
(AF_ScriptClassRec): Move `blue_stringset' and `writing_system'
members to ...
(AF_Style_ClassRec): ... this new structure.
(AF_Style): New enumeration.
(AF_StyleMetricsRec): Replace `script' enumeration with
`style_class' pointer.
(AF_DEFINE_SCRIPT_CLASS, AF_DECLARE_SCRIPT_CLASS): Updated.
(AF_DEFINE_STYLE_CLASS, AF_DECLARE_STYLE_CLASS): New macros.
* src/autofit/afstyles.h: New file, using data from `afscript.h'.
* src/autofit/afscript.h: Updated.
* src/autofit/afcjk.c (af_cjk_metrics_init_widths,
af_cjk_metrics_init_blues, af_cjk_hint_edges): Updated.
* src/autofit/afglobal.c (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(af_script_names) [FT_DEBUG_LEVEL_TRACE]: Replace with...
(af_style_names): ... this array.
(af_face_globals_compute_script_coverage): Renamed to...
(af_face_globals_compute_style_coverage): ... this.
Updated.
(af_face_globals_new, af_face_globals_free,
af_face_globals_get_metrics): Updated.
* src/autofit/afglobal.h (SCRIPT): Updated.
(STYLE): Redefine macro to load `afstyles.h'.
(AF_SCRIPT_FALLBACK): Update definition. This will get more
refinements with later on.
(AF_SCRIPT_UNASSIGNED): Replace with...
(AF_STYLE_UNASSIGNED): ... this macro.
(AF_FaceGlobalsRec): Updated.
* src/autofit/aflatin.c (af_latin_metrics_init_widths,
af_latin_metrics_init_blues, af_latin_metrics_scale_dim,
af_latin_hint_edges): Updated.
* src/autofit/aflatin2.c (af_latin2_metrics_init_widths): Updated.
(af_ltn2_uniranges): Removed.
* src/autofit/afloader.c (af_loader_load_g, af_loader_load_glyph):
Updated.
* src/autofit/afpic.c (autofit_module_class_pic_init): Updated.
* src/autofit/afpic.h (AF_STYLE_CLASSES_GET): New macro.
(AFModulePIC): Add `af_style_classes' and `af_style_classes_rec'
members.
* src/autofit/afranges.h: Updated.
* src/autofit/rules.mk (AUTOF_DRV_H): Add `afstyles.h'.
2013-12-20 17:26:26 +01:00
|
|
|
|
|
|
|
/* END */
|