mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-04-15 13:03:08 -04:00
Fixed to update the fonts for MainWindow ListWidget
This commit is contained in:
parent
a5752ec4d3
commit
5005c0303d
@ -1642,6 +1642,8 @@ void MainWindow::settingsChanged()
|
||||
ui->toolBarAction->setIconSize(QSize(toolSize,toolSize));
|
||||
int itemSize = Settings->getListItemIconSize();
|
||||
ui->listWidget->setIconSize(QSize(itemSize,itemSize));
|
||||
|
||||
updateFontSize();
|
||||
}
|
||||
|
||||
void MainWindow::externalLinkActivated(const QUrl &url)
|
||||
@ -1821,13 +1823,6 @@ void MainWindow::setCompactStatusMode(bool compact)
|
||||
//opModeStatus: TODO Show only ???
|
||||
}
|
||||
|
||||
void MainWindow::showEvent(QShowEvent *event)
|
||||
{
|
||||
if (!event->spontaneous()) {
|
||||
updateFontSize();
|
||||
}
|
||||
}
|
||||
|
||||
void MainWindow::updateFontSize()
|
||||
{
|
||||
#if defined(Q_OS_DARWIN)
|
||||
@ -1841,7 +1836,6 @@ void MainWindow::updateFontSize()
|
||||
QFontMetricsF fontMetrics(newFont);
|
||||
int iconHeight = fontMetrics.height()*1.5;
|
||||
ui->listWidget->setFont(newFont);
|
||||
ui->toolBarPage->setFont(newFont);
|
||||
ui->listWidget->setIconSize(QSize(iconHeight, iconHeight));
|
||||
}
|
||||
}
|
||||
|
@ -204,8 +204,6 @@ public:
|
||||
|
||||
static bool hiddenmode;
|
||||
|
||||
virtual void showEvent(QShowEvent *) ;
|
||||
|
||||
public slots:
|
||||
void receiveNewArgs(QStringList args);
|
||||
void displayErrorMessage(int,int,const QString&) ;
|
||||
|
@ -376,4 +376,6 @@ void AppearancePage::updateFontSize()
|
||||
Settings->beginGroup(QString("File"));
|
||||
Settings->setValue("MinimumFontSize", ui.minimumFontSize_SB->value());
|
||||
Settings->endGroup();
|
||||
|
||||
NotifyQt::getInstance()->notifySettingsChanged();
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user