BomosBoy 13 Posted June 13, 2016 I want to create a loadout dialog with the use of multiple buttons, labels, etc.I've a menu with a headline etc. My problem is that the menu is sometimes looking different. (Image) I thought it might be possible to have a "super" control where different controls are children of the super control. So that i only need to hide the body of my menu not the header. I know i cant explain it good enough. I hope the picture helps. I only want a way where i dont need to hide every single control. Share this post Link to post Share on other sites
gc8 974 Posted June 13, 2016 can you show the dialog code you have so far? thx Share this post Link to post Share on other sites
BomosBoy 13 Posted June 13, 2016 Its nothing special.... I just want like a "controlbox" where i can put other controls in and access them via one idc. class loadoutMenu { idd = 1200; movingEnable = 0; enableSimulation = 1; class controls { class BackgroundTitle : RscText { idc = 1211; x = 0.25 * safezoneW + safezoneX; y = 0.20 * safezoneH + safezoneY; w = 0.5 * safezoneW; h = 0.058 * safezoneH; }; class BackgroundLoadout : RscText { idc = 1212; x = 0.422656 * safezoneW + safezoneX; y = 0.324 * safezoneH + safezoneY; w = 0.37125 * safezoneW; h = 0.319 * safezoneH; }; class ButtonLoadoutDefault : RscButton { idc = 1201; text = "default"; //--- ToDo: Localize; x = 0.25 * safezoneW + safezoneX; y = (0.26 + 0.0015) * safezoneH + safezoneY; w = 0.071 * safezoneW; h = 0.022 * safezoneH; }; class ButtonLoadoutCustom : RscButton { idc = 1202; text = "custom"; //--- ToDo: Localize; x = (0.25 + (0.07) + (0.0015)) * safezoneW + safezoneX; y = (0.26 + 0.0015) * safezoneH + safezoneY; w = 0.071 * safezoneW; h = 0.022 * safezoneH; }; /* MY IDEA ############################# class supercontrol { idc = 2000; button1 : RscButton button2 : RscButton }; class supercontrol2 { idc = 2001; button1 : RscButton button2 : RscButton }; ######################################*/ }; }; Share this post Link to post Share on other sites
bull_a 44 Posted June 13, 2016 You can only have one at a time. The best way to go about structuring dialogs with lots of controls is with multiple ControlGroups (which are basically containers for controls). The only way I have managed to get two dialogs to be layered (where the bottom layer is inactive) is to create them using the following code: _nul = createDialog "RscDialog1"; ([] call BIS_fnc_displayMission) createDisplay "RscDialog2"; This will create a dialog "RscDialog1" and then another dialog "RscDialog2" on top of the first. Hope this helps, Bull 1 Share this post Link to post Share on other sites
BomosBoy 13 Posted June 13, 2016 You can only have one at a time. The best way to go about structuring dialogs with lots of controls is with multiple ControlGroups (which are basically containers for controls). The only way I have managed to get two dialogs to be layered (where the bottom layer is inactive) is to create them using the following code: _nul = createDialog "RscDialog1"; ([] call BIS_fnc_displayMission) createDisplay "RscDialog2"; This will create a dialog "RscDialog1" and then another dialog "RscDialog2" on top of the first. Hope this helps, Bull Yea it helps alot thx! I only need to understand now the concept of the ControlsGroup ^^ but i will read the wiki! Share this post Link to post Share on other sites
BomosBoy 13 Posted June 14, 2016 Sorry that i post again, but has someone an example of ControlsGroup? I try to the example in the wiki / gui editor but my button is invisible / not added. Share this post Link to post Share on other sites
Larrow 2816 Posted June 14, 2016 Did you remember to change your button positions? Positons of controls in a ctrlsGrp are relative to the ctrlGrp. So dependent on whether you added scrollbars to the ctrlGrp(may not be obvious), the button may not be invisible, just wildly offset from where you think it should be. 1 Share this post Link to post Share on other sites
BomosBoy 13 Posted June 15, 2016 Yes that was my problem. And the ControlsGroup has a really big border at the bottom. I made a small ControlsGroup so there was nothing to see ^^. Thx for the answer larrow! Share this post Link to post Share on other sites