sites

public wiki contents of suckless.org
git clone git://git.suckless.org/sites
Log | Files | Refs

index.md (1205B)


      1 charoffsets
      2 ===========
      3 
      4 Description
      5 -----------
      6 Some fonts seem to misreport their height, which leads to unsightly vertical
      7 gaps appearing between rows of text with characters that are supposed to fill
      8 the vertical space, like box-drawing characters.
      9 
     10 This is because the character height that st uses is off from the actual glyph
     11 height, so there's a gap of bg space above and below each glyph. This can be
     12 adjusted by modifying the `chscale` value, but reducing that value alone just
     13 clips the bottom of the glyphs.
     14 
     15 This patch simply adds a `cyoffset` value (and a corresponding `cxoffset`) to
     16 allow you to adjust the glyph position, so it doesn't get clipped short when
     17 you reduce the `chscale`. You'll have to play with the values to get it to
     18 look right with your font choice.
     19 
     20 Example
     21 -------
     22 Note the vertical gaps between the lines in the box art, and the raised part
     23 that sticks out on the time display.
     24 
     25 Taken with Pragmata Pro with a few font patches applied.
     26 
     27 [![An example of the vertical gaps.](vertical-gaps.png)](vertical-gaps.png)
     28 
     29 Download
     30 --------
     31 * [st-charoffsets-20220311-0.8.5.diff](st-charoffsets-20220311-0.8.5.diff)
     32 
     33 Authors
     34 -------
     35 * Zacchary Dempsey-Plante - <zacc@ztdp.ca>