-
Notifications
You must be signed in to change notification settings - Fork 3.7k
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
patched font variants (bold, semibold etc) show up as duplicate in fontbook osx #56
Comments
I reported this in #25 which appeared to be fixed, but I didn't actually have a chance to test it because I stopped using the install script in favour of manually installing just the font I use... Would love to see this resolved though! |
Yes this should be fixed.. thanks for the details here. I don't have a mac to test on but perhaps I can setup a test branch where others can try it out 😄 |
Which, I must say - this project is LEGIT. Really thankful for it! |
Err I apologize for not making my point clear. 😊 What I meant here was that this should get fixed not that it already was fixed. i.e. Yes this is still a problem AFAIK 👍 I will be leaving this ticket open until someone can confirm an attempted fix 😄
Thanks! That means a lot |
I will be pushing up a test branch that should address this issue. Maybe even as early as tomorrow if I get time. I will link to it on this ticket when I do. Thanks |
@ryanoasis I think this is an issue with FontForge not giving scripts access to font style names (fontforge/fontforge#1061) and relying on autogessing style. Hence you get very strange styles in your fonts such as After I've used your script to generate the required fonts the only perfect solution to the naming mess I've found was to use FontLab
Then, you'd get the following clean names (based on Source Code Medium Italic) No more naming conflicts, no more "NerdFontComplete" in drop-down menus in apps! I think it might be even possible as is if you can try to guess a style name from a file name or font properties and try to trick FontForge into reading a specially constructed full name (with a hyphen separating name from style) to write the correct style name, but I don't know how FontForge autoguess is working |
Actually, was wrong about FontForge not allowing scripting access to all the names — that github ticket threw me off. The |
@eugenesvk Yep! I was aware of the Thank you for the detailed info I think it is helpful 👍 I think at some point adding configuration files to denote the subfont/style name might be needed. Because some fonts have it after the dash in the filename as a convention but some don't. Also some fonts have the incorrect Styles (SubFamily) when viewed in FontForge (e.g. SourceCodePro-ExtraLight.ttf) as shown below: WIP Changes preview: particularly of note: |
Yeah, Source Code is unfortunately a mess in this regard (I also had to change all the font names for these fonts to be correctly reflected in e.g. ST3 — didn't understand why the same name would work on Mac, but fail to work on a Windows, then realized the font names are inconsistent). Thanks for the gist — I'm also trying to adjust exactly this so that I don't have to do any manual changes, so it's helpful to see what you've done. And just to reiterate — to me the default FontLab options I've described above are ideal, so I'd suggest you follow them in your scripts as well (overwriting the default Source Code mess, for example), but of course it's up to you. |
I'd also suggest in the output to write OpenType names in addition to the regular ones, as they have a priority (e.g. Mac would display OpenType names over regular ones on conflict, think same is true for Windows, but haven't checked) A quick reference table from my script (names in comments are from FontLab)
And just FYI similar reference re. default naming functions (FF) is FontForge app names
P.S. Just realized during testing that FontForge introduces another layer of useless quadruplication — the |
Did not know this thanks!
Nice. I think I even overlooked that in the screenshot I posted 😊 . Yes I think this makes sense and I this seems like the logic to go with here.
Sorry I did read your suggestion but have not really gone through it in detail. Just FYI the gist I posted was work done before any of your messages so the new information you have provided will help me greatly in making this patcher 'do the right thing'. 👍
Also as you mentioned in #58, this one is the only one I am still not sure on. I will reply there |
That's what I got from that Adobe document
.
I'm basically arguing for three key principles:
Re. #58 — while thinking about shorter names, don't forget about the larger point of reducing ~36 combinations to 2 :) |
Good stuff thanks again. Yeah I think I am in agreement with you on all 3 of the main points as you described them. #58 - yeah that is definitely something to consider. Also claiming a bunch of font variations is a bit deceiving if most of them aren't very useful 😝 |
Just noticed this thread after I created #61, hopefully it's a start towards solving this? |
@jrolfs Yes and I replied on #61, seems like your work at least will help solve. I might have a bit of conflict with https://gist.github.com/ryanoasis/af51f008838aaa46fb61 but I think I soon need to setup a test branch for us to check how the fonts come out. |
I have run into a variant of this issue as well. The script seems to assume the font name is the same as the family name. While the font's I have generated are now organized correctly in Font Book, all variants are generated with the same font name, and Font Book interprets them as Duplicates. The proper method I have found (at least on OS X) is for the style to be included in the font name ("OperatorMonoItalic", for instance). |
Thanks I think we are getting close to getting this fixed now. You are correct it seems that the font name needs the style to identify it properly as a separate font variant. If you want (and it would be a great help!) you can try patching with the 0.7.0 branch because it seems to be solving most of the issues so far at least. |
Preserve Icon Settings Across Locales. Fixes ryanoasis#56.
Similar / related issue: Fontname: Example-ReguarItalic When I generate an .otf file and open it in Fontbook, the font is shown within Example as 'Regular' rather than RegularItalic, meaning it conflicts with the genuine Regular (non-italic) face. |
I'm having similar issues still in the sense that I have several weights of fonts with italics versions however all of the italics get assigned the Bold weight for some reason |
@ryanoasis its a bit weird since i mean the font gets actually rendered and you can select it but it will look like other weight. So even if it says its the light font it will show as bold 🤔 |
also forgot to add, yeah the bug happens only after patching |
@Mike3run Oh! So it's not an issue with some showing up or not showing up as selectable but how the style is rendered? I wonder if the same thing would happen for you with for instance with Hasklug (Hasklig). It seems to render the correct style/weight for me on Linux: |
So you can see on the right I have all the fonts + italic versions but when imported on the italic ones only the light shows up. On my laptop the same installed fonts make only the bold one show up as italic |
Thanks, this might take some more digging 😟 |
If your system is affected by this, note that having the fonts that Font Book flags as duplicates (i.e.more than a single Italic variant) active will crash iterm2 if you try to set any font from the family in use. Disabling all italic variants but one will resolve the issue. |
But then you wouldn't have bold support :((((((((((( |
I'm not happy without bold italic support, but I'd rather have the icons at all than it. ... But as this issue is happening on 1.2.0 still, it might need to be reopened? ( @ryanoasis ? ) |
Going to reopen because:
Thanks @zxaos for getting this back to visibility for me. I don't know if this will be apart of the next release or not. Goal of 1 per month has been severely lagging. Need to revisit methodology perhaps |
Maybe we can make some traction on this again this month. I won't be able to test any potential fixes but I could upload zips if others (who are on macos) can test them out? |
@ryanoasis Can do! Thanks for looking into it, happy to help with testing out fixes |
+1 this issue is still happening. |
Here's the manual solution to the problem: #257 (comment) @ryanoasis I think it's just a matter of having better Fontname generators that output shorter names. |
I know this has fallen off the radar. Trying to come up with better system to keep up with the issues |
This is implemented/solved since |
For example Operator Mono normally comes in 8 styles that FontBook recognizes as a single font:
Patching it with Could this be reopened since it's still not fixed? |
Thanks for the feedback. I assume you self patched, but which fonts? The ones currently in this repo, i.e. at master/HEAD? |
Ah, Now examining the names Zoom into the family names:
Ok, I'll examine. |
Should be fixed with 3.0.0 |
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. |
* this is at least a partial untested/unverified start to the fix * this will probably also include at least some part of Pull Request ryanoasis#61
…ryanoasis#61) * restores part of logic from PR ryanoasis#61 from @jrolfs but slightly modified to work after them merge
Installing multiple font variants (bold, semibold, light, etc) on OSX using fontbook results in warnings and the font variants are all in separate "font families" ..
I tried installing multiple patched fonts (both Hack and Source Code Pro) so that should rule out that a single patched font is causing the issue.
As can be seen in the screenshot, multiple font families are created for the font variants while I expect a single font family named Sauce Code Pro containing all the variants. Also all the fonts are named: "NerdFontCompleteMono"
I hope we can sort this out because I really want to use the awesome glyphs in my setup
The text was updated successfully, but these errors were encountered: