Export to GitHub

fbterm - issue #39

fix 1px padding of unifont


Posted on Aug 11, 2010 by Massive Giraffe

Hi,

This issue is forward from debian/BTS #590831 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=590831


From: "Trent W. Buck" <trentbuck@gmail.com> To: Debian Bug Tracking System <submit@bugs.debian.org> Subject: wish for --font-height=16, fix 1px padding of unifont Date: Fri, 30 Jul 2010 00:02:14 +1000 Package: fbterm Version: 1.6-1 Severity: wishlist

I want to replace jfbterm (using PCF unifont) with fbterm (using TTF unifont). Unfortunately, it seems to force 1px padding between cells:

$ fbterm -vs16 -nunifont -- login -f twb
[screen] driver: inteldrmfb, mode: 1024x600-32bpp, scrolling: redraw
[font] width: 9px, height: 17px, ordered list: unifont, DejaVu Sans, DejaVu Sans Mono, DejaVu Serif
[term] size: 113x35, default codec: UTF-8

In jfbterm I get the same size unifont glyphs, but they're packed a little more tightly (and look better):

# jfbterm -e login -f twb
$ echo $COLUMNS'x'$LINES
128x37

I can "fix" the width with --font-width=8, but I can't force the height to 16px instead of 17px. I also tried -s15, -s15.9, -s16pt, -s16px, -nunifont-16 and -nunifont:pixelSize=16 -- none of which worked.

I think a cheap way to get what I want is to simply patch in a corresponding --font-height=16 option that sets mHeight.

PS: I'd actually prefer DejaVu + Dotum over unifont, but fbterm doesn't do antialiasing, so to me ALL outline fonts look crap in it.


I tested attached patch. Work fine for me. I applied this patch on Debian. Could you apply?

Best regards, Nobuhiro

Attachments

Comment #1

Posted on Aug 15, 2010 by Happy Horse

TTF unifont gives different width/height from PCF unifont.

Thanks for your patch! I will add it in next version.

In order to let FbTerm do antialiasing for font Dejavu Sans Mono, perhaps you should add/modify specific configuration of fontconfig for that font.

Comment #2

Posted on Oct 6, 2010 by Happy Horse

added in version 1.7

Status: Verified

Labels:
Type-Defect Priority-Medium