Create a gist now

Instantly share code, notes, and snippets.

Embed
What would you like to do?
vim-powerline patched fonts
This file has been truncated, but you can view the full file.
@alexyoung

This comment has been minimized.

Show comment
Hide comment
@alexyoung

alexyoung Jan 13, 2012

Awesome to the max

alexyoung commented Jan 13, 2012

Awesome to the max

@endel

This comment has been minimized.

Show comment
Hide comment
@endel

endel Jan 14, 2012

Awesome! Can you provide Monaco patched font too?

endel commented Jan 14, 2012

Awesome! Can you provide Monaco patched font too?

@daqing

This comment has been minimized.

Show comment
Hide comment
@daqing

daqing Jan 14, 2012

+1 for patched Monaco

daqing commented Jan 14, 2012

+1 for patched Monaco

@victorpimentel

This comment has been minimized.

Show comment
Hide comment
@victorpimentel

victorpimentel commented Jan 14, 2012

Thank you :D

@suvash

This comment has been minimized.

Show comment
Hide comment
@suvash

suvash Jan 15, 2012

this is great, but what are the fontnames to be use on the vimrc file ? rather confused.

suvash commented Jan 15, 2012

this is great, but what are the fontnames to be use on the vimrc file ? rather confused.

@victorpimentel

This comment has been minimized.

Show comment
Hide comment
@victorpimentel

victorpimentel Jan 15, 2012

@suvash These fonts need to be installed in your machine, and then selected as your terminal font. You have to change nothing in your .vimrc (well, you need to activate the "fancy" mode, as the documentation says).

victorpimentel commented Jan 15, 2012

@suvash These fonts need to be installed in your machine, and then selected as your terminal font. You have to change nothing in your .vimrc (well, you need to activate the "fancy" mode, as the documentation says).

@suvash

This comment has been minimized.

Show comment
Hide comment
@suvash

suvash Jan 15, 2012

Thanks a lot, and also found the trick for non-terminal vim(I use MacVim occasionally).

if has('gui_running')
  set guifont=Monaco:h12    " set fonts for gui vim
  set transparency=5        " set transparent window
  set guioptions=egmrt  " hide the gui menubar
endif

suvash commented Jan 15, 2012

Thanks a lot, and also found the trick for non-terminal vim(I use MacVim occasionally).

if has('gui_running')
  set guifont=Monaco:h12    " set fonts for gui vim
  set transparency=5        " set transparent window
  set guioptions=egmrt  " hide the gui menubar
endif
@sjl

This comment has been minimized.

Show comment
Hide comment
@sjl

sjl Jan 17, 2012

If you want a version of Menlo that includes bold, italic, and bold italic: https://gist.github.com/1627888

sjl commented Jan 17, 2012

If you want a version of Menlo that includes bold, italic, and bold italic: https://gist.github.com/1627888

@blissdev

This comment has been minimized.

Show comment
Hide comment
@blissdev

blissdev Jan 18, 2012

Wish there was a Consolas patch.. :)

blissdev commented Jan 18, 2012

Wish there was a Consolas patch.. :)

@qrush

This comment has been minimized.

Show comment
Hide comment
@qrush

qrush Jan 18, 2012

Folks, I'm not going to provide any more patched fonts. I did the 3 up there for myself and a friend. Download vim-powerline, check out the readme, and get it working like I did if you want it with your own font.

Owner

qrush commented Jan 18, 2012

Folks, I'm not going to provide any more patched fonts. I did the 3 up there for myself and a friend. Download vim-powerline, check out the readme, and get it working like I did if you want it with your own font.

@goatslacker

This comment has been minimized.

Show comment
Hide comment
@goatslacker

goatslacker Jan 19, 2012

Thanks for providing the fonts! I owe you a 🍺

goatslacker commented Jan 19, 2012

Thanks for providing the fonts! I owe you a 🍺

@mbadran

This comment has been minimized.

Show comment
Hide comment
@mbadran

mbadran Jan 20, 2012

Unrelated noob question: how do you attach a binary font file (ttf) to a gist? I patched Meslo DZ and I want to make it available.

mbadran commented Jan 20, 2012

Unrelated noob question: how do you attach a binary font file (ttf) to a gist? I patched Meslo DZ and I want to make it available.

@sjl

This comment has been minimized.

Show comment
Hide comment
@sjl

sjl Jan 20, 2012

