util/options.cc


Log

Author Commit Date CI Message
Chun-wei Fan 998e8dda 2015-11-02T16:55:29 util: Fix build on Visual Studio Use the fallback implementation for lround() only on pre-2013 Visual Studio, and ensure we are clear about the types of the parameters for lround() and scalbnf(), since Visual Studio can be quite picky on ambiguous parameter types. Also, use g_ascii_strcasecmp() rather than strcasecmp() as we are already using GLib for this code and we are assured that g_ascii_strcasemp() is available. For scalbnf() on pre-2013 Visaul Studio, a fallback implementation is needed, but use another forced-included header for those compilers, which will be added later. Also use (char)27 on Visual Studio builds as '\e' is not a recognized escape sequence, which will do the same thing.
Behdad Esfahbod 3530cc2d 2015-11-03T11:34:47 [util] Fix option-parsing leaks
Behdad Esfahbod 642135f3 2015-11-03T11:26:34 [util] In --debug mode, duplicate font data This has the effect that the font data will end up in a memory section malloc()ed exactly to its size. This gives us better valgrind detection of out-of-bounds access. Previously, the font data was placed in a mmap()ed section or GString-allocated area, which didn't have proper protections at the end when running under valgrind.
Behdad Esfahbod fdd1770e 2015-08-24T13:49:55 Add API/cmdline to show glyph extents when serializing buffer New API: HB_BUFFER_SERIALIZE_FLAG_GLYPH_EXTENTS hb-shape now accepts --show-extents. Patch from Simon Cozens.
Behdad Esfahbod 376d587f 2015-07-22T16:51:12 Implement more granular cluster-merging TODO: Documentation. Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=71445
Behdad Esfahbod 16dac7ec 2015-06-03T12:07:46 Fix build
Behdad Esfahbod 820505a1 2015-04-13T23:51:45 Whitespace
Behdad Esfahbod 76d57331 2015-04-13T23:40:35 Merge pull request #86 from cpfair/hb-shape-output-help-improvement Improve hb-shape/hb-view's help text w.r.t. output options
Behdad Esfahbod a664810e 2015-04-09T15:04:42 [util] Accept comma as well as space when separating components of args Applies to --font-size and --margin. Hopefully the scanf usage here doesn't have compatibility issues (star being counted in the return value, etc).
Collin Fair 9ee176ee 2015-02-14T09:59:44 Stop hb-shape docs leaking into hb-view
Collin Fair 952b8dbd 2015-02-14T09:44:00 'All' of the above, not 'each'
Collin Fair 9e867b64 2015-02-14T09:32:04 Remove reference to --help-output-content in --help-output (as --help-output-format's options aren't available in hb-view)
Collin Fair 1d55ffeb 2015-02-14T09:29:35 Add serialization syntax documentation. Clarify naming and wording in --help-output/--help-format
Behdad Esfahbod cd4eb96a 2015-01-20T12:30:45 [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.
Behdad Esfahbod 5789ca69 2015-01-09T14:22:01 [util] Minor
Behdad Esfahbod c36c4a99 2015-01-02T14:09:23 Add missing va_end() Fixes https://github.com/behdad/harfbuzz/pull/74
Behdad Esfahbod 0de25d41 2014-07-25T12:35:03 [util] Note CSS compatibility in --help-features
Behdad Esfahbod 8650def7 2014-07-05T15:50:18 [util] Add option to set font function implementation to use Supports ft and ot right now. hb-view currently not rendering with ot. Will fix after some clean up.
Behdad Esfahbod 2306ad46 2014-07-04T18:09:29 [util] Fix memory issue
Behdad Esfahbod 90364843 2014-03-24T14:26:36 Start fleshing out builtin font functions
Behdad Esfahbod ea5e8a02 2014-03-19T15:38:02 [util] Plug minor leak
Behdad Esfahbod d688475e 2013-12-12T13:21:57 Minor
Behdad Esfahbod 260a3198 2013-12-02T05:39:39 [util] Plug leak
Behdad Esfahbod c2bc8187 2013-10-27T23:36:35 Work with old and new glib Avoids "deprecated" warnings.
Behdad Esfahbod 9326d48e 2013-10-10T20:04:42 Don't use g_mapped_file_unref() Was introduced in glib 2.22.
Behdad Esfahbod 50067e28 2013-04-11T16:31:01 [util] Add --num-iterations Useful for profiling shapers.
Behdad Esfahbod e2aab4b5 2013-02-12T15:35:32 Improve checks for setmode() As reported by Jonathan, OS X has setmode() that is something other than what setmode() is on Win32. So, limit invocation to Windows platforms only.
Behdad Esfahbod ceeae30f 2013-01-31T19:27:36 Really fix setmode this time Thanks to Khaled for spotting it.
Behdad Esfahbod 7cba8a67 2013-01-31T18:37:10 Fixup previous commit Now, it looks like this breaks Cygwin again. Have to figure out what's going on.
Behdad Esfahbod bc76449f 2013-01-31T18:18:05 Use setmode() instead of _setmode() Looks like Cygwin / MSVC declare it that way, and it still works on MinGW32 cross.
Behdad Esfahbod 9815a881 2012-12-21T16:46:53 [util] List supported output formats in --help output
Behdad Esfahbod 9a34a50d 2012-12-05T19:18:18 Fix build with C++11
Behdad Esfahbod f9edf167 2012-11-15T12:14:09 Add buffer serialization / deserialization API Two output formats for now: TEXT, and JSON. For example: hb-shape --output-format=json Deserialization API is added, but not implemented yet.
Behdad Esfahbod 407f80d6 2012-11-13T15:33:27 [util] Add --bot / --eot / --preserve-default-ignorables
Behdad Esfahbod 78d41d8d 2012-11-13T15:15:09 Minor
Behdad Esfahbod 321f73c1 2012-11-13T15:12:24 [util] Add --text-before and --text-after to hb-shape / hb-view Use with Arabic, for example, to see the effect on joining.
Behdad Esfahbod c8149ca8 2012-11-13T11:07:20 [hb-shape] Adjust postioning output format 1. If there is any offset (x or y), print out both x and y offsets. 2. Always print out the advance in the major direction of the buffer. Ie. even for zero-advance glyphs, print a "+0". This is more intuitive.
Behdad Esfahbod 3bc22eb7 2012-11-12T10:07:28 Minor
Behdad Esfahbod e30ebd27 2012-09-06T22:09:06 Add hb_feature_to/from_string()
Behdad Esfahbod 6f3a3001 2012-08-07T22:13:25 Add hb_font_glyph_from/to_string
Behdad Esfahbod ade7459e 2012-08-06T19:42:47 [util] Fix leaks
Behdad Esfahbod bdc48a87 2012-08-04T17:08:38 Enlarge glyph_name buffer Lohit Devanagari has a glyph named: u0924_u094D.half_u0930_u094D.blwf.vatu
Behdad Esfahbod 39b17837 2012-07-17T17:09:29 Add hb_buffer_normalize_glyphs() and hb-shape --normalize-glyphs This reorders glyphs within the cluster to a nominal order. This should have no visible effect on the output, but helps with testing, for getting the same hb-shape output for visually-equal glyphs for each cluster.
Behdad Esfahbod 0594a244 2012-06-05T20:35:40 Cleanup TRUE/FALSE vs true/false
Behdad Esfahbod c1885483 2012-06-04T08:56:00 Add --verbose to hb-shape Just turns all --show-* options on.
Behdad Esfahbod ae621665 2012-06-02T12:21:19 [util] Minor
Behdad Esfahbod 5db0683a 2012-06-02T12:13:08 [util] Make hb-shape continue shaping other lines if shapers failed
Behdad Esfahbod bce09552 2012-05-27T11:29:21 Add hb_font_get_glyph_name() and hb_font_get_glyph_from_name()
Behdad Esfahbod 8f8956a5 2012-05-25T14:30:24 [util] Add hidden --shaper that is equivalent of --shapers
Behdad Esfahbod 30874b48 2012-05-12T15:54:27 [util] Make tools default to stdin if no text is provided One less argument to type in typical testing workflow!
Behdad Esfahbod 95cefdf9 2012-04-16T18:08:20 Add --utf8-clusters Also fix cairo cluster generation.
Behdad Esfahbod f51e1674 2012-01-30T09:48:33 Minor error handling
Behdad Esfahbod d5300241 2012-01-21T19:07:22 [util] Make clusters work with char offset instead of UTF-8 offset This means the --features indices also refer to char position instead of byte position now. Same for cluster values reported by hb-shape. Will add an option for byte indices later.
Behdad Esfahbod 0f68f4a0 2012-01-21T18:59:48 Correctly print out Unicode strings
Behdad Esfahbod d8134bc0 2012-01-20T17:18:59 [hb-shape] Add parantheses around --show-text output
Behdad Esfahbod c91c4fa4 2012-01-19T17:51:57 [hb-shape] Change glyphstring brackets from </> to [/] Sorry for the disruption but I need this to differentiate from the Unicode string.
Behdad Esfahbod cdc673d9 2012-01-19T12:46:18 [hb-shape] Add --show-line-num Ok, much more useful as a test suite driver now.
Behdad Esfahbod cc4d9810 2012-01-19T12:32:20 [hb-shape] Add --show-text and --show-unicode options
Behdad Esfahbod 27c36af4 2012-01-19T12:30:43 Fix OOB in hb-shape
Behdad Esfahbod 8750abaf 2012-01-18T22:47:44 [util] Add --help-features Patch from Khaled Hosny.
Behdad Esfahbod a097043f 2012-01-14T17:55:51 Allow space in one more place when parsing features
Behdad Esfahbod fd528c17 2011-10-12T15:03:58 [util] Add --list-shapers to hb-view and hb-shape
Behdad Esfahbod 5857720c 2011-09-27T12:36:26 [util] s/%d/%u/ when printing glyph ids and clusters
Behdad Esfahbod d3f3690b 2011-09-21T16:41:43 hb-shape: In --no-glyph-names, output glyph number directly Ie. write "86" instead of "gid86".
Behdad Esfahbod 088c1e27 2011-09-20T14:43:55 [util] Fix option parsing Wow, who knew bool is one byte and I was using it as a 4byte int?! C++ auto casts fails you in mysterious ways...
Behdad Esfahbod 42255814 2011-09-19T17:57:02 [util] Account for line-space in surface size
Behdad Esfahbod b5afd8f7 2011-09-19T16:56:21 [util] Rename --output to --output_file, and --format to --output-format
Behdad Esfahbod 8b8b1905 2011-09-19T16:41:17 [util] Add hb-shape utility Like hb-view, but prints out buffer contents. The output format is kinda cryptic. Suggestions welcome.
Behdad Esfahbod 11e51993 2011-09-19T09:58:55 [util] Move font-size into view-options
Behdad Esfahbod 0fe29601 2011-09-17T09:59:58 Fix Linux build when io.h is available Bug 40953 - fail compile git: make[2]: *** [hb_view-options.o] Error 1
Behdad Esfahbod 5ddd9cc4 2011-09-16T16:40:44 Minor
Behdad Esfahbod 55aeb049 2011-09-16T02:08:36 Fix reading text from stdin
Behdad Esfahbod a75c1b12 2011-09-16T01:16:41 Move code around
Behdad Esfahbod 7bf6ecd3 2011-09-16T01:11:30 Always shape at size=upem Fixes bug with uniscribe not handling GIGANTIC sizes.
Behdad Esfahbod 674ee58d 2011-09-16T00:54:05 Minor
Behdad Esfahbod 4451168e 2011-09-16T00:38:19 Fix binary stdin/stdout io in Windows Make --font-file accept "-" to mean stdin, and have it work in Windows too!
Behdad Esfahbod 639b5957 2011-09-15T18:09:49 Minor
Behdad Esfahbod b9b10ad7 2011-09-13T13:30:39 [util] Refactor hb-view completely Now we can use the same code to do other utils...
Behdad Esfahbod bc4b07b0 2011-09-08T17:08:32 More reshuffling
Behdad Esfahbod 109cb382 2011-09-08T16:00:04 [util] Further refactor option parsing
Behdad Esfahbod 4c9fe88d 2011-08-26T09:18:53 [API] Make all _from_string() functions take a len parameter Can be -1 for NUL-terminated string. This is useful for passing parts of a larger string to a function without having to copy or modify the string first. Affected functions: hb_tag_t hb_tag_from_string() hb_direction_from_string() hb_language_from_string() hb_script_from_string()
Behdad Esfahbod 97796453 2011-08-15T19:03:43 Fix falloffs of the GOption conversion
Behdad Esfahbod 3bb300ee 2011-08-11T11:54:31 Refactor hb-view code