belluzj / fantasque-sans

A font family with a great monospaced variant for programmers.
http://openfontlibrary.org/en/font/fantasque-sans-mono
SIL Open Font License 1.1
6.98k stars 154 forks source link

p, q and u are offset by 1 pixel #94

Closed martenlienen closed 6 years ago

martenlienen commented 6 years ago

Hello, yesterday I switched to your font and really enjoy it. The only thing is that the letters p, q and u are somehow offset a tiny bit in the normal weight as shown in the screenshot. This does not happen in the bold font. Do you have any idea why this could be? It did not find this effect on the example screenshots in the README.

I am using 1.7.2-no-k-loop.

Best, Marten

2018-05-17-15 34 43

belluzj commented 6 years ago

It's probably because those letters are a bit off, and also it may depend on your operating system & desktop environment & terminal emulator. Could I ask you which of those you're using?

martenlienen commented 6 years ago

Of course. I am running Arch Linux with i3 as a window manager. My terminal emulator is urxvt though the same thing happens in emacs' graphical mode and rofi, all of which I have set to use Fantasque Sans Mono. Do you have any idea what I could try to fix it or in which direction I should further investigate?

belluzj commented 6 years ago

You could try to tweak the antialiasing settings to not use autohinting. The font would look more "fuzzy" (a bit like macOS) but would not jump from one pixel to the next between letters. But mostly the problem is in the font, I need to clean up the drawings of the letters to align them properly, and other kinds of font quality assurance that I haven't taken the time to do yet.

martenlienen commented 6 years ago

Disabling auto-hinting worked. I set the following in my .Xresources.

URxvt*font: xft:Fantasque Sans Mono:size=13:hinting=false

Now I just have to figure out how to get the same result in emacs. I tried to write a fonts.conf but could not get it to work.

<!-- fonts.conf -->
<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
  <match target="font">
    <test qual="all" name="family" compare="eq">
      <string>Fantasque</string>
    </test>
    <test qual="all" name="weight" compare="eq">
      <const>medium</const>
    </test>
    <edit name="autohint" mode="assign">
      <bool>false</bool>
    </edit>
  </match>
</fontconfig>

Thank you for your help.

2018-05-17-16 31 52