dqisme / Hactor

A font alternative to Operator Mono by combination of Hack and Victor Mono.
MIT License
31 stars 0 forks source link

Font Weight problem #1

Open Shaglock opened 3 years ago

Shaglock commented 3 years ago

Hello! I have installed this font and when I am using it in VSCode it feels like font-weight is bold and I can't change it through editor.fontWeight. Maybe I'm doing something wrong? I'm attaching screenshots of my before\after changing to Hactor.

image image image

dqisme commented 3 years ago

Hey, thanks for raising problems. I tried to reproduce the issue you posted here. First, would you please try with the fontWeight as bold? Because in general 100 means lighter than the normal (you can learn here). Second, please make sure you have installed all the font files in your system. There should be 4 files in total (2 for normal and 2 for bold). And also the thickness is different between two fonts, even they are all in normal weight.

Shaglock commented 3 years ago

Hey! Thanks for your response.

First, would you please try with the fontWeight as bold? Because in general 100 means lighter than the normal (you can learn here).

I tried every possible value, nothing changes.

Second, please make sure you have installed all the font files in your system. There should be 4 files in total (2 for normal and 2 for bold).

Fonts are definitely installed in my system, and they work in VSCode (italic comments works exactly as your screenshot)

$ fc-list | grep Hactor
/home/shaglock/.fonts/Hactor-Bold-Italic.ttf: Hactor:style=Bold Italic
/home/shaglock/.fonts/Hactor-Regular.ttf: Hactor:style=Regular
/home/shaglock/.fonts/Hactor-Italic.ttf: Hactor:style=Italic
/home/shaglock/.fonts/Hactor-Bold.ttf: Hactor:style=Bold

image I tried installing in several ways, but it does not help with this issue.

And also the thickness is different between two fonts, even they are all in normal weight.

I understand that, but this font is really bolder than other fonts. I saw similar issues with Cascadia Code font (https://github.com/microsoft/cascadia-code/issues/25), maybe this is kind of the same issue. Even in your screenshot in README font is way lighter than mine.

lfom commented 3 years ago

I also think that there is a problem, please see the picture below (picking font in latest Gedit):

Screenshot from 2020-07-24 18-16-24

Shaglock commented 3 years ago

I also think that there is a problem, please see the picture below (picking font in latest Gedit):

Screenshot from 2020-07-24 18-16-24

Yeah, same problem Regular looks like Bold. But you have 2 bold versions and 2 bold italic for some reason.

lfom commented 3 years ago

Yes, I noticed that too. But I have installed only the 4 (four) TTF files provided by @dqisme. Yesterday I tried to fix that with FonfForge but I wasn't successful. I don't know much about font design/creation, so hopefully someone can fix this issue. I think it is related to the font weight problem, all of them use "medium" as weight value.

lfom commented 3 years ago

I think I have found the problem: all the files are set as medium and weight (500). Then I changed to the same settings as the original Hack files using FontForge: Regular and Italic to Book and Regular (400), and Bold and Bold Italic to Bold and Bold (700) and it is working fine here. Screenshots for the Regular font:

Screenshot from 2020-08-03 04-38-58 Screenshot from 2020-08-03 04-42-47

Shaglock commented 3 years ago

I think I have found the problem: all the files are set as medium and weight (500). Then I changed to the same settings are the original Hack files using FontForge: Regular and Italic to Book and Regular (400), and Bold and Bold Italic to Bold and Bold (700). Screenshots for the Regular font:

Thank you for your investigation, I will try to apply the same fix to my PC later this week.

dqisme commented 3 years ago

Thank you for the solution. I will update all the files to the repository as well.


From: Ilya Shaplyko notifications@github.com Sent: Monday, August 3, 2020 12:33:12 PM To: dqisme/Hactor Hactor@noreply.github.com Cc: DQ dqisme@outlook.com; Mention mention@noreply.github.com Subject: Re: [dqisme/Hactor] Font Weight problem (#1)

I think I have found the problem: all the files are set as medium and weight (500). Then I changed to the same settings are the original Hack files using FontForge: Regular and Italic to Book and Regular (400), and Bold and Bold Italic to Bold and Bold (700). Screenshots for the Regular font:

Thank you for your investigation, I will try to apply the same fix to my PC later this week.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/dqisme/Hactor/issues/1#issuecomment-667947095, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ACX77GKAMFI5D35XQDUWO7TR62G6RANCNFSM4ORSTIWQ.

lfom commented 3 years ago

Probably Style Map needs to be configured properly too (it is wrong for the files other than Regular):

Screenshot from 2020-08-03 14-54-33

lfom commented 3 years ago

Here are the fonts with the width fixed for Italics and BoldItalics as explained in the README (space & nbspc width=662). I have tested them in VS Code and I didn't see the selection problem (I use a them with comments in italics).

I used the latest versions of both Hack and Victor Mono, and MediumItalic for the Italic version and it seems to be closer to the weigh of Hack Regular. The font is correctly detected as monospace and can be used in a terminal emulator, and even seems to have the powerline glyphs (and a few more in the Hack one).

Fell free to delete this post if you test the font and decide to distribute it.

Hactor-Width-Fixed.zip