mirror of
https://github.com/SoftFever/OrcaSlicer.git
synced 2025-07-10 08:17:51 -06:00
Fix of Settings scaling when they are placed in non-modal Dialog
This commit is contained in:
parent
0f0c9a0726
commit
c49221c621
4 changed files with 19 additions and 4 deletions
|
@ -787,9 +787,10 @@ void MainFrame::on_dpi_changed(const wxRect& suggested_rect)
|
|||
this->SetSize(sz);
|
||||
|
||||
this->Maximize(is_maximized);
|
||||
|
||||
/*
|
||||
if (m_layout == ESettingsLayout::Dlg)
|
||||
rescale_dialog_after_dpi_change(*this, m_settings_dialog, ERescaleTarget::SettingsDialog);
|
||||
*/
|
||||
}
|
||||
|
||||
void MainFrame::on_sys_color_changed()
|
||||
|
@ -1988,7 +1989,14 @@ SettingsDialog::SettingsDialog(MainFrame* mainframe)
|
|||
wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | wxMINIMIZE_BOX | wxMAXIMIZE_BOX, "settings_dialog"),
|
||||
m_main_frame(mainframe)
|
||||
{
|
||||
#if ENABLE_WX_3_1_3_DPI_CHANGED_EVENT && defined(__WXMSW__)
|
||||
// ys_FIXME! temporary workaround for correct font scaling
|
||||
// Because of from wxWidgets 3.1.3 auto rescaling is implemented for the Fonts,
|
||||
// From the very beginning set dialog font to the wxSYS_DEFAULT_GUI_FONT
|
||||
this->SetFont(wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT));
|
||||
#else
|
||||
this->SetFont(wxGetApp().normal_font());
|
||||
#endif // ENABLE_WX_3_1_3_DPI_CHANGED_EVENT
|
||||
this->SetBackgroundColour(wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOW));
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue