Commit Graph

33 Commits

Author SHA1 Message Date
Behdad Esfahbod faac252f9f [util/hb-ot-shape-closure] Fix showing glyph names 2022-07-18 12:23:57 -06:00
Behdad Esfahbod c0b2f50c0b [util] Rename template typenames to avoid clashing with actual types
Apparently MSVC2015 can confuse them

Fixes https://github.com/harfbuzz/harfbuzz/issues/3379
2022-02-18 12:29:14 -06:00
Behdad Esfahbod c45d2a9c9d [util] Allow setting cli summary / description 2021-08-12 11:19:59 -06:00
Behdad Esfahbod 4d73b3d9b1 [util] Add --batch to hb-view / hb-ot-shape-closure 2021-08-12 10:39:46 -06:00
Behdad Esfahbod 9a6055caa8 [util/hb-ot-shape-closure] Remove unnecessary include 2021-08-11 20:30:25 -06:00
Behdad Esfahbod 97a9e4e41e [util] Separate shape_text_options_t from text_options_t 2021-08-11 19:28:16 -06:00
Behdad Esfahbod 24a9d8c78d [util] Use post_parse in font_options_t 2021-08-11 18:49:59 -06:00
Behdad Esfahbod 9468e46998 [util] Rename main_font_text back to main_font_text_t 2021-08-11 16:46:04 -06:00
Behdad Esfahbod 9d8bbe3e53 [util] Make main_font_text a struct again
Going to move to G_OPTION_REMAINING.
2021-08-11 11:53:32 -06:00
Behdad Esfahbod 7d2e9164ab [util] Move text options into text_options_t
Remove now empty options.cc.
2021-08-07 13:38:19 -06:00
Behdad Esfahbod 5545eea7e5 [util] Remove main_font_text_t class, use bare function 2021-08-07 11:04:46 -06:00
Behdad Esfahbod 58c223357b [util] Move face/font options into face/font-options.hh 2021-08-06 23:47:48 -06:00
Behdad Esfahbod c3599fded7 [util] Move shape options into shape-options.hh 2021-08-06 23:24:28 -06:00
Behdad Esfahbod 71440dbd90 [util] Move font-size and upem to be extern variables 2021-08-06 19:17:12 -06:00
Behdad Esfahbod fc0339eef0 [util] Simplify shape-consumer by removing buffer arg 2021-08-06 19:17:12 -06:00
Behdad Esfahbod 463411a1de [util] Remove unused option_group_t 2021-08-06 19:17:12 -06:00
Behdad Esfahbod 09e4d7dd30 [util] Simplify output_options_t 2021-08-06 19:17:12 -06:00
Behdad Esfahbod e109f9a6f9 [util] Collect cmdline arg options outside of constructor 2021-08-06 19:17:12 -06:00
Behdad Esfahbod e57dd66889 [util] Initialize struct members inline 2021-08-06 19:17:12 -06:00
Bruce Mitchener 659eeddb2d Use C++11 override keyword. 2019-06-04 20:31:32 -07:00
Behdad Esfahbod dbdbfe3d7b Use nullptr instead of NULL 2017-10-15 12:11:08 +02:00
Behdad Esfahbod e60350551a [hb-shape] Improve shaping-debug output
Before, that was printed using --debug (and in both hb-shape and hb-view).
Changed it, now hb-shape has a new command-line argument called --show-messages.
When invoked, it also respects other output formatting options.  The messages
are better formatted and printed to te same place that hb-shape output is
directed to.  Previously they were written to stderr.

Fixes https://github.com/behdad/harfbuzz/issues/506
2017-07-18 19:16:09 -07:00
Behdad Esfahbod cd4eb96abb [util] Add --font-size to hb-shape
Also makes hb-view to use 8 bits of subpixel precision and shape at
requested size, instead of always shaping at upem and scaling results.
2015-01-20 12:45:13 -08:00
Behdad Esfahbod 5fbc952524 Fix glyph name printing in hb-ot-shape-closure 2013-07-29 14:34:40 -04:00
Behdad Esfahbod 7235f33f9e Fix misc warnings reported by cppcheck
https://bugs.freedesktop.org/show_bug.cgi?id=65544
2013-06-10 15:08:49 -04:00
Behdad Esfahbod 75da37dcb1 Minor 2012-11-15 18:39:23 -08:00
Behdad Esfahbod aec89de564 Add / modify set API a bit 2012-11-15 16:15:42 -08:00
Behdad Esfahbod 321f73c16e [util] Add --text-before and --text-after to hb-shape / hb-view
Use with Arabic, for example, to see the effect on joining.
2012-11-13 15:12:24 -08:00
Behdad Esfahbod 5db0683a82 [util] Make hb-shape continue shaping other lines if shapers failed 2012-06-02 12:13:08 -04:00
Behdad Esfahbod cd6a549341 Remove unused variable 2012-06-01 13:45:25 -04:00
Behdad Esfahbod bce095524b Add hb_font_get_glyph_name() and hb_font_get_glyph_from_name() 2012-05-28 10:45:50 -04:00
Behdad Esfahbod 29ce446d31 Add set iterator 2012-05-25 14:17:54 -04:00
Behdad Esfahbod c87b317f0e [util] Add hb-ot-shape-closure tool
Computes all the glyphs that may be generated given a font and
set of Unicode characters.

The order of the Unicode characters is irrelevant.

Sample output:

behdad:util 0$ ./hb-ot-shape-closure Doulos\ SIL\ Regular.ttf f
f f_f

behdad:util 0$ ./hb-ot-shape-closure Doulos\ SIL\ Regular.ttf i
i

behdad:util 0$ ./hb-ot-shape-closure Doulos\ SIL\ Regular.ttf fi
f f_i f_f_i f_f i

behdad:util 0$ ./hb-ot-shape-closure DroidNaskh-Regular.ttf ب
uni0628 uni0628.init uni0628.medi uni0628.fina

behdad:util 0$ ./hb-ot-shape-closure DroidNaskh-Regular.ttf ا
uni0627 uni0627.fina

behdad:util 0$ ./hb-ot-shape-closure DroidNaskh-Regular.ttf با
uni0627 uni0627.fina uni0628 uni0628.init uni0628.medi uni0628.fina

behdad:util 0$ ./hb-ot-shape-closure DroidNaskh-Regular.ttf با --no-glyph-names
5 6 133 134 135 136
2012-05-15 23:53:18 -04:00