HeroEngine Forums

HeroEngine Support => GUI Creation => Topic started by: Hiro_Protagonist on Mar 11, 14, 12:25:49 PM

Title: Hiding Tab Panels in the GUI Editor
Post by: Hiro_Protagonist on Mar 11, 14, 12:25:49 PM
Quick question: I am creating a tabbed GUI, based on the wiki (http://hewiki.heroengine.com/wiki/GUI_Tabs). However, it is really difficult to actually build the content in the tabs because everything is visible- I see all the tabs all the time, overlapping. Other GUI editors allow you to hide the tabs so you can edit just one at a time- HE must have this so I must be missing something basic, but for the life of me I can't figure out how to make this easy!

Edit: things I've tried:
Set the panel to visible=false
Set the panel to enabled = false
Right click everywhere

Last remaining idea:
Build the tabs as separate GUIs and add them dynamically to the tab set. This seems like major overkill though.
Title: Re: Hiding Tab Panels in the GUI Editor
Post by: FI-ScottZ on Mar 11, 14, 01:49:31 PM
At the top of the editor is an Options buttons.  One of the options is to not show hidden controls, so turn that on.
Title: Re: Hiding Tab Panels in the GUI Editor
Post by: Hiro_Protagonist on Mar 11, 14, 03:46:18 PM
I knew there was something basic I was missing. Thanks, so much better now.
Title: Re: Hiding Tab Panels in the GUI Editor
Post by: Thazager on Mar 11, 14, 08:48:56 PM
Another option, is to add gui parts to the GUI through script. Here parent is used to for the tab name, and multiple tab client areas can be set.

Code: [Select]
// set the current slot type
function setSlots(parent as String)
  myAugs as NodeRef of Class GUIControl = getClientArea(parent)
  myPanel as NodeRef of Class GUIControl

  end as Integer = getAmountSlots(parent)

  // clear old slots - don't want stacked panels
  loop i from 1 to 5
    myPanel = FindGUIControlByName(myAugs, "ItemSlot"+i)
    if myPanel <> None
      DestroyNode(myPanel)
    .
  .
  // make new panels
  loop i from 1 to end
    myPanel = CreateNodeFromPrototype("ItemPanel")          // slot for augments
    myPanel.build = true
    myPanel.name = "ItemSlot"+i
    myPanel.position.x = (i-1) mod 5 * 74
    myPanel.position.y = (i-1) / 5 * 90
    add back myPanel to myAugs.children
  .
.