I downloaded the bui jar today and tried to do a HelloWorld example for BUI.
Just a jME HelloWorld with some BUI code to get a button on the screen.
problem 1 solved
[…]
problem 2:
protected void simpleInitGame() {
I downloaded the bui jar today and tried to do a HelloWorld example for BUI.
Just a jME HelloWorld with some BUI code to get a button on the screen.
problem 1 solved
[…]
problem 2:
protected void simpleInitGame() {
The version is the one you gave me 5 minutes ago :). The error is the same.
But thx for the answer!
If you haven't used Bui yet (thought you had), i don't wanna bother you any longer.
Is anyone in here who has already used it?
as far as I can see in the current bui code (but your version seems to be quite older) the button has no _backgroud - whatever that means (I have not used bui yet).
Hi Paigan,
I got the same error whenever I call setBounds() on a BButton instance…
Son Of Cain
After irrisor's tip, i inserted the line
"button.setBackground(new BlankBackground());"
thus changing the error to:
java.lang.IllegalArgumentException: Components added to a BorderLayout must have proper constraints (eg. BorderLayout.NORTH).
at com.jmex.bui.layout.BorderLayout.addLayoutComponent(BorderLayout.java:90)
at com.jmex.bui.BContainer.add(BContainer.java:77)
at com.jmex.bui.BContainer.add(BContainer.java:67)
at HelloBUI.simpleInitGame(HelloBUI.java:81)
at com.jme.app.SimpleGame.initGame(SimpleGame.java:374)
at com.jme.app.BaseGame.start(BaseGame.java:65)
at HelloBUI.main(HelloBUI.java:59)
(now occurs one line later, at "guiWin.add(button);")
But again, i don't know what BUI wants from me…
I couldn't find where to set something like BorderLayout
Dunno… once again, dealing with GUI is rescheduled
It is just like swing, but not the same!
I have this error too, when I use no layout manager for the window (passing a null reference, as we do in swing). It looks like BUI requires a layout for your window, even if you intend to set their location "manually".
Son Of Cain