From b78d2a7f75c8d9fa3f5f174526cac9106ace0ad9 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Sat, 13 Jan 2024 17:45:34 -0500 Subject: [PATCH] Add another font rendering test This one tests that we handle glyphs with lsb correctly wrt. to positioning. --- testsuite/gsk/compare/text-glyph-lsb.node | 4 ++++ testsuite/gsk/compare/text-glyph-lsb.png | Bin 0 -> 205 bytes testsuite/gsk/fonts/text-mixed-color.ttf | Bin 680 -> 708 bytes testsuite/gsk/fonts/text-mixed-color.ttx | 14 +++++++++++++- testsuite/gsk/meson.build | 1 + 5 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 testsuite/gsk/compare/text-glyph-lsb.node create mode 100644 testsuite/gsk/compare/text-glyph-lsb.png diff --git a/testsuite/gsk/compare/text-glyph-lsb.node b/testsuite/gsk/compare/text-glyph-lsb.node new file mode 100644 index 0000000000..61dd2dab89 --- /dev/null +++ b/testsuite/gsk/compare/text-glyph-lsb.node @@ -0,0 +1,4 @@ +text { + font: "text-mixed-color 30"; + glyphs: 1 40, 1 40, 8 40, 1 40; +} diff --git a/testsuite/gsk/compare/text-glyph-lsb.png b/testsuite/gsk/compare/text-glyph-lsb.png new file mode 100644 index 0000000000000000000000000000000000000000..85843e8ec8275e3993caa835e867556687d2ac5e GIT binary patch literal 205 zcmeAS@N?(olHy`uVBq!ia0vp^eL$?m!3HE#3z9zosVSZ=jv*Cu-diI?UuS_wi?fo9 n(8CEF?JgE7)DdF1Z^<}Kh$X;jXZB;D`xrc3{an^LB{Ts5*kMQ? literal 0 HcmV?d00001 diff --git a/testsuite/gsk/fonts/text-mixed-color.ttf b/testsuite/gsk/fonts/text-mixed-color.ttf index 291102a1b9e4d9b690b0ebaf030ed7c445708c89..99eb88198e225186a4db8fee29f77557aec3c9d9 100644 GIT binary patch delta 255 zcmZ3%dW3a?czq261A~rpfTIuNe+FR&2BsB2zEpBLcx z1R%cv#LrEvC}7}b;ACL1V&nh{DC8yPrq*34+X8d|$U-FsMj**3IqRyjv|~KK%~u8{ zkTM2_hlhY}0@25EGbUcJW#pL5$Ed@|Fxi?>j?sN`6r<+k*^E__|1vsEj%3OP02v}P A5&!@I diff --git a/testsuite/gsk/fonts/text-mixed-color.ttx b/testsuite/gsk/fonts/text-mixed-color.ttx index 76b742deb0..2e66f1dd6a 100644 --- a/testsuite/gsk/fonts/text-mixed-color.ttx +++ b/testsuite/gsk/fonts/text-mixed-color.ttx @@ -11,6 +11,7 @@ + @@ -82,12 +83,13 @@ + - + @@ -158,6 +160,15 @@ + + + + + + + + + @@ -200,6 +211,7 @@ + diff --git a/testsuite/gsk/meson.build b/testsuite/gsk/meson.build index 28ddebb4b7..a7190d05d0 100644 --- a/testsuite/gsk/meson.build +++ b/testsuite/gsk/meson.build @@ -136,6 +136,7 @@ compare_render_tests = [ 'stroke-fractional-translate-nogl', 'stroke-opacity', 'stroke-with-3d-contents-nogl-nocairo', + 'text-glyph-lsb', 'text-mixed-color-nocairo', 'text-mixed-color-colrv1', 'texture-coords',