You are not logged in.

#1 2015-01-19 19:16:39

noarch
Member
Registered: 2015-01-06
Posts: 17

[Solved]spacing between characters not correct on any termial emulator

Hi All,

I'm using Xfce on my laptop. The fonts don't look right in any of the terminal emulators. I've tried Xfce terminal, guake and terminator. Each one of them shows the same problem, sometimes the characters overlap and sometimes they are too far apart. You can have a look at the screenshot for xrandr output.

https://www.dropbox.com/s/rqmfy64iv137g … on_002.png

However, xterm looks just fine.

I'm currently using infinality-bundle fonts. However, the probem existed with the default fonts as well.

Thanks

Last edited by noarch (2015-01-20 13:56:39)

Offline

#2 2015-01-19 19:46:58

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,424
Website

Re: [Solved]spacing between characters not correct on any termial emulator

Broken prompt (incorrectly escaped) or you are forcing the TERM variable in one of your shell files would be my guesses...


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2015-01-19 20:00:08

noarch
Member
Registered: 2015-01-06
Posts: 17

Re: [Solved]spacing between characters not correct on any termial emulator

Jason,

Thanks for the suggestion

echo $TERM gives 'xterm' on both actual xterm console and on xfce-terminal. Xfce-terminal docs recommend using 'xterm' as Emulation setting http://docs.xfce.org/apps/terminal/preferences .

What did you exactly mean by "Broken prompt"? I'm using all ascii characters in title/prompt(not even utf-8).

Offline

#4 2015-01-19 20:36:42

noarch
Member
Registered: 2015-01-06
Posts: 17

Re: [Solved]spacing between characters not correct on any termial emulator

Changing the font works, but only in some cases. For ex. If I change the font to "clean" or "fixed", then characters appear perfectly. For all other fonts, the problem remains.

Since both the 'clean' and 'fixed' fonts are not anti-aliased, I'm guessing the problem is with anti-aliasing capabilities.

Offline

#5 2015-01-20 00:03:53

Knute
Member
From: Minot, ND
Registered: 2009-03-17
Posts: 604

Re: [Solved]spacing between characters not correct on any termial emulator

There was a letterSpace option that I played with when I had issues with fonts being to spread apart or condensed.  That was in urxvt, and I'm not sure if that helps you at all but it's worth looking into.
Here's the exerpt from my ~/.Xdefaults file.

!urxvt.letterSpace:  -8

HTH


Knute

Offline

#6 2015-01-20 00:30:35

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: [Solved]spacing between characters not correct on any termial emulator

@noarch,
What are the specific fonts that give you odd spacing, or bad kerning?  I suspect you are trying to use proportionally spaced fonts. Yes, they look awful in a terminal emulator.

Terminal emulators expect monospace fonts. To list the monospaced fonts installed on your machine, try either of these two commands:
⁣ ⁣ fc-list :spacing=100 or fc-list :spacing=mono

Many people seem to be fond of the terminus font whose package name is terminus-font. Some folks like Liberation Mono from the ttf-liberation package, but my workhorse monospace font is DejaVu Sans Mono from ttf-dejavu.

Edited to fix typo.

Last edited by thisoldman (2015-01-20 00:34:27)

Offline

#7 2015-01-20 05:59:06

noarch
Member
Registered: 2015-01-06
Posts: 17

Re: [Solved]spacing between characters not correct on any termial emulator

@thisoldman,

fc-list command gives me this.

[cheema@screwed ~]$ fc-list :spacing=mono
/usr/share/fonts/misc/micro.pcf.gz: micro.pcf:style=Regular
/usr/share/fonts/misc/deccurs.pcf.gz: deccurs.pcf:style=Regular
/usr/share/fonts/misc/cursor.pcf.gz: cursor.pcf:style=Regular
/usr/share/fonts/misc/decsess.pcf.gz: decsess.pcf:style=Regular

But again, none of these fonts help the matters. Is is possible that monospace fonts are not installed/not properly installed?

Offline

#8 2015-01-20 08:07:09

TheSaint
Member
From: my computer
Registered: 2007-08-19
Posts: 1,523

Re: [Solved]spacing between characters not correct on any termial emulator

I do face similar problem with my daughter PC. She has Chinese locale. The writing is overlapping, specially for UTF8.


do it good first, it will be faster than do it twice the saint wink

Offline

#9 2015-01-20 09:08:35

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: [Solved]spacing between characters not correct on any termial emulator

noarch wrote:

But again, none of these fonts help the matters. Is is possible that monospace fonts are not installed/not properly installed?

@noarch, I do wonder how you installed the infinality packages. I do not use that bundle. Did you perhaps use the infinality packages in the AUR? The AUR packages are outdated.

I suggest following the Infinality instructions in the wiki: https://wiki.archlinux.org/index.php/Infinality.

Pay particular attention to the '"Installation" section, adding the infinality repo to your pacman.conf, https://wiki.archlinux.org/index.php/Un … ity-bundle and adding the proper key to your pacman keyring, https://wiki.archlinux.org/index.php/Pa … icial_keys.

Offline

#10 2015-01-20 09:57:10

thisoldman
Member
From: Pittsburgh
Registered: 2009-04-25
Posts: 1,172

Re: [Solved]spacing between characters not correct on any termial emulator

