Skip to content
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

RobotoMono "Mono" variant is too widely spaced #597

Closed
rrobertobt opened this issue Mar 22, 2021 · 6 comments
Closed

RobotoMono "Mono" variant is too widely spaced #597

rrobertobt opened this issue Mar 22, 2021 · 6 comments

Comments

@rrobertobt
Copy link

rrobertobt commented Mar 22, 2021

🎯 Subject of issue

The "RobotoMono Nerd Font Mono" seems to have been spaced more widely than the non-mono version "RobotoMono Nerd Font"
Seems like this issue has been reported once in the past but didn't find a solution: #220
It partly affects terminals like kitty and Alacritty but these have cell spacing and sizing configuration options so it can be solved

Screenshots with detailed description are below

🔧 My current set-up

  • RobotoMono Nerd Font 11
  • GNOME Terminal, Tilix, Kitty
  • Fedora Linux 33 x86_64

★ Screenshots

Tilix terminal - Using the "Mono" variant
Screenshot from 2021-03-21 23-13-30

Tilix terminal - After setting the non-Mono variant in GNOME Tweaks, wide spacing issue is resolved but icons and glyphs look bigger than "Mono" variant
Screenshot from 2021-03-21 23-14-07

kitty terminal - Solved the issue after setting "adjust_column_width" to "-1" in kitty's config file. Using the "Mono" variant, icon's size is correct
Screenshot from 2021-03-21 23-31-00

@Finii
Copy link
Collaborator

Finii commented May 14, 2022

Examined this after creating #830

In Roboto there are some 'special' glyphs that are 'wider than normal' in the original font.
These are for example Eth Ð , Dcroat ď and ldot ŀ.

image

The Nerd Font Mono variant takes the widest glyph and makes the font 'really monospaced', thus it needs to increase the 'normal' glyph's width.

We could exclude these specific glyphs, like in #830, but it is not so obvious if that is the right thing to do.

Edit: Add example image

@Finii
Copy link
Collaborator

Finii commented May 14, 2022

Eth and Dcroat have some negative bearing, but not enough to keep the width constant.

image

I think this is a font specific quirk, they call themselves mono 🙄

@delinx
Copy link

delinx commented Aug 9, 2022

Any updates on this? I really love the font, but it's unusable as is, could someone make a version with forced char width even if it breaks some characters? Sorry, I am a total noob about the process, just trying to get the font working.

UPDATE

So I modified the patcher script on lines 662 and 664 to be

if self.font_dim['width'] < self.sourceFont[glyph].width:   
    self.font_dim['width'] = 1230   
if xmax > self.font_dim['xmax']:   
    self.font_dim['xmax'] = 1230   

If you modify it to be a constant value, you can get very close through trial and error, and you can get pretty good results, certainly good enough for me, it's a quick hack, and I only post it here for other strugglers who search for RobotoMono in issues

Image of the result

Thank you guys for creating a fantastic tool

@Finii
Copy link
Collaborator

Finii commented Aug 15, 2022

Maybe we should add a font specific handling for the too-wide-chars, so that at least the release fonts are ok?

@Finii
Copy link
Collaborator

Finii commented Jan 28, 2023

Fixed by #1062

@Finii Finii closed this as completed Jan 28, 2023
@github-actions
Copy link
Contributor

This issue has been automatically locked since there has not been any recent activity (i.e. last half year) after it was closed. It helps our maintainers focus on the active issues. If you have found a problem that seems similar, please open a new issue, complete the issue template with all the details necessary to reproduce, and mention this issue as reference.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 31, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants