4 * Copyright (C) 2014 by Werner Lemberg.
6 * This file is part of the ttfautohint library, and may only be used,
7 * modified, and distributed under the terms given in `COPYING'. By
8 * continuing to use, modify, or distribute this file you indicate that you
9 * have read `COPYING' and understand and accept it fully.
11 * The file `COPYING' mentioned in the previous paragraph is distributed
12 * with the ttfautohint library.
20 #define DUMPVAL(str, arg) \
25 width, (str), (FT_Long)(arg)); \
29 #define DUMPSTR(str, arg) \
34 width, (str), (arg), eol); \
38 #define DUMPSTRX(arg) \
43 prev_eol, width, "", (arg), eol); \
50 /* if `format' is set, we present the data in a more friendly format */
53 TA_font_dump_parameters(FONT
* font
,
64 const char* eol
= "\n";
65 const char* prev_eol
= "";
74 s
= sdscat(s
, "TTF_autohint parameters\n"
75 "=======================\n"
91 DUMPVAL("adjust-subglyphs",
92 font
->adjust_subglyphs
);
93 DUMPSTR("default-script",
94 script_names
[font
->default_script
]);
95 DUMPVAL("dw-cleartype-strong-stem-width",
96 font
->dw_cleartype_strong_stem_width
);
97 DUMPSTR("fallback-script",
98 script_names
[ta_style_classes
[font
->fallback_style
]->script
]);
99 DUMPVAL("fallback-stem-width",
100 font
->fallback_stem_width
);
101 DUMPVAL("gdi-cleartype-strong-stem-width",
102 font
->gdi_cleartype_strong_stem_width
);
103 DUMPVAL("gray-strong-stem-width",
104 font
->gray_strong_stem_width
);
105 DUMPVAL("hinting-limit",
106 font
->hinting_limit
);
107 DUMPVAL("hinting-range-max",
108 font
->hinting_range_max
);
109 DUMPVAL("hinting-range-min",
110 font
->hinting_range_min
);
111 DUMPVAL("hint-composites",
112 font
->hint_composites
);
113 DUMPVAL("ignore-restrictions",
114 font
->ignore_restrictions
);
115 DUMPVAL("increase-x-height",
116 font
->increase_x_height
);
121 DUMPVAL("windows-compatibility",
122 font
->windows_compatibility
);
124 ns
= number_set_show(font
->x_height_snapping_exceptions
,
125 TA_PROP_INCREASE_X_HEIGHT_MIN
, 0x7FFF);
133 DUMPSTR("x-height-snapping-exceptions", ns
);
135 ds
= TA_deltas_show(font
);
143 /* show delta exceptions data line by line */
156 token
= strtok_r(ds
, "\n", &saveptr
);
157 DUMPSTR("delta exceptions", token
);
161 token
= strtok_r(NULL
, "\n", &saveptr
);
169 DUMPSTR("delta exceptions", "");
190 res
= (char*)malloc(len
);
199 /* end of tadump.c */