chiark / gitweb /
Fix vertical stem hints on bold condensed fonts
authorBen Harris <bjh21@bjh21.me.uk>
Tue, 19 Nov 2024 23:38:46 +0000 (23:38 +0000)
committerBen Harris <bjh21@bjh21.me.uk>
Tue, 19 Nov 2024 23:40:54 +0000 (23:40 +0000)
The weight needed to be adjusted to allow for the change in width.

bedstead.c

index 6fc2696d7e7277cefdbb3fae3a01cd3a261483a5..b5d3b68bc5d9535d675386f35e400f99ffb1341b 100644 (file)
@@ -3906,8 +3906,8 @@ emit_hints(int vstems[XSIZE], int ledges[XSIZE], int redges[XSIZE],
                case hint_counter_stem:
                        need_cntrmask = true; /* FALLTHROUGH */
                case hint_stem:
-                       start = i * XPIX - weight->weight;
-                       size = XPIX + weight->weight;
+                       start = i * XPIX - weight->weight / XSCALE;
+                       size = XPIX + weight->weight / XSCALE;
                        break;
                case hint_aedge: /* Left edge. */
                        start = i * XPIX + 21;