sjl commented Jan 20, 2012

@ghost

This comment has been minimized.

Show comment
Hide comment
@ghost

ghost Jan 26, 2012

When using your patched Inconsolata font, and Powerline_symbols set to fancy, I get boxes instead of the patched characters. Here's a screenshot:

broken powerline status bar font

Is there a setting I'm missing, or is the font not working correctly? All my settings seem to be set to UTF-8 and using urxvt.

Edit: I've tried another font from the wiki, and it seems to work. This tells me the font you provide might not be functional.

ghost commented Jan 26, 2012

When using your patched Inconsolata font, and Powerline_symbols set to fancy, I get boxes instead of the patched characters. Here's a screenshot:

broken powerline status bar font

Is there a setting I'm missing, or is the font not working correctly? All my settings seem to be set to UTF-8 and using urxvt.

Edit: I've tried another font from the wiki, and it seems to work. This tells me the font you provide might not be functional.

@goatslacker

This comment has been minimized.

Show comment
Hide comment
@goatslacker

goatslacker Jan 26, 2012

@clownfart rm /tmp/Powerline.cache

goatslacker commented Jan 26, 2012

@clownfart rm /tmp/Powerline.cache

@ghost

This comment has been minimized.

Show comment
Hide comment
@ghost

ghost Jan 26, 2012

@goatslacker that isn't a file. I've tried :PowerlineClearCache as well.

Edit: I was able to patch my own font, but the glyphs have a lower line height than Inconsolata-dz has. I will try with normal Inconsolata.

ghost commented Jan 26, 2012

@goatslacker that isn't a file. I've tried :PowerlineClearCache as well.

Edit: I was able to patch my own font, but the glyphs have a lower line height than Inconsolata-dz has. I will try with normal Inconsolata.

@martin-damien

This comment has been minimized.

Show comment
Hide comment
@martin-damien

martin-damien Jan 28, 2012

Thank you very much for those patched fonts. It saved my life (not able to compile on my MAC).

martin-damien commented Jan 28, 2012

Thank you very much for those patched fonts. It saved my life (not able to compile on my MAC).

@jojojames

This comment has been minimized.

Show comment
Hide comment
@jojojames

jojojames Feb 4, 2012

Font doesn't display correct in gvim, everything has wide spacings. Can anyone help?

jojojames commented Feb 4, 2012

Font doesn't display correct in gvim, everything has wide spacings. Can anyone help?

@niklas

This comment has been minimized.

Show comment
Hide comment
@niklas

niklas May 24, 2012

@6msj vim did not find the font. Try the following in your .vimrc:

set guifont=Inconsolata-dz\ for\ Powerline\ Medium\ 12

niklas commented May 24, 2012

@6msj vim did not find the font. Try the following in your .vimrc:

set guifont=Inconsolata-dz\ for\ Powerline\ Medium\ 12

@cutemachine

This comment has been minimized.

Show comment
Hide comment
@cutemachine

cutemachine May 26, 2012

Excellent. Many Thanks.

cutemachine commented May 26, 2012

Excellent. Many Thanks.

@teoljungberg

This comment has been minimized.

Show comment
Hide comment
@teoljungberg

teoljungberg Jun 17, 2012

My statusline looks strange with the Inconsolata font. This is in vim inside iTerm. It works just fine with MacVim

http://cl.ly/1M1C2T161E2D2S0f0w17

Have anyone got any idea?

teoljungberg commented Jun 17, 2012

My statusline looks strange with the Inconsolata font. This is in vim inside iTerm. It works just fine with MacVim

http://cl.ly/1M1C2T161E2D2S0f0w17

Have anyone got any idea?

@bmcorser

This comment has been minimized.

Show comment
Hide comment
@bmcorser

bmcorser Jun 22, 2012

I just downloaded Mensch and this is crazy.

bmcorser commented Jun 22, 2012

I just downloaded Mensch and this is crazy.

@supr

This comment has been minimized.

Show comment
Hide comment
@supr

supr Jul 3, 2012

@metamorfos i think you might have to increase the size of your status bar.

supr commented Jul 3, 2012

@metamorfos i think you might have to increase the size of your status bar.

@teoljungberg

This comment has been minimized.

Show comment
Hide comment
@teoljungberg

teoljungberg Jul 3, 2012

@metamorfos i think you might have to increase the size of your status bar.

that, amongst other things, did it @supr

