- Removed *args: segments are not receiveing any non-keyword arguments so no
need to bother with *args at all.
- Replaced additional_cache_key with cache_key: all functions that formerly used
additional_cache_key appear not to need initial arguments as cache keys. It
also simplifies the code.
- Made _cache be defined in __init__, it is much easier to implement cache
purging this way.
Ref #205Fixes#208
Allows more precise icon selection and purges out unicode characters from
configuration.
Note: windy icon needs reworking, I used a trigram for it.
Fixes#203.
API changes done:
- memoize additional_key function now accepts all function arguments
- get_theme now receives matcher_info
- render now receives segment_info and matcher_info, but segments and themes
were removed
- due to very different ways of obtaining column information col_current
splitted back to col_current and virtcol_current. The former should be false
in case of horizontal scrollbind (when &scrollopt contains hor)
- added requires_segment_info decorator for convenience
Other changes:
- removed all vim function calls that were possible to remove
- removed direct vim.eval calls
This is faster then super() calls and also more convenient.
Fixes#142 just as well
Conflicts:
powerline/renderers/bash_prompt.py
powerline/renderers/ipython.py
powerline/renderers/shell.py
powerline/renderers/zsh_prompt.py
What does hl() mean? It looks like “highlight an empty string”, but is actually
“reset highlight style”. In addition if you are writing “hl()” function for new
renderer you need to care about “contents” variable (in two places!: None for
super() call and (contents or u'') after super() call) though function is
actually doing nothing with it. It is just inconvenient.
Several of the plugin loading methods have been joined into one plugin
file that will be loaded by updating the runtimepath. More informative
error messages will be displayed if Python support is missing or if the
module import fails.
Note that this commit will break existing plugin loading, the new
method with updating the runtimepath will be required.
Closes#156.
Closes#181.
Because vim doesn't trigger any autocmds after leaving a cmdwin the
statusline in the window the user returned to from the cmdwin would be
highlighted as non-current even if it should have been current.
This issue is resolved by storing the last current window ID in a script
variable, and when leaving the cmdwin we show the last current window as
current instead of detecting it after the WinEnter autocmd has been
triggered (which doesn't happen after leaving a cmdwin).
Closes#184.