[Gui] NaviCube: don't write font size on loading preferences

- as discussed here: https://github.com/FreeCAD/FreeCAD/pull/8567#issuecomment-1445283127 and following)
This commit is contained in:
Uwe
2023-02-28 10:15:25 +01:00
parent b1e8de58ea
commit 22db01d7a9

View File

@@ -211,8 +211,9 @@ void DlgSettingsNavigation::loadSettings()
// but not accessible if there is no cube yet drawn
if (hGrp->GetInt("FontSize", 0) == 0) {
// the "4" is the hardcoded m_OverSample from getDefaultFontSize()
hGrp->SetInt("FontSize", int(0.18 * 4 * ui->prefCubeSize->value()));
ui->naviCubeFontSize->onRestore();
ui->naviCubeFontSize->setValue(int(0.18 * 4 * ui->prefCubeSize->value()));
// we purposely don't write to the parameters because the writing would
// also be done when the user cancels the preferences dialog
}
}