mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Clearer labelling
This commit is contained in:
parent
327b6e071b
commit
af0e127004
@ -5,7 +5,6 @@
|
|||||||
from __future__ import absolute_import, division, print_function, unicode_literals
|
from __future__ import absolute_import, division, print_function, unicode_literals
|
||||||
|
|
||||||
import json
|
import json
|
||||||
import textwrap
|
|
||||||
from collections import Counter
|
from collections import Counter
|
||||||
from threading import Thread
|
from threading import Thread
|
||||||
|
|
||||||
@ -218,13 +217,15 @@ class SearchInput(QWidget): # {{{
|
|||||||
l.addLayout(h)
|
l.addLayout(h)
|
||||||
self.query_type = qt = QComboBox(self)
|
self.query_type = qt = QComboBox(self)
|
||||||
qt.setFocusPolicy(Qt.NoFocus)
|
qt.setFocusPolicy(Qt.NoFocus)
|
||||||
qt.addItem(_('Normal'), 'normal')
|
qt.addItem(_('Contains'), 'normal')
|
||||||
qt.addItem(_('Whole words'), 'word')
|
qt.addItem(_('Whole words'), 'word')
|
||||||
qt.addItem(_('Regex'), 'regex')
|
qt.addItem(_('Regex'), 'regex')
|
||||||
qt.setToolTip(textwrap.fill(_('Choose the type of search: Normal will search'
|
qt.setToolTip(('<p>' + _(
|
||||||
' for the entered text, Whole words will search for whole words that'
|
'Choose the type of search: <ul>'
|
||||||
' equal the entered text and Regex will interpret the text as a'
|
'<li><b>Contains</b> will search for the entered text anywhere.'
|
||||||
' regular expression.')))
|
'<li><b>Whole words</b> will search for whole words that equal the entered text.'
|
||||||
|
'<li><b>Regex</b> will interpret the text as a regular expression.'
|
||||||
|
)))
|
||||||
qt.setCurrentIndex(qt.findData(vprefs.get('viewer-search-mode', 'normal') or 'normal'))
|
qt.setCurrentIndex(qt.findData(vprefs.get('viewer-search-mode', 'normal') or 'normal'))
|
||||||
qt.currentIndexChanged.connect(self.save_search_type)
|
qt.currentIndexChanged.connect(self.save_search_type)
|
||||||
h.addWidget(qt)
|
h.addWidget(qt)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user