Commit Graph

1911 Commits

Author SHA1 Message Date
ZyX 68263beec4 Show current buffer, window and tabpage number by default
Fixes #1048
2014-09-05 20:00:21 +04:00
ZyX 42bd619866 Remove `{module}.{function}` default highlighting group
It is both not documented and not supported by linter in any case.
2014-09-05 20:00:21 +04:00
ZyX f916fe819f Use less precise algorythm for width computations under stress
Makes #1047 far less bad
2014-09-05 20:00:20 +04:00
ZyX 60fb311463 Add a way to profile Vim bindings 2014-09-05 20:00:20 +04:00
ZyX d569c0b3dd Skip identical highlighting
Fixes #1049
2014-09-05 20:00:20 +04:00
ZyX 1a5bbbea96 Replace segment-local modes with highlight_group_prefix option
Fixes #1046
2014-09-05 20:00:20 +04:00
ZyX b7504c7178 Do not require using `priority_multiplier` key 2014-09-05 20:00:20 +04:00
ZyX 667cd4bce5 Assume highlight group is always an iterable
According to the documentation and linter `'highlight_group': 'string'` was not
correct even at the current stage, but it worked. This commit fixes this
situation.
2014-09-05 20:00:20 +04:00
ZyX adc08d0cd8 Filter subsegments for segment lister prior to using lister 2014-09-05 20:00:20 +04:00
ZyX 786543c977 Filter None values when computing subsegments for segment listers 2014-09-05 20:00:19 +04:00
ZyX 54e12b1515 Use new functionality to replace tabbuflister and single_tab segment 2014-09-05 20:00:19 +04:00
ZyX c5ca1b23c4 Use class setup/teardown methods to use vim module mock 2014-09-05 20:00:19 +04:00
ZyX 7bf025ca2b Add `exclude_/include_function` support
This is first step towards fixing #1046.
2014-09-05 20:00:19 +04:00
ZyX bc557bd656 Use replace_item to add module `bar` to sys.modules
Tests should not leave modified environment.
2014-09-04 21:38:49 +04:00
ZyX 96b2cb8f10 Fix spaces-only line in configuration.rst 2014-09-04 21:38:49 +04:00
ZyX 9947bb300a Reference sections where all segments are listed 2014-09-04 21:38:49 +04:00
ZyX ea2fd28292 Merge exclude_modes and include_modes documentation 2014-09-04 21:38:49 +04:00
ZyX b5a551eb56 Fix typos in exclude/include_modes documentation 2014-09-04 19:34:29 +04:00
ZyX 479bc7fca4 Do not raise from gen_segment_getter 2014-09-04 19:09:15 +04:00
ZyX bd719ba134 Make too long line in segment.py more readable 2014-09-04 19:05:30 +04:00
ZyX 00d3dfbc19 Merge branch 'pypi' into develop 2014-09-04 18:27:15 +04:00
ZyX 1d4349ce72 Exclude *.pyc files in bindings directory 2014-09-04 09:13:08 +04:00
ZyX a221e82af1 Also include client files in the distribution 2014-09-04 09:09:45 +04:00
ZyX 2a515b7849 Use PyPI name in setup.py 2014-09-04 08:46:29 +04:00
ZyX 2a73f031a0 Add download_url, license and classifiers to setup.py 2014-09-04 08:46:03 +04:00
Nikolai Aleksandrovich Pavlov 31ccd2907a Merge pull request #1056 from ZyX-I/vim-troubleshooting
Improve vim troubleshooting
2014-09-04 08:42:04 +04:00
ZyX 8588885b04 In vim tests check for printed messages 2014-09-04 08:32:36 +04:00
ZyX 0bb14dbe9c Make it immune to the absense of powerline_appended_path 2014-09-04 08:29:08 +04:00
ZyX a919b453ee Fix some errors in troubleshooting code 2014-09-04 08:29:08 +04:00
ZyX eda93c87fd Add default_log_stream Powerline attribute, make it sys.stdout in Vim
Reason for changes in VimPowerline:

    try
        python import sys; sys.stderr.write('abc')
    catch
        echomsg v:exception
    endtry

reports an exception. This should not happen because stack trace that ought to 
be printed by the logger will not be shown to the user, making it hard to 
determine the error and turning some recoverable errors to non-recoverable when 
using powerline.vim.
2014-09-04 08:19:17 +04:00
Nikolai Aleksandrovich Pavlov 13fef50837 Merge pull request #1055 from magus424/develop
Corrects alignment issue between inactive and active windows in tmux.
2014-09-03 22:50:52 +04:00
Collin Grady c50838bd2c Corrects alignment issue between inactive and active windows in tmux.
Adresses #1029
2014-09-02 18:23:52 -07:00
Nikolai Aleksandrovich Pavlov 77d311bdc8 Merge pull request #1053 from ZyX-I/fix-uv-watcher
Some fixes for libuv-based watcher
2014-09-02 22:22:43 +04:00
ZyX a2c6d79b2f Return False in place of None to indicate absense of changes
Fixes #1052: another part of it
2014-09-02 22:09:07 +04:00
ZyX ad519b5e91 Add realpath() calls to Uv watchers where appropriate 2014-09-02 22:06:24 +04:00
ZyX c564b64530 Add `is_watching` method to UvWatcher class
Fixes #1052
2014-09-02 22:05:53 +04:00
ZyX b638a8e1c9 Add tests for is_watching method
Currently they fail for uv-based watcher.
2014-09-02 21:58:42 +04:00
ZyX 6484341222 Rename `is_watched` method to `is_watching` 2014-09-02 21:51:46 +04:00
ZyX 986a69481f Update documentation 2014-09-02 21:49:23 +04:00
Nikolai Aleksandrovich Pavlov a4667c9a76 Merge pull request #1045 from ZyX-I/style-fixes
Improve coding style
2014-09-01 00:30:05 +04:00
ZyX 8d00ba781c Remove unneeded # NOQA comments
It appears that something has changed and it no longer complains about double
declaration in else or except blocks.
2014-09-01 00:25:24 +04:00
ZyX 06211cbe63 Unify imports
Now imports follow the following structure:

1. __future__ line: exactly one line allowed:

        from __future__ import (unicode_literals, division, absolute_import, print_function)

   (powerline.shell is the only exception due to problems with argparse).
2. Standard python library imports in a form `import X`.
3. Standard python library imports in a form `from X import Y`.
4. and 5. 2. and 3. for third-party (non-python and non-powerline imports).
6. 3. for powerline non-test imports.
7. and 8. 2. and 3. for powerline testing module imports.

Each list entry is separated by exactly one newline from another import. If
there is module docstring it goes between `# vim:` comment and `__future__`
import. So the structure containing all items is the following:

    #!/usr/bin/env python
    # vim:fileencoding=utf-8:noet

    '''Powerline super module'''

    import sys

    from argparse import ArgumentParser

    import psutil

    from colormath.color_diff import delta_e_cie2000

    from powerline.lib.unicode import u

    import tests.vim as vim_module

    from tests import TestCase

.
2014-09-01 00:25:24 +04:00
ZyX 545bd6b52f Fix some style errors reported by syntastic in .segments.plugin.ctrlp 2014-08-31 22:09:09 +04:00
ZyX d952b469d6 Fix syntastic error in powerline.lib.memoize 2014-08-31 21:44:18 +04:00
ZyX aaed00e078 Fix installation notes location.
These notes are parts of the list entries.
2014-08-31 21:33:56 +04:00
ZyX 0e98bc2d4f Fix style in a number of places
- Fixes lines where line with N tab indent is followed by a line with N+2 tab 
  indent or greater (most of such lines were already fixed in 
  ae92d83eae, but regex used there has one flow: 
  it does not catches lines where N=0 for which case first `\+` needs to be 
  replaced with `*`).
- Replace print(…, file=sys.stderr) with sys.stderr.write in powerline-daemon.
2014-08-31 21:29:03 +04:00
Nikolai Aleksandrovich Pavlov a2b58370c4 Merge pull request #1043 from ZyX-I/truncate-expand
Add segment.truncate and segment.expand attributes support
2014-08-30 18:29:28 +04:00
ZyX 2505d0b827 Implement segment truncation
Closes #161 (requires implementation for specific segments though)
2014-08-30 18:22:52 +04:00
ZyX d6c603daf0 Add support for `segment.expand`
Closes #154
2014-08-30 18:22:46 +04:00
ZyX 5b038dba82 Use `expand` key to fill segments 2014-08-30 17:59:58 +04:00