Merge branch 'feature/vim-special-windows' into develop
This commit is contained in:
commit
a1f370490b
|
@ -36,7 +36,8 @@
|
|||
"theme": "default",
|
||||
"local_themes": {
|
||||
"cmdwin": "cmdwin",
|
||||
"help": "help"
|
||||
"help": "help",
|
||||
"quickfix": "quickfix"
|
||||
}
|
||||
},
|
||||
"wm": {
|
||||
|
|
|
@ -0,0 +1,36 @@
|
|||
{
|
||||
"segment_data": {
|
||||
"file_name": {
|
||||
"contents": "Location List"
|
||||
}
|
||||
},
|
||||
"segments": {
|
||||
"left": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "file_name",
|
||||
"draw_soft_divider": false
|
||||
},
|
||||
{
|
||||
"type": "string",
|
||||
"highlight_group": ["background"],
|
||||
"draw_soft_divider": false,
|
||||
"draw_hard_divider": false,
|
||||
"width": "auto"
|
||||
}
|
||||
],
|
||||
"right": [
|
||||
{
|
||||
"type": "string",
|
||||
"name": "line_current_symbol",
|
||||
"highlight_group": ["line_current_symbol", "line_current"]
|
||||
},
|
||||
{
|
||||
"name": "line_current",
|
||||
"draw_soft_divider": false,
|
||||
"width": 3,
|
||||
"align": "r"
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
|
@ -13,3 +13,7 @@ def help(matcher_info):
|
|||
def cmdwin(matcher_info):
|
||||
name = matcher_info['buffer'].name
|
||||
return name and os.path.basename(name) == '[Command Line]'
|
||||
|
||||
|
||||
def quickfix(matcher_info):
|
||||
return str(getbufvar(matcher_info['bufnr'], '&buftype')) == 'quickfix'
|
||||
|
|
|
@ -19,7 +19,7 @@ class TestConfig(TestCase):
|
|||
def test_vim(self):
|
||||
from powerline.vim import VimPowerline
|
||||
cfg_path = os.path.join(os.path.dirname(os.path.dirname(__file__)), 'powerline', 'config_files')
|
||||
buffers = ((('bufoptions',), {'buftype': 'help'}), (('buffer', '[Command Line]'), {}))
|
||||
buffers = ((('bufoptions',), {'buftype': 'help'}), (('buffer', '[Command Line]'), {}), (('bufoptions',), {'buftype': 'quickfix'}))
|
||||
with open(os.path.join(cfg_path, 'config.json'), 'r') as f:
|
||||
self.assertEqual(len(buffers), len(json.load(f)['ext']['vim']['local_themes']))
|
||||
outputs = {}
|
||||
|
|
Loading…
Reference in New Issue