teoljungberg commented Jul 3, 2012

@metamorfos i think you might have to increase the size of your status bar.

that, amongst other things, did it @supr

@J-Swift

This comment has been minimized.

Show comment
Hide comment
@J-Swift

J-Swift Sep 1, 2012

I had the same issue as metamorfos (using terminal vim and iTerm2) and found 2 ways to fix it. One, you can choose a different font. Two, you can mess with the vertical line height of the terminal font. Hope that helps someone.

J-Swift commented Sep 1, 2012

I had the same issue as metamorfos (using terminal vim and iTerm2) and found 2 ways to fix it. One, you can choose a different font. Two, you can mess with the vertical line height of the terminal font. Hope that helps someone.

@dz

This comment has been minimized.

Show comment
Hide comment
@dz

dz Sep 13, 2012

Thanks much for the inconsolata-dz patch! :) I love powerline.

dz commented Sep 13, 2012

Thanks much for the inconsolata-dz patch! :) I love powerline.

@davidchambers

This comment has been minimized.

Show comment
Hide comment
@davidchambers

davidchambers Sep 27, 2012

I just patched Inconsolata (after battling to get fontforge to compile). I made the following tweak to get the arrows to line up perfectly:

diff --git a/fontpatcher/fontpatcher b/fontpatcher/fontpatcher
index 2c54a3f..6e75838 100755
--- a/fontpatcher/fontpatcher
+++ b/fontpatcher/fontpatcher
@@ -177,7 +177,7 @@ for font_path in args.fonts:
        font.transform(psMat.translate(0, font_dim['ymax'] - sym_dim['ymax']))

        # Then move it the y center difference
-       font.transform(psMat.translate(0, sym_ycenter - font_ycenter))
+       font.transform(psMat.translate(0, sym_ycenter - font_ycenter - 66))

        # Ensure that the glyph doesn't extend outside the font's bounding box
        if sym_dim['width'] > font_dim['width']:

davidchambers commented Sep 27, 2012

I just patched Inconsolata (after battling to get fontforge to compile). I made the following tweak to get the arrows to line up perfectly:

diff --git a/fontpatcher/fontpatcher b/fontpatcher/fontpatcher
index 2c54a3f..6e75838 100755
--- a/fontpatcher/fontpatcher
+++ b/fontpatcher/fontpatcher
@@ -177,7 +177,7 @@ for font_path in args.fonts:
        font.transform(psMat.translate(0, font_dim['ymax'] - sym_dim['ymax']))

        # Then move it the y center difference
-       font.transform(psMat.translate(0, sym_ycenter - font_ycenter))
+       font.transform(psMat.translate(0, sym_ycenter - font_ycenter - 66))

        # Ensure that the glyph doesn't extend outside the font's bounding box
        if sym_dim['width'] > font_dim['width']:
@colemickens

This comment has been minimized.

Show comment
Hide comment
@colemickens

colemickens Sep 29, 2012

Love to see this for Adobe's new Source Code Pro.

colemickens commented Sep 29, 2012

Love to see this for Adobe's new Source Code Pro.

@joshmosh

This comment has been minimized.

Show comment
Hide comment
@joshmosh

joshmosh Oct 5, 2012

  • 1 for Monaco

joshmosh commented Oct 5, 2012

  • 1 for Monaco
@ruaz

This comment has been minimized.

Show comment
Hide comment
@ruaz

ruaz Nov 26, 2012

@davidchambers Excellent work, thank you! Finally, I have a decent looking status bar.

ruaz commented Nov 26, 2012

@davidchambers Excellent work, thank you! Finally, I have a decent looking status bar.

@hit9

This comment has been minimized.

Show comment
Hide comment
@hit9

hit9 Jan 1, 2013

cool, i like it !

hit9 commented Jan 1, 2013

cool, i like it !

@zhm

This comment has been minimized.

Show comment
Hide comment
@zhm

zhm Feb 11, 2013

I ended up having to make some tweaks to the fontpatcher script to get Inconsolata-dz to line up perfectly in MacVim.

Here is my font file for anyone else who stumbles upon this: http://cl.ly/3Q362Q2M1e1h

Enabled using set guifont=Inconsolata-dz\ for\ Powerline:h13

Here are my changes to the fontpatcher script:

