From a9b53d94e8fa05af26581771efd37e66b0f245c5 Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Mon, 30 Nov 2020 19:00:11 +0100 Subject: [PATCH] Page layout editor: fix missing scrollbars in properties panel (GTK specific) From master branch --- pagelayout_editor/properties_frame.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pagelayout_editor/properties_frame.cpp b/pagelayout_editor/properties_frame.cpp index 16fe8ad359..d2ec564e01 100644 --- a/pagelayout_editor/properties_frame.cpp +++ b/pagelayout_editor/properties_frame.cpp @@ -303,6 +303,14 @@ void PROPERTIES_FRAME::CopyPrmsFromItemToPanel( WORKSHEET_DATAITEM* aItem ) // The number of widgets was modified m_swItemProperties->Layout(); +#ifdef __WXGTK__ + // This call is mandatory on wxGTK to initialize the right virtual size and therefore + // scrollbars, but for some reason, create issues on Windows (incorrect disply + // until the frame is resized). Joys of multiplatform dev. + m_swItemProperties->Fit(); +#endif + // send a size event to be sure scrollbars will be added/removed as needed + m_swItemProperties->PostSizeEvent(); m_swItemProperties->Refresh(); }