Skip to content
This repository has been archived by the owner on Nov 25, 2024. It is now read-only.

Center icons with characters #98

Open
mdSlash opened this issue Aug 19, 2024 · 0 comments
Open

Center icons with characters #98

mdSlash opened this issue Aug 19, 2024 · 0 comments
Labels
glyph rendering Adjust icon rendering
Milestone

Comments

@mdSlash
Copy link
Owner

mdSlash commented Aug 19, 2024

Describe the bug
The icons aren't centered with the characters.

Expected behavior
Icons should be center-aligned with the characters.

Additional context
If an icon takes up more than one cell, some terminals may truncate or shrink it to fit. Others might display it as-is.

For example, Kitty terminal may render icons that span multiple cells as small or truncated. In this case, the issue isn't with IconicFonts but with the terminal itself. You might need to use a different terminal or contact the developer.
image

On the other hand, terminals that handle glyphs differently, such as Alacritty, align the icons perfectly with characters.
image

To address this, one solution could be to create two font variants: one with an icon centered within a single cell and another with an icon centered across two cells, to fit different terminal rendering styles

Screenshots

one cell:
image

two cells:
image

@mdSlash mdSlash added the glyph rendering Adjust icon rendering label Aug 19, 2024
@mdSlash mdSlash pinned this issue Aug 19, 2024
@mdSlash mdSlash added this to the v1.2.0 milestone Aug 19, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
glyph rendering Adjust icon rendering
Projects
None yet
Development

No branches or pull requests

1 participant