mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 19:25:39 +00:00
* the longest completion does not depend on the competion.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@23317 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
93d8667d39
commit
7ff4b67487
@ -743,9 +743,11 @@ size_t commonPrefix(QString const & s1, QString const & s2)
|
||||
docstring GuiCompleter::longestUniqueCompletion() const
|
||||
{
|
||||
QAbstractItemModel const & model = *popup()->model();
|
||||
QString s = currentCompletion();
|
||||
size_t n = model.rowCount();
|
||||
|
||||
if (n == 0)
|
||||
return docstring();
|
||||
QString s = model.data(model.index(0, 0), Qt::EditRole).toString();
|
||||
|
||||
if (modelSorting() == QCompleter::UnsortedModel) {
|
||||
// For unsorted model we cannot do more than iteration.
|
||||
// Iterate through the completions and cut off where s differs
|
||||
|
Loading…
Reference in New Issue
Block a user