diff --git a/fontpatcher/fontpatcher b/fontpatcher/fontpatcher
index 2c54a3f..4826d9d 100755
--- a/fontpatcher/fontpatcher
+++ b/fontpatcher/fontpatcher
@@ -164,7 +164,7 @@ for font_path in args.fonts:
                        # Stretch the glyph vertically
                        scale_ratio = font_dim['height'] / sym_dim['height']

-                       font.transform(psMat.scale(1, scale_ratio))
+                       font.transform(psMat.scale(1, scale_ratio * 1.3))

                # Use the dimensions from the pasted and stretched glyph
                sym_dim = get_dim(font[sym_glyph.unicode])
@@ -177,7 +177,7 @@ for font_path in args.fonts:
                font.transform(psMat.translate(0, font_dim['ymax'] - sym_dim['ymax']))

                # Then move it the y center difference
-               font.transform(psMat.translate(0, sym_ycenter - font_ycenter))
+               font.transform(psMat.translate(0, sym_ycenter - font_ycenter + 60))

                # Ensure that the glyph doesn't extend outside the font's bounding box
                if sym_dim['width'] > font_dim['width']:

zhm commented Feb 11, 2013

I ended up having to make some tweaks to the fontpatcher script to get Inconsolata-dz to line up perfectly in MacVim.

Here is my font file for anyone else who stumbles upon this: http://cl.ly/3Q362Q2M1e1h

Enabled using set guifont=Inconsolata-dz\ for\ Powerline:h13

Here are my changes to the fontpatcher script:

diff --git a/fontpatcher/fontpatcher b/fontpatcher/fontpatcher
index 2c54a3f..4826d9d 100755
--- a/fontpatcher/fontpatcher
+++ b/fontpatcher/fontpatcher
@@ -164,7 +164,7 @@ for font_path in args.fonts:
                        # Stretch the glyph vertically
                        scale_ratio = font_dim['height'] / sym_dim['height']

-                       font.transform(psMat.scale(1, scale_ratio))
+                       font.transform(psMat.scale(1, scale_ratio * 1.3))

                # Use the dimensions from the pasted and stretched glyph
                sym_dim = get_dim(font[sym_glyph.unicode])
@@ -177,7 +177,7 @@ for font_path in args.fonts:
                font.transform(psMat.translate(0, font_dim['ymax'] - sym_dim['ymax']))

                # Then move it the y center difference
-               font.transform(psMat.translate(0, sym_ycenter - font_ycenter))
+               font.transform(psMat.translate(0, sym_ycenter - font_ycenter + 60))

                # Ensure that the glyph doesn't extend outside the font's bounding box
                if sym_dim['width'] > font_dim['width']:
@dvcrn

This comment has been minimized.

Show comment
Hide comment
@dvcrn

dvcrn Jun 26, 2013

Can someone update these fonts to the new code points? robbyrussell/oh-my-zsh#1872

dvcrn commented Jun 26, 2013

Can someone update these fonts to the new code points? robbyrussell/oh-my-zsh#1872

@justin8

This comment has been minimized.

Show comment
Hide comment
@justin8

justin8 Jul 6, 2013

You can get the menlo patched font at least from my dotfiles here:
https://github.com/justin8/dotfiles/tree/master/install-files/fonts

I couldn't find a decent font with the new code points, so I ripped the menlo ttc from OS X and patched it.

justin8 commented Jul 6, 2013

You can get the menlo patched font at least from my dotfiles here:
https://github.com/justin8/dotfiles/tree/master/install-files/fonts

I couldn't find a decent font with the new code points, so I ripped the menlo ttc from OS X and patched it.

@kevinrenskers

This comment has been minimized.

Show comment
Hide comment
@kevinrenskers

kevinrenskers Jul 12, 2013

The best source for the updated fonts seems to be https://github.com/Lokaltog/powerline-fonts

kevinrenskers commented Jul 12, 2013

The best source for the updated fonts seems to be https://github.com/Lokaltog/powerline-fonts

@tgy

This comment has been minimized.

Show comment
Hide comment
@tgy

tgy Nov 6, 2013

@justin8 your Menlo font is not working

Can someone provide a Menlo patched font please ?

tgy commented Nov 6, 2013

@justin8 your Menlo font is not working

Can someone provide a Menlo patched font please ?

@monokrome

This comment has been minimized.

Show comment
Hide comment
@monokrome

monokrome Feb 9, 2014

