Page 1 of 1

[2.0.73] LuaGuiElement "scroll-pane" with style "deep_scroll_pane" incorrectly renders scrollbar

Posted: Thu Feb 26, 2026 12:57 am
by Data
Not sure if it's a bug, or I'm misusing API/base game assets, but here we go

What did you do?
  • Start the freeplay with default settings, no mods/space age dlc
  • Skip the cutscene
  • Run the command (twice to suppress achievements disable warning):

    Code: Select all

    /c
    local frame = game.player.gui.screen.add{ type = 'frame' }
    frame.style.size = 100
    local pane = frame.add{
        type = 'scroll-pane',
        style = 'deep_scroll_pane',
        vertical_scroll_policy = 'always',
        horizontal_scroll_policy = 'never',
    }
    pane.style.horizontally_stretchable = true
    pane.style.vertically_stretchable = true
  • Inspect the frame created at top left corner of the screen
What happened?
The frame contains scrollpane, but scrollbar offset too much to the right (see the screenshot attached)

What did you expect to happen instead?
Scrollbar should be within scrollpane

Does it happen always, once, or sometimes?
Always reproducible, style "deep_scroll_pane_with_padding" has the same scrollbar issue

If you run similar code snippet, but with the default style, scrollbar will have correct position (see also the screenshot):

Code: Select all

/c
local frame = game.player.gui.screen.add{ type = 'frame' }
frame.style.size = 100
local pane = frame.add{
    type = 'scroll-pane',
    vertical_scroll_policy = 'always',
    horizontal_scroll_policy = 'never',
}
pane.style.horizontally_stretchable = true
pane.style.vertically_stretchable = true

Re: [2.0.73] LuaGuiElement "scroll-pane" with style "deep_scroll_pane" incorrectly renders scrollbar

Posted: Thu Feb 26, 2026 1:04 am
by Rseding91
Thanks for the report however this is not a bug. That style specifically has “scrollbars_go_outside = true” which does exactly what it says.