Merge branch 'nanjekyejoannah-master'

This commit is contained in:
Florian Bruhin 2016-08-01 14:38:11 +02:00
commit fca3c28134
6 changed files with 16 additions and 1 deletions

View File

@ -24,6 +24,8 @@ Added
did before v0.8.0.
- New `:rl-unix-filename-rubout` command which is similar to readline's
`unix-filename-rubout`.
- New `fonts -> completion.category` setting to customize the font used for
completion category headers.
Changed
~~~~~~~

View File

@ -178,6 +178,7 @@ Contributors, sorted by the number of commits in descending order:
* error800
* Liam BEGUIN
* skinnay
* nanjekyejoannah
* Zach-Button
* Tomasz Kramkowski
* Ismail S

View File

@ -266,6 +266,7 @@
|Setting|Description
|<<fonts-_monospace,_monospace>>|Default monospace fonts.
|<<fonts-completion,completion>>|Font used in the completion widget.
|<<fonts-completion.category,completion.category>>|Font used in the completion categories.
|<<fonts-tabbar,tabbar>>|Font used in the tab bar.
|<<fonts-statusbar,statusbar>>|Font used in the statusbar.
|<<fonts-downloads,downloads>>|Font used for the downloadbar.
@ -2100,6 +2101,12 @@ Font used in the completion widget.
Default: +pass:[8pt ${_monospace}]+
[[fonts-completion.category]]
=== completion.category
Font used in the completion categories.
Default: +pass:[bold ${completion}]+
[[fonts-tabbar]]
=== tabbar
Font used in the tab bar.

View File

@ -206,7 +206,7 @@ class CompletionItemDelegate(QStyledItemDelegate):
else:
self._doc.setPlainText(self._opt.text)
else:
self._doc.setHtml('<b>{}</b>'.format(html.escape(self._opt.text)))
self._doc.setHtml(html.escape(self._opt.text))
def _draw_focus_rect(self):
"""Draw the focus rectangle of an ItemViewItem."""

View File

@ -69,6 +69,7 @@ class CompletionView(QTreeView):
{{ color['completion.category.border.top'] }};
border-bottom: 1px solid
{{ color['completion.category.border.bottom'] }};
font: {{ font['completion.category'] }};
}
QTreeView::item:selected, QTreeView::item:selected:hover {

View File

@ -1244,6 +1244,10 @@ def data(readonly=False):
SettingValue(typ.Font(), DEFAULT_FONT_SIZE + ' ${_monospace}'),
"Font used in the completion widget."),
('completion.category',
SettingValue(typ.Font(), 'bold ${completion}'),
"Font used in the completion categories."),
('tabbar',
SettingValue(typ.QtFont(), DEFAULT_FONT_SIZE + ' ${_monospace}'),
"Font used in the tab bar."),