Jump to content

Cant get BABYLON.GUI StackPanel to work Correct


Pryme8
 Share

Recommended Posts

http://www.babylonjs-playground.com/#ZIPFMJ

I am beating my head into the wall trying to get a white container block next to the text in this example...   Maybe I'm just doing it wrong...

Never mind... It was because I did not have a defined width on the first element... sorry for the wasted thread... 

Guess it pays to actually read the documentation and not skim through >_<

Link to comment
Share on other sites

Maybe, It would not be that hard to make it a constructor!  I was looking at doing text inputs as well here at some point.
http://www.babylonjs-playground.com/#ZIPFMJ#27
also Im about to test DOM UI versus BJS GUI if anyone is interested....  Its not done yet but Ill work on it as I get more time here because I need input elements for my demo for the article I'm writing.

Link to comment
Share on other sites

So I do have a behavior riddle:

https://www.babylonjs-playground.com/#6DQN7N#4

If you click the ... button you will see it hides the value of the select box like would be expected and keeps the two option elements (there can be lots more but this was easiest for debugging)
Which of course is not the functionality I really want because who wants to have all the select options visible at initial run time.

So here is where the question is if I do not add the control initially that has the options in it, when the ... is clicked it toggles correctly but does not show all the options: https://www.babylonjs-playground.com/#6DQN7N#6
Now I can kinda understand that this would be because the stackpanel never got set to the correct height due to the elements never being added or something along those lines.

So I though the fix would be to add it wait till the other elements are added, then remove it?

https://www.babylonjs-playground.com/#6DQN7N#7

but no that does not work... so I am kinda stumped on the behavior of the stack panel elements still... anyone got any ideas on how to make this "work"  Im just dinking around in my free time at work to see if I can come up with a model for select elements.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...