@TheSaint,
I think you should start a new thread, perhaps titled "Chinese fonts in terminals?" You can reference this thread in your first post. And do mention if the infinality bundle is involved. Also include in that post the results of the locale command from your daughter's machine.

Chinese font usage is complicated due to the interplay of Unicode and other Chinese language encodings, the various input methods, and the capabilities of the terminal emulator used.

You can check for installed fonts that advertise themselves as Chinese with the command fc-list :lang=zh. The results could be an incomplete or an incorrect list—not all fonts properly advertise their language support.

Urxvt might be a good choice for a Chinese language terminal app. I don't know how good it is when compared to other emulators. My locale is set for "en_US.UTF-8" and I prefer small fonts. The font ladder I currently use in urxvt includes:

urxvt*font: xft:DejaVu Sans Mono:style=Book:antialias=false:size=8, \
            xft:WenQuanYi Bitmap Song:size=8, \
            xft:unifont:style=Medium:antialias=false, \
            xft:FreeSerif:style=Regular

With the UTF-8 only locale, these settings get me an acceptable Chinese font display in xterm:

xterm*termName: xterm-256color
XTerm*locale: true

xterm*faceName: DejaVu Sans Mono:style=Book:antialias=false
xterm*faceNameDoublesize: WenQuanYi Bitmap Song
xterm*faceSize: 8
xterm*scaleHeight: 1.01

Last edited by thisoldman (2015-01-20 09:57:32)

Offline

#11 2015-01-20 11:54:46

TheSaint
Member
From: my computer
Registered: 2007-08-19
Posts: 1,523

Re: [Solved]spacing between characters not correct on any termial emulator

thisoldman wrote:

@TheSaint,
I think you should start a new thread, perhaps titled "Chinese fonts in terminals?"

You're right
I posted here and the answer is already fair.


do it good first, it will be faster than do it twice the saint wink

Offline

#12 2015-01-20 13:55:19

noarch
Member
Registered: 2015-01-06
Posts: 17

Re: [Solved]spacing between characters not correct on any termial emulator

It was a silly mistake on my part. I tried to install 'infinality-bundle-fonts' package, but since it errored out, I just totally ignored the whole package.

[root@screwed cheema]# pacman -S infinality-bundle-fonts
:: There are 44 members in group infinality-bundle-fonts:
:: Repository infinality-bundle-fonts
   1) otf-heuristica-ib  2) otf-oswald-ib  3) otf-quintessential-ib  4) otf-tex-gyre-ib  5) t1-bh-ib  6) t1-cursor-ib
   7) t1-dejavu-ib  8) t1-urw-fonts-ib  9) ttf-bh-ib  10) ttf-caladea-ib  11) ttf-cantoraone-ib  12) ttf-carlito-ib
   13) ttf-courier-prime-ib  14) ttf-ddc-uchen-ib  15) ttf-dejavu-ib  16) ttf-droid-ib  17) ttf-droid-nonlatin-ib  18) ttf-faruma-ibx
   19) ttf-gelasio-ib  20) ttf-heuristica-ib  21) ttf-liberastika-ib  22) ttf-liberation-ib  23) ttf-lohit-assamese-ib
   24) ttf-lohit-bengali-ib  25) ttf-lohit-devanagari-ib  26) ttf-lohit-gujarati-ib  27) ttf-lohit-gurmukhi-ib
   28) ttf-lohit-kannada-ib  29) ttf-lohit-malayalam-ib  30) ttf-lohit-marathi-ib  31) ttf-lohit-nepali-ib  32) ttf-lohit-odia-ib
   33) ttf-lohit-punjabi-ib  34) ttf-lohit-tamil-ib  35) ttf-lohit-telugu-ib  36) ttf-merriweather-ib  37) ttf-merriweather-sans-ib
   38) ttf-noto-sans-ib  39) ttf-noto-sans-multilang-ib  40) ttf-noto-serif-ib  41) ttf-noto-serif-multilang-ib  42) ttf-opensans-ib
   43) ttf-symbola-ib  44) ttf-ubuntu-font-family-ib

Enter a selection (default=all): 
warning: otf-heuristica-ib-1.0.2-2 is up to date -- reinstalling
warning: t1-bh-ib-1.0.3-2 is up to date -- reinstalling
warning: ttf-courier-prime-ib-1.203-6 is up to date -- reinstalling
warning: ttf-merriweather-sans-ib-1.003-8 is up to date -- reinstalling
warning: ttf-noto-sans-ib-2014.12-4 is up to date -- reinstalling
warning: ttf-noto-serif-ib-2014.12-4 is up to date -- reinstalling
warning: ttf-opensans-ib-1.2-17 is up to date -- reinstalling
warning: ttf-symbola-ib-7.19-2 is up to date -- reinstalling
warning: ttf-ubuntu-font-family-ib-0.80-11 is up to date -- reinstalling
resolving dependencies...
looking for conflicting packages...
error: unresolvable package conflicts detected
error: failed to prepare transaction (conflicting dependencies)
:: t1-bh-ib and ttf-bh-ib are in conflict

Well, turns out that installing those individual fonts resolves the problem. Its a bit tedious installing individual fonts(there are around 40 options to choose from), but it does solve the spacing problem.

Offline

Board footer

Powered by FluxBB