From cc6a9bfa6f4eca07b8dec693acfc557cd21c073c Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Sun, 15 Jan 2023 18:16:19 -0700 Subject: [PATCH] [hb-shape/view] Print table length in --list-tables --- util/face-options.hh | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/util/face-options.hh b/util/face-options.hh index d6d983c84..e193b0000 100644 --- a/util/face-options.hh +++ b/util/face-options.hh @@ -137,7 +137,13 @@ static G_GNUC_NORETURN void _list_tables (hb_face_t *face) for (unsigned i = 0; i < count; i++) { - printf ("%c%c%c%c\n", HB_UNTAG (tags[i])); + hb_tag_t tag = tags[i]; + + hb_blob_t *blob = hb_face_reference_table (face, tag); + + printf ("%c%c%c%c: %8u bytes\n", HB_UNTAG (tag), hb_blob_get_length (blob)); + + hb_blob_destroy (blob); } free (tags);