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

Feature Request: Use all system fonts #19

Open
Phytolizer opened this issue Jun 24, 2020 · 4 comments
Open

Feature Request: Use all system fonts #19

Phytolizer opened this issue Jun 24, 2020 · 4 comments

Comments

@Phytolizer
Copy link

This might result in slower startup time, but I would like the option to shift between all installed monospace fonts instead of having to enumerate them manually in the "includeFontFamilies" config option.

@bmealhouse
Copy link
Owner

Hi @onContentStop, thanks for submitting this issue.

The “includeFontFamilies” config setting was designed mostly for programming fonts developers purchase.

As far as I know, I don’t have access to look at what system monospaced fonts are installed. I could dig into this a bit more to see if anything has changed since the last time I checked. Otherwise, if you have any ideas about how this could be accomplished, please feel free to open a PR.

There is another way to accomplish this without looking at the file system for installed monospace fonts. What fonts are missing and what platform are you using (mac, windows, linux)?

@Phytolizer
Copy link
Author

It's not necessarily that a specific font is missing, but more that it would be a generic solution.

On Linux, you can get this information by running in a shell fc-list :mono family | sed 's/\\-/-/g'.
On Windows it is more complicated, involving reading the registry and getting font metrics with .NET. I don't have an elegant solution for that.

@bmealhouse
Copy link
Owner

Thanks for the suggestion @onContentStop.

I would certainly like to have a more generic solution since it would remove another one of my config settings (ignoreCodefaceFontFamilies) as well. When I have time I will do more research on how this could work across different platforms. The command you mentioned above doesn't work on macOS either.

As I mentioned before, PRs are welcome if you are also interested in digging into this.

@Phytolizer
Copy link
Author

Sure, I'll get to work figuring out how to integrate into your code, then make a Linux implementation at the very least. Unfortunately that nice one-liner I wrote relies on you having fontconfig installed (on Mac, through Homebrew), so it won't work for most OSX machines unless they install that. I can work on a generic Objective-C solution for that though. As for Windows, I still don't know :(

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants