diff options
-rw-r--r-- | gtk/ScintillaGTK.cxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx index 75c19d733..f4602a5b7 100644 --- a/gtk/ScintillaGTK.cxx +++ b/gtk/ScintillaGTK.cxx @@ -893,7 +893,15 @@ void ScintillaGTK::Resize(int width, int height) { // Not always needed, but some themes can have different sizes of scrollbars scrollBarWidth = GTK_WIDGET(scrollbarv.GetID())->requisition.width; + if ((scrollBarWidth == 0)) { + scrollBarWidth = 16; + GTK_WIDGET(scrollbarv.GetID())->requisition.width = scrollBarWidth; + } scrollBarHeight = GTK_WIDGET(scrollbarh.GetID())->requisition.height; + if (horizontalScrollBarVisible && (scrollBarHeight == 0)) { + scrollBarHeight = 16; + GTK_WIDGET(scrollbarh.GetID())->requisition.height = scrollBarHeight; + } // These allocations should never produce negative sizes as they would wrap around to huge // unsigned numbers inside GTK+ causing warnings. |