mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-05 01:05:34 +08:00
[UI] Make completer length font size relative
This commit is contained in:
committed by
Mat Sutcliffe
parent
668659248e
commit
70c88f0982
@@ -66,7 +66,8 @@ namespace BlackGui
|
||||
c->setCaseSensitivity(Qt::CaseInsensitive);
|
||||
c->setCompletionMode(QCompleter::PopupCompletion);
|
||||
c->setMaxVisibleItems(10);
|
||||
c->popup()->setMinimumWidth(175);
|
||||
const int w5chars = c->popup()->fontMetrics().size(Qt::TextSingleLine, "FooBa").width();
|
||||
c->popup()->setMinimumWidth(w5chars * 10);
|
||||
ui->le_AirlineName->setCompleter(c);
|
||||
return c;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user