Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Create functionality for overriding dividers

Closes #105.
  • Loading branch information...
commit 295b4c3db61cfbd54eb0ac909a5f1cf6d38461a3 1 parent aa10a1b
Kim Silkebækken authored
5 autoload/Pl/Parser.vim
View
@@ -35,6 +35,11 @@ for [s:key, s:value] in items(g:Powerline_symbols_override)
unlet! s:key s:value
endfor
+" Handle divider overrides
+if len(g:Powerline_dividers_override) == 4
+ let g:Pl#Parser#Symbols[g:Powerline_symbols].dividers = g:Powerline_dividers_override
+endif
+
let s:LEFT_SIDE = 0
let s:RIGHT_SIDE = 2
18 doc/Powerline.txt
View
@@ -26,6 +26,7 @@ CONTENTS *Powerline-contents*
4.3.1 Compatible symbols ....... |Powerline-symbols-compatible|
4.3.2 Fancy symbols ............ |Powerline-symbols-fancy|
4.3.3 Overriding symbols ....... |Powerline_symbols_override|
+ 4.3.4 Overriding dividers ...... |Powerline_dividers_override|
4.4 Powerline_theme ................ |Powerline_theme|
4.5 Powerline_colorscheme .......... |Powerline_colorscheme|
4.6 Powerline_stl_path_style ....... |Powerline_stl_path_style|
@@ -160,7 +161,7 @@ adding the required symbols to any outline font and some bitmap fonts, see
------------------------------------------------------------------------------
4.3.3 Overriding symbols *Powerline_symbols_override*
-You can override single symbols (not dividers) by adding your symbols to the
+You can override symbols by adding your symbols to the
g:Powerline_symbols_override dictionary. Example: If you want the branch
symbol to be "∓" (hex code 0x2213) and the line symbol to be "L" you can add
the following to your |vimrc|: >
@@ -170,6 +171,21 @@ the following to your |vimrc|: >
\ 'LINE': 'L',
\ }
<
+------------------------------------------------------------------------------
+4.3.4 Overriding dividers *Powerline_dividers_override*
+
+If you for some reason want to override the dividers then you can set
+g:Powerline_dividers_override to a list with exactly four elements:
+
+ 1: Hard right-pointing arrow
+ 2: Soft right-pointing arrow
+ 3: Hard left-pointing arrow
+ 4: Soft left-pointing arrow
+
+Example: >
+
+ let g:Powerline_dividers_override = ['>>', '>', '<<', '<']
+<
-----------------------------------------------------------------------------
4.4 Powerline_theme *Powerline_theme*
13 plugin/Powerline.vim
View
@@ -16,12 +16,13 @@
" }}}
" Set default options {{{
for [s:key, s:value] in items({
- \ 'theme' : 'default'
- \ , 'colorscheme' : 'default'
- \ , 'symbols' : 'compatible'
- \ , 'symbols_override': {}
- \ , 'stl_path_style' : 'relative'
- \ , 'cache_enabled' : 1
+ \ 'theme' : 'default'
+ \ , 'colorscheme' : 'default'
+ \ , 'symbols' : 'compatible'
+ \ , 'symbols_override' : {}
+ \ , 'dividers_override': []
+ \ , 'stl_path_style' : 'relative'
+ \ , 'cache_enabled' : 1
\ })
if ! exists('g:Powerline_' . s:key)
Please sign in to comment.
Something went wrong with that request. Please try again.