shithub: neatroff

Download patch

ref: f1e7a115b847b2617620668d5611b8bdc43cec01
parent: 399a4936bad90998d119f25431889b25a3b03f5f
author: Ali Gholami Rudi <[email protected]>
date: Wed Feb 19 14:05:22 EST 2014

wb: disable ligatures and pairwise kerning while changing fonts

--- a/wb.c
+++ b/wb.c
@@ -179,6 +179,7 @@
 	char *cs[LIGLEN + 2];
 	int i = -1;
 	int ligpos;
+	wb_font(wb);		/* apply font changes */
 	cs[0] = c;
 	while (wb_prev(wb, ++i))
 		cs[i + 1] = wb_prev(wb, i);
@@ -198,6 +199,7 @@
 int wb_kern(struct wb *wb, char *c)
 {
 	int val;
+	wb_font(wb);		/* apply font changes */
 	if (!wb_prev(wb, 0))
 		return 1;
 	val = font_kern(dev_font(R_F(wb)), wb_prev(wb, 0), c);