mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-01 13:36:48 +08:00
[UI] Make completer length font size relative
This commit is contained in:
committed by
Mat Sutcliffe
parent
668659248e
commit
70c88f0982
@@ -457,7 +457,8 @@ namespace BlackGui
|
||||
if (!airports.isEmpty())
|
||||
{
|
||||
QCompleter *airportCompleter = new QCompleter(airports, this);
|
||||
airportCompleter->popup()->setMinimumWidth(75);
|
||||
const int w5chars = airportCompleter->popup()->fontMetrics().size(Qt::TextSingleLine, "FooBa").width();
|
||||
airportCompleter->popup()->setMinimumWidth(w5chars * 5);
|
||||
ui->le_AtcStationsOnlineMetar->setCompleter(airportCompleter);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user