@Toogy Not sure if this works for you, but this copy of Menlo seems to have solved the problem for myself.

monokrome commented Feb 9, 2014

@Toogy Not sure if this works for you, but this copy of Menlo seems to have solved the problem for myself.

@mtalebi

This comment has been minimized.

Show comment
Hide comment
@mtalebi

mtalebi Mar 7, 2014

I don't know if this helps anyone else, try changing your iTerm's profile to Pastel (Dark Background). It fixed the icon display issue for me. My terminal now looks exactly like http://www.paradox.io/posts/9-my-new-zsh-prompt. FYI, I did install the above fonts.

mtalebi commented Mar 7, 2014

I don't know if this helps anyone else, try changing your iTerm's profile to Pastel (Dark Background). It fixed the icon display issue for me. My terminal now looks exactly like http://www.paradox.io/posts/9-my-new-zsh-prompt. FYI, I did install the above fonts.

@phaberest

This comment has been minimized.

Show comment
Hide comment
@phaberest

phaberest May 8, 2014

Superlative work!

phaberest commented May 8, 2014

Superlative work!

@trusktr

This comment has been minimized.

Show comment
Hide comment
@trusktr

trusktr Dec 27, 2014

These fonts don't seem to work? I just installed these, along with Prezto, then when I choose one of these fonts in iTerm2, the font changes in the terminal, but the ugly symbols remain (I don't see the nice powerline triangles).

trusktr commented Dec 27, 2014

These fonts don't seem to work? I just installed these, along with Prezto, then when I choose one of these fonts in iTerm2, the font changes in the terminal, but the ugly symbols remain (I don't see the nice powerline triangles).

@marbon87

This comment has been minimized.

Show comment
Hide comment
@marbon87

marbon87 Mar 12, 2015

I have the same problem as trukstr. I installed the fonts from https://github.com/powerline/fonts but not all icons are shown correctly

marbon87 commented Mar 12, 2015

I have the same problem as trukstr. I installed the fonts from https://github.com/powerline/fonts but not all icons are shown correctly

@ghost

This comment has been minimized.

Show comment
Hide comment
@ghost

ghost Jul 12, 2015

Thank you!

ghost commented Jul 12, 2015

Thank you!

@topdown

This comment has been minimized.

Show comment
Hide comment
@topdown

topdown Jun 16, 2016

Once you go through the font installation you need to set the fonts in whatever you are using for that profile.
For me it was iTerm2 on latest Mac OSx
Go to preferences > select the profile you are using > Text tab
Now set both the Font and Non-ASCII Font to one the ends in Powerline.
screen shot 2016-06-16 at 1 35 32 pm

If there are not fonts that end in Powerline it is not installed correctly.
Frankly with all of the issues I was surprised I got it to work in 2016 :)

screen shot 2016-06-16 at 1 34 55 pm

topdown commented Jun 16, 2016

Once you go through the font installation you need to set the fonts in whatever you are using for that profile.
For me it was iTerm2 on latest Mac OSx
Go to preferences > select the profile you are using > Text tab
Now set both the Font and Non-ASCII Font to one the ends in Powerline.
screen shot 2016-06-16 at 1 35 32 pm

If there are not fonts that end in Powerline it is not installed correctly.
Frankly with all of the issues I was surprised I got it to work in 2016 :)

screen shot 2016-06-16 at 1 34 55 pm

@sghiassy

This comment has been minimized.

Show comment
Hide comment

sghiassy commented Oct 4, 2016

@Yammmy

This comment has been minimized.

Show comment
Hide comment
@Yammmy

Yammmy commented Dec 6, 2016

Thx :)

@suilu

This comment has been minimized.

Show comment
Hide comment
@suilu

suilu Dec 15, 2016

Thank you!

suilu commented Dec 15, 2016

Thank you!

@freehuntman

This comment has been minimized.

Show comment
Hide comment
@freehuntman

freehuntman commented Jan 5, 2017

awesome~

@mrleblanc101

This comment has been minimized.

Show comment
Hide comment
@mrleblanc101

mrleblanc101 Oct 1, 2017

@topdown What's the bullet and the plus sign after the branch name ? I don't have this using the exact same theme but with SourceCode Pro for Powerline ?

mrleblanc101 commented Oct 1, 2017

@topdown What's the bullet and the plus sign after the branch name ? I don't have this using the exact same theme but with SourceCode Pro for Powerline ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment