PDA

View Full Version : scrolling



jkeller
April 16th, 2026, 19:33
I'm trying to create some kind of window inside my main UI. I want the inner window to be fairly large, and to be scrollable and/or dragable as needed.
I don't need anything fancy.

I've tried several approaches, but nothing has worked so far.

Can anyone point me to an example? Thanks!

LordEntrails
April 16th, 2026, 20:09
What's wrong with just creating a window via a windowclass? Default behavior will be draggable, resizable, and maybe? scrollable if the contents grow.

<windowclass name="NewWindow">
<placement>
<size height="300" width="300" />
</placement>
<sheetdata />
</windowclass>

Trenloe
April 16th, 2026, 21:55
Only certain controls support scrolling - which will be using the mousewheel, unless a scrollbarcontrol is attached - see info here: https://fantasygroundsunity.atlassian.net/wiki/spaces/FGCP/pages/996645136/scrollbarcontrol

For examples, unzip CoreRPG (not in the rulesets directory) and do a find in files for scroll

jkeller
April 17th, 2026, 21:34
I can get vertical scrolling to work. The mouse-wheel scrolls automatically.

If I add scrollbar_list controls, the vertical scroll bar shows up.

No luck with horizontal yet.



<scrollbar_list>
<anchored to="content" />
<target>content</target>
</scrollbar_list>

<scrollbar_list>
<anchored to="content" />
<target>content</target>
<horizontal />
</scrollbar_list>

Trenloe
April 17th, 2026, 21:42
As indicated in the scrollbarcontrol API page I linked (https://fantasygroundsunity.atlassian.net/wiki/spaces/FGCP/pages/996645136/scrollbarcontrol): "A scrollbarcontrol creates a vertical scrollbar control." There is no <horizontal/> option in the Definition section of that page.

Only an image control can "pan" (move horizontally and vertically) as detailed here: https://fantasygroundsunity.atlassian.net/wiki/spaces/FGCP/pages/996645149/scrollercontrol

jkeller
April 17th, 2026, 22:05
Ah, okay, thanks.

I don't think I want to go that route at the moment. Currently, they can resize the window so it's large enough for my needs; that should be fine for now.