nerd-fonts icon indicating copy to clipboard operation
nerd-fonts copied to clipboard

Chrome / Chrome OS support

Open jokerkeny opened this issue 5 years ago • 9 comments

🎯 Subject of the issue

Could you add Chrome / Chrome OS support by creating web fonts version like powerline-web-fonts?

🔧 Your Setup

Font: Droid Sans Mono Nerd Font Terminal: Secure Shell App OS: Chrome OS and Chrome Web Browser on Windows

Screenshot

image

jokerkeny avatar Apr 08 '19 07:04 jokerkeny

This would be useful and it seems doable

ryanoasis avatar Jun 21 '19 04:06 ryanoasis

This would be creating woff and woff2 versions of the fonts. I did create these for the symbols only font but not the all the fonts

ryanoasis avatar Aug 16 '19 04:08 ryanoasis

This would be super helpful. Currently using ChromeOS as well. Having the same problem with native terminal and Hyper.js terminal. However, Gnome Terminal works because it doesn't have to use web fonts for this. Would love to know if there is any progress on this :)

wrightbradley avatar Sep 08 '19 19:09 wrightbradley

Here is a temporary solution.

  • Set a custom CSS(inline text) like this one.
  • Src is the raw file where you can download the font.
@font-face {
    font-family: "DejaVu Sans Mono Nerd";
    src: url("https://raw.githubusercontent.com/ryanoasis/nerd-fonts/master/patched-fonts/DejaVuSansMono/Regular/complete/DejaVu%20Sans%20Mono%20Nerd%20Font%20Complete%20Mono.ttf");
    font-weight: normal;
    font-style: normal;
}

image image

vn7n24fzkq avatar Sep 17 '19 06:09 vn7n24fzkq

Is it possible to add an output to font_patcher for this? (Really wish the complete patched fira code was available in eot/woff/woff2 so I could drop it in as discussed here: https://github.com/tonsky/FiraCode/wiki/ChromeOS-Terminal)

ckrailo avatar Nov 07 '19 09:11 ckrailo

I'm not working on this atm

ryanoasis avatar Feb 02 '20 06:02 ryanoasis

Ctrl+Shift+J to open dev console, input following code to get NERD font support. (tested on ChromeOS 94 Linux terminal)

term_.prefs_.set('font-family', 'DejaVu Sans Mono Nerd');
term_.prefs_.set('user-css-text', '@font-face {font-family: "DejaVu Sans Mono Nerd"; src: url("https://raw.githubusercontent.com/ryanoasis/nerd-fonts/master/patched-fonts/DejaVuSansMono/Regular/DejaVuSansMNerdFont-Regular.ttf"); font-weight: normal; font-style: normal;}')

nwillis avatar Nov 05 '21 08:11 nwillis

Ctrl+Shift+J to open dev console, input following code to get NERD font support. (tested on ChromeOS 94 Linux terminal)

term_.prefs_.set('font-family', 'DejaVu Sans Mono Nerd');
term_.prefs_.set('user-css-text', '@font-face {font-family: "DejaVu Sans Mono Nerd"; src: url("https://raw.githubusercontent.com/ryanoasis/nerd-fonts/master/patched-fonts/DejaVuSansMono/Regular/complete/DejaVu%20Sans%20Mono%20Nerd%20Font%20Complete%20Mono.ttf"); font-weight: normal; font-style: normal;}')

I tried this, but some weird horizontal lines appear when I open NeoVim, and they are quite annoying:

image

Anyone knows how to fix this? I already tried increasing and decreasing the font size, but it doesn't fix it.

neolight1010 avatar Nov 22 '21 20:11 neolight1010

Ctrl+Shift+J to open dev console, input following code to get NERD font support. (tested on ChromeOS 94 Linux terminal)

term_.prefs_.set('font-family', 'DejaVu Sans Mono Nerd');
term_.prefs_.set('user-css-text', '@font-face {font-family: "DejaVu Sans Mono Nerd"; src: url("https://raw.githubusercontent.com/ryanoasis/nerd-fonts/master/patched-fonts/DejaVuSansMono/Regular/complete/DejaVu%20Sans%20Mono%20Nerd%20Font%20Complete%20Mono.ttf"); font-weight: normal; font-style: normal;}')

I tried this, but some weird horizontal lines appear when I open NeoVim, and they are quite annoying:

image

Anyone knows how to fix this? I already tried increasing and decreasing the font size, but it doesn't fix it.

Decrease the "Line height padding size" in the Terminal Settings, under the font size setting.

zakrywilson avatar Feb 09 '22 00:02 zakrywilson

Is it possible to add an output to font_patcher for this?

I do not really know what this is, but when you self patch, just specify -ext woff and that's it.

But having these in the release would double (just woff) or tripple (woff and woff2) the release size. I believe that is not desirable. Plus there are a lot of tools that can convert to woff(2).

Finii avatar Feb 04 '23 11:02 Finii

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[bot] avatar Nov 20 '23 00:11 github-actions[bot]