fixedsys icon indicating copy to clipboard operation
fixedsys copied to clipboard

Visual font height is 15, not 16

Open isral opened this issue 4 years ago • 8 comments

I use VS code on Windows 10. I found that block or vertical line is not connected vertically because the height is not full 16px. And I found the height is (120 - -30) / 10 = 15 from line 33591:

    <TTGlyph name="block" xMin="0" yMin="-30" xMax="80" yMax="120">
      <contour>
        <pt x="80" y="-30" on="1"/>
        <pt x="0" y="-30" on="1"/>
        <pt x="0" y="120" on="1"/>
        <pt x="80" y="120" on="1"/>
      </contour>
      <instructions><assembly>
        </assembly></instructions>
    </TTGlyph>

README.md said "8x16 font".

isral avatar May 09 '20 15:05 isral

I think that this might be intentional. See the two screenshots below:

image

image

The second is a modified version of the font, with a larger vertical line. I personally think it looks a little out-of-place and too large

Here's the patch file of my changes if you'd like to try it out:

diff --git a/FSEX.ttx b/FSEX.ttx
index 4253408..8fce78b 100644
--- a/FSEX.ttx
+++ b/FSEX.ttx
@@ -33437,12 +33437,12 @@
         </assembly></instructions>
     </TTGlyph>
 
-    <TTGlyph name="bar" xMin="30" yMin="-30" xMax="50" yMax="90">
+    <TTGlyph name="bar" xMin="30" yMin="-30" xMax="50" yMax="130">
       <contour>
         <pt x="50" y="-30" on="1"/>
         <pt x="30" y="-30" on="1"/>
-        <pt x="30" y="90" on="1"/>
-        <pt x="50" y="90" on="1"/>
+        <pt x="30" y="130" on="1"/>
+        <pt x="50" y="130" on="1"/>
       </contour>
       <instructions><assembly>
         </assembly></instructions>

mikejzx avatar Apr 12 '21 01:04 mikejzx

@isral can you post those characters in text? I'm guessing it's "│", but I'm using that character in Sublime Text and Windows Terminal and they're not showing that much spacing. Maybe these programs are using a secondary font to show that character?

Here's Sublime Text on the left, Windows Terminal on the right:

image

iiiGerardoiii avatar Apr 12 '21 06:04 iiiGerardoiii

image

I disabled clear-type so the screenshot doesn't have weird color.

░▒▓█ ░▒▓█ ┌┬┐ ├┼┤ └┴┘

isral avatar Apr 12 '21 06:04 isral

If this is U+2502 endpoint you are talking about it renders correctly on my system (MacOS, iTerm2) image

image

kika avatar Apr 13 '21 18:04 kika

If this is U+2502 endpoint you are talking about it renders correctly on my system (MacOS, iTerm2) image

17px on your screenshot, overlapped 1px

isral avatar Apr 13 '21 21:04 isral

This is some iTerm trickery, I guess. Look at the vertical bar, it actually goes onto the space of the next text row (the green block in the dashed selection rectangle is part of the letter on the next row). But this pixel is dimmed.

The non-solid blocks are indeed short by one pixel on the top

image

kika avatar Apr 13 '21 22:04 kika

Same characters in MacOS Terminal with line spacing 0.935: image

Line spacing: 1 (default) image

And the blocks are okay in both cases. Anyone understands what's going on here?

kika avatar Apr 14 '21 01:04 kika

Anyone understands what's going on here?

gly2599

Like the initial comment said, the glyph (e.g. U+2599 of the somewhat older v3.02.9) is really just 150 units tall, and the font info specifies an em size of 160 (of which 130 are ascent).

jengelh avatar Dec 08 '21 21:12 jengelh