Skip to content

Commit

Permalink
font-patcher: Limit vertical overlap
Browse files Browse the repository at this point in the history
[why]
The vertical overlap has never been a problem (as far as I know). It is
maybe good to have some overlap for the terminal emulators that support
vertical overlap.
On terminals that truncate at the nominal cell border too much overlap
looks bad, i.e. the glyphs 'distorted'.

If we ever increase the overlap it is most likely be meant to be the
left-right overlap.

[note]
Originally this has been part of commit fecda6a of #780.

Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
  • Loading branch information
Finii committed Oct 14, 2022
1 parent 2d53894 commit 602b3ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion font-patcher
Original file line number Diff line number Diff line change
Expand Up @@ -1038,7 +1038,7 @@ class font_patcher:
if scale_ratio_x != 1 or scale_ratio_y != 1:
if overlap:
scale_ratio_x *= 1 + overlap
scale_ratio_y *= 1 + overlap
scale_ratio_y *= 1 + max(0.01, overlap) # never aggressive vertical overlap
self.sourceFont[currentSourceFontGlyph].transform(psMat.scale(scale_ratio_x, scale_ratio_y))

# Use the dimensions from the newly pasted and stretched glyph
Expand Down

0 comments on commit 602b3ea

Please sign in to comment.