Merge remote-tracking branch 'upstream/master'

pull/2157/head
Ebrahim Byagowi 5 years ago
commit 43253e404d
  1. BIN
      test/api/fonts/NotoColorEmoji.cmap.38,AE,2049.ttf
  2. BIN
      test/api/fonts/NotoColorEmoji.cmap.ttf
  3. 44
      test/api/test-subset-cmap.c
  4. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E00,4E02,4E03.otf
  5. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E00,4E03.otf
  6. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E00,4E05,4E07.otf
  7. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E02,4E03,4E08.otf
  8. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E02.otf
  9. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E03.otf
  10. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E05,4E07,4E08,4E09.otf
  11. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E08,4E09.otf
  12. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.4E08.otf
  13. BIN
      test/subset/data/expected/cmap14/cmap14_font2.default.retain-all-codepoint.otf
  14. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E00,4E02,4E03.otf
  15. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E00,4E03.otf
  16. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E00,4E05,4E07.otf
  17. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E02,4E03,4E08.otf
  18. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E02.otf
  19. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E03.otf
  20. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E05,4E07,4E08,4E09.otf
  21. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E08,4E09.otf
  22. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.4E08.otf
  23. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints-retain-gids.retain-all-codepoint.otf
  24. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E00,4E02,4E03.otf
  25. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E00,4E03.otf
  26. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E00,4E05,4E07.otf
  27. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E02,4E03,4E08.otf
  28. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E02.otf
  29. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E03.otf
  30. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E05,4E07,4E08,4E09.otf
  31. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E08,4E09.otf
  32. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.4E08.otf
  33. BIN
      test/subset/data/expected/cmap14/cmap14_font2.drop-hints.retain-all-codepoint.otf
  34. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E00,4E02,4E03.otf
  35. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E00,4E03.otf
  36. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E00,4E05,4E07.otf
  37. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E02,4E03,4E08.otf
  38. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E02.otf
  39. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E03.otf
  40. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E05,4E07,4E08,4E09.otf
  41. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E08,4E09.otf
  42. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.4E08.otf
  43. BIN
      test/subset/data/expected/cmap14/cmap14_font2.name-ids.retain-all-codepoint.otf
  44. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E00,4E02,4E03.otf
  45. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E00,4E03.otf
  46. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E00,4E05,4E07.otf
  47. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E02,4E03,4E08.otf
  48. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E02.otf
  49. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E03.otf
  50. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E05,4E07,4E08,4E09.otf
  51. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E08,4E09.otf
  52. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.4E08.otf
  53. BIN
      test/subset/data/expected/cmap14/cmap14_font2.retain-gids.retain-all-codepoint.otf
  54. BIN
      test/subset/data/fonts/cmap14_font2.otf
  55. 1
      test/subset/data/tests/cmap14.tests

@ -133,6 +133,48 @@ test_subset_cmap_empty_tables (void)
hb_face_destroy (face_empty);
}
static void
test_subset_cmap_noto_color_emoji_noop (void)
{
hb_face_t *face = hb_test_open_font_file ("fonts/NotoColorEmoji.cmap.ttf");
hb_set_t *codepoints = hb_set_create ();
hb_face_t *face_subset;
hb_set_add (codepoints, 0x38);
hb_set_add (codepoints, 0x39);
hb_set_add (codepoints, 0xAE);
hb_set_add (codepoints, 0x2049);
hb_set_add (codepoints, 0x20E3);
face_subset = hb_subset_test_create_subset (face, hb_subset_test_create_input (codepoints));
hb_set_destroy (codepoints);
hb_subset_test_check (face, face_subset, HB_TAG ('c','m','a','p'));
hb_face_destroy (face_subset);
hb_face_destroy (face);
}
static void
test_subset_cmap_noto_color_emoji_non_consecutive_glyphs (void)
{
hb_face_t *face = hb_test_open_font_file ("fonts/NotoColorEmoji.cmap.ttf");
hb_face_t *face_expected = hb_test_open_font_file ("fonts/NotoColorEmoji.cmap.38,AE,2049.ttf");
hb_set_t *codepoints = hb_set_create ();
hb_face_t *face_subset;
hb_set_add (codepoints, 0x38);
hb_set_add (codepoints, 0xAE);
hb_set_add (codepoints, 0x2049);
face_subset = hb_subset_test_create_subset (face, hb_subset_test_create_input (codepoints));
hb_set_destroy (codepoints);
hb_subset_test_check (face_expected, face_subset, HB_TAG ('c','m','a','p'));
hb_face_destroy (face_subset);
hb_face_destroy (face_expected);
hb_face_destroy (face);
}
// TODO(rsheeter) test cmap to no codepoints
int
@ -145,6 +187,8 @@ main (int argc, char **argv)
hb_test_add (test_subset_cmap_non_consecutive_glyphs);
hb_test_add (test_subset_cmap4_no_exceeding_maximum_codepoint);
hb_test_add (test_subset_cmap_empty_tables);
hb_test_add (test_subset_cmap_noto_color_emoji_noop);
hb_test_add (test_subset_cmap_noto_color_emoji_non_consecutive_glyphs);
return hb_test_run();
}

@ -1,5 +1,6 @@
FONTS:
cmap14_font1.otf
cmap14_font2.otf
PROFILES:
default.txt

Loading…
Cancel
Save