Gtk3: applied scrollbars size to client rect if overlay scrolling is enabled.

This commit is contained in:
zeljan1 2025-01-19 17:52:15 +01:00
parent 46023f7b4b
commit 834f380863

View File

@ -5523,12 +5523,12 @@ begin
if Assigned(AWindow) then
begin
Bar := getHorizontalScrollbar;
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible then
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible and GTK3WidgetSet.OverlayScrolling then
HOffset := Bar^.get_allocated_height
else
HOffset := 0;
Bar := getVerticalScrollbar;
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible then
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible and GTK3WidgetSet.OverlayScrolling then
VOffset := Bar^.get_allocated_width
else
VOffset := 0;
@ -7838,13 +7838,13 @@ begin
AViewPort^.get_view_window^.get_geometry(@x, @y, @w, @h);
Bar := getHorizontalScrollbar;
if (Bar <> nil) and Bar^.get_visible then
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible and GTK3WidgetSet.OverlayScrolling then
HOffset := Bar^.get_allocated_height
else
HOffset := 0;
Bar := getVerticalScrollbar;
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible then
if (Bar <> nil) and Gtk3IsWidget(Bar) and Bar^.get_visible and GTK3WidgetSet.OverlayScrolling then
VOffset := Bar^.get_allocated_width
else
VOffset := 0;