Hi,

I'm trying to switch from xterm to urxvt. Everything is fine, except one
problem: with my favorite font I have only 62 lines on maximized terminal
instead of 67 with xterm.

It happens because xterm uses ascent + descent as a font height, but urxvt
uses ascent + descent or height metrics from font face, depending what's
higher. In my case urxvt adds extra pixel after each line.

Let's use ascent + descent as font height. You always can add extra space
between lines using -lsp.

Use of ascent + descent is also consistent with handling X11 fonts in
urxvt.

I know, that urxvt doesn't handle overlapping lines[1], but it should not
be a problem here since lines will not overlap IIUC.

[0] xft:PragmataPro:size=9:antialias=false
[1] http://lists.schmorp.de/pipermail/rxvt-unicode/2012q1/001548.html

--- a/src/rxvtfont.C    2012-01-19 15:34:39.000000000 +0200
+++ b/src/rxvtfont.C    2012-11-23 01:07:40.781078067 +0200
@@ -1239,7 +1239,7 @@
 
       ascent  = (face->size->metrics.ascender + 63) >> 6;
       descent = (-face->size->metrics.descender + 63) >> 6;
-      height  = max (ascent + descent, (face->size->metrics.height + 63) >> 6);
+      height  = ascent + descent;
       width   = 0;
 
       bool scalable = face->face_flags & FT_FACE_FLAG_SCALABLE;
-- 
 Kirill A. Shutemov

_______________________________________________
rxvt-unicode mailing list
[email protected]
http://lists.schmorp.de/cgi-bin/mailman/listinfo/rxvt-unicode

Reply via email to