Blockland Forums > Modification Help
GuiScrollControl
Pages: (1/1)
otto-san:
I'm pretty sure I made a topic back in 2010 and never got a good answer, can someone explain how to work GuiScrollControls and have selectable child controls?
Like on the Admin GUI?
Red_Guy:
They are pretty easy to use.
add the scroll control.
add a guiControl as the child of the scroll control
then add whatever you want inside the child.
when you make the child control larger than its parent gui scroll control, scrollbars will show up.
That can all be done in the gui editor.
otto-san:
--- Quote from: Red_Guy on June 24, 2011, 06:32:07 PM ---They are pretty easy to use.
add the scroll control.
add a guiControl as the child of the scroll control
then add whatever you want inside the child.
when you make the child control larger than its parent gui scroll control, scrollbars will show up.
That can all be done in the gui editor.
--- End quote ---
I know how to make it scrollable, but like, being selectable. How do I do that, does it just do it automatically at some point?
Red_Guy:
--- Quote from: otto-san on June 24, 2011, 11:08:07 PM ---I know how to make it scrollable, but like, being selectable. How do I do that, does it just do it automatically at some point?
--- End quote ---
what do you mean make it selectable?
What do you want to "select"?
and what have you tried thats not working the way you want?
Greek2me:
You need to add a GuiTextListCtrl as a child of the scroll control.
Example:
--- Code: --- new GuiScrollCtrl() {
profile = "GuiScrollProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "0 19";
extent = "157 108";
minExtent = "8 2";
visible = "1";
willFirstRespond = "0";
hScrollBar = "alwaysOff";
vScrollBar = "alwaysOn";
constantThumbHeight = "0";
childMargin = "0 0";
rowHeight = "40";
columnWidth = "30";
new GuiTextListCtrl(Slayer_Teams_Selector) {
profile = "GuiTextListProfile";
horizSizing = "right";
vertSizing = "bottom";
position = "1 1";
extent = "140 2";
minExtent = "8 2";
visible = "1";
enumerate = "0";
resizeCell = "1";
columns = "0";
fitParentWidth = "1";
clipColumnText = "0";
};
};
--- End code ---
Pages: (1/1)