-
Notifications
You must be signed in to change notification settings - Fork 3.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Increase Powerline rounded overlap #1551
Conversation
And add meta information. Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why] We still fight with the faint lines on the big side of the powerline glyphs. They come from the LCD antialiasing mode that has problems with the borders. Other fonts use far more overlap. We use only a modest amount of overlap (1% of the width). [how] As the other fonts do, increase the overlap (to 6% now). Add full-hight 'landing platforms' on the outsides of the glyphs, which are 7% wide. Related: a8b9e1d Related: #1245 Fixes: #1547 Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
@luebking Do you want to try this out? I can patch you a font for that... (please tell me which you prefer) |
I was already looking which branch holds the change and will happily be your guinea-pig, out of pure altruism and totally not to get the rounded caps to work for at least myself ;) I have fontforge installed and can probably run the patcher locally, if that helps you anything. Edit: SauceCode - there's exactly one thing Adobe is actually really good at. |
|
I guess I don't get it...? |
This would upload "fonts.zip" to https://0x0.st and get you a tiny URL in return. It's the universal weapon of the archlinux forum :) |
Nice thing, good to know. Anyhow, here just the basic RIBBI set(s) |
I guess we now look into specific Some problems are not solvable with some clients. For example we have a bit of 'overhang' into previous/next cell to paint over the faint line. But some clients shrink glyphs that are bigger than the expected cell size to exactly fit, and then we end up with a not-tall-enough glyph that still has a faint line 😬 These clients that handle the font rendering all on their own, to be faster or better than the system... Sigh. A good way to check for cell size problems are Powerline glyphs |
I like that! |
I mostly wanted to make sure that there're no regressions w/ other (popular) TEs (where afaict there are not) I also was gonna say that xterm/st have the same problem, but actually they don't - the moment you configure their fonts using the pixelsize freetype syntax, they behave exactly like urxvt. Wrt alacritty, I could get better results when running "alacritty -v" and fiddling w/ the size variable until I had odd font and cell heights (which however doesn't seem to be always possible, at least not with single-digit precision) |
Testing this now (playing around), with this output:
#!/usr/bin/env bash
COL_A='\033[48;5;51m\033[38;5;200m'
COL_B='\033[48;5;200m\033[38;5;51m'
COL_A='\033[48;5;238m\033[38;5;253m'
COL_B='\033[48;5;253m\033[38;5;238m'
printf "\
${COL_A} \n\
Under \ue0b2${COL_B} lap ${COL_A}\ue0b0 and \ue0b6${COL_B} top ${COL_A}\ue0b4 mop\n\
${COL_A}Over \ue0b2${COL_B} lap ${COL_A}\ue0b0 and \ue0b6${COL_B} top ${COL_A}\ue0b4 mop trop lop klop\n\
\n" which looks like this with this settings (for the top image, afterwards is greyscale and none) And the font is Delugia v2111.01.2, sorry ;-) Now taking the colors from this
Hmm, that is not the case for me 🤔 antialiasing LCD, hinting none antialiasing LCD, hinting slight antialiasing LCD, hinting full Hinting moves (especially) the horizontal 'borders' of letters to pixel borders, to make them more sharp. Anyhow, I do not see the vertical antialiasing line; I know AHHH, I know why I prefer Delugia over Caskaydia Cove :-D tbc |
This is This is This is This looks clean. I always imagine faint lines, but that seems an optical illusion, even more magnification (click to enlarge) I believe this PR successfully does what it sets out to do. |
This is not used for anything. Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
A more conceise version of the Powerline test, designed to show the dreaded 'faint vertical lines' phenomenon from LCD antialiasing Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
@allcontributors please add @luebking for bug |
I've put up a pull request to add @luebking! 🎉 |
@allcontributors please add @luebking for bug and review |
I've updated the pull request to add @luebking! 🎉 |
Thanks for all the input! I am very grateful for this / the discussions! 💚 |
Many thanks for fixing this, wrt.
I meant to say that the visual perception of the shift or indention is caused by the antialiasing effect, ie. it's not really that the glyph is misplaced but the illusion is caused by the uneven density applied by the antialiasing. tilix is btw. just a wrapper around VTE3, so all terminal emulators wrapping that should get the same behavior, see eg. https://archlinux.org/packages/extra/x86_64/vte3/ |
[why] There are still the annoying vertical colored lines sometimes that turn up due to subpixel rendering. [how] Add "landing platforms" to the big triangular glyphs (E0B8, E0BA, E0BC, E0BE) and flames (E0C0, E0C2). The landing platform is approx 7% wide based on one-cell width, assuming the glyphs are all rendered 2 cells wide. Increase the overlap width for patching to 5%. See also: Merge request #1551 Merge request #1419 Commit 5e28586 Commit a8b9e1d Fixes: #1629 (well, not the top problem which is unfixable) Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
[why] There are still the annoying vertical colored lines sometimes that turn up due to subpixel rendering. [how] Add "landing platforms" to the big triangular glyphs (E0B8, E0BA, E0BC, E0BE) and flames (E0C0, E0C2). The landing platform is approx 7% wide (based on one-cell width, assuming the glyphs are all rendered 2 cells wide for the "xy2" ones). Increase the overlap width for patching to 5%. See also: Merge request #1551 Merge request #1419 Commit 5e28586 Commit a8b9e1d Fixes: #1629 (well, not the top problem which is unfixable) Signed-off-by: Fini Jastrow <ulf.fini.jastrow@desy.de>
Description
Similar to
this increases the overlap of the rounded Powerline glyphs to 6%
Patch result with the PR applied, note the increased overlap into next/previous 'cell'
Green outline is new glyph
Fixes: #1547
Requirements / Checklist
What does this Pull Request (PR) do?
How should this be manually tested?
Any background context you can provide?
What are the relevant tickets (if any)?
Screenshots (if appropriate or helpful)