Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

Java 

Align buttons ( objects )

How do i set the position of a JButton? I've searched all over the internet, and i can't seem to find it, please help :)
Obviously, you are a beginner at JAVA.

So, I suggest starting integrating GUI applications using Netbeans IDE, because it also provides a layout for your form, so that you do not have to align everything by code, but just by your view.

It is very easy to use and if you search youtube, you will find plenty of tutorials explaining in detail "how to".

There is NO reason to waste your time thinking on how to arrange gui objects and test run each time the application to test if it fits you.

Go for it, I'm sure you 'll make it.
Im sorry, but that is not what i asked for.
I want an example on how i set the position on a button. Not a tutorial on how to use NetBeans, i see this as a much faster way to learn things.
Thanks
It depends on the layout you are using.

http://docs.oracle.com/javase/tutorial/u...using.html
If I said something stupid, I probably realized it right after I posted it.


Yeah as Assume said above, it depends on the layout.

My personal preference is to set the layout to null, and then use the setBound method to position everything.
(May 20, 2013 11:24 AM)Xerif Wrote:  Yeah as Assume said above, it depends on the layout.

My personal preference is to set the layout to null, and then use the setBound method to position everything.

I did not know that this was posible, thanks man :)
(May 20, 2013 12:33 PM)ctxd Wrote:  I did not know that this was posible, thanks man :)

No problem man :D PM me if you need anymore help.
(May 20, 2013 01:50 PM)Xerif Wrote:  No problem man :D PM me if you need anymore help.

Thanks, i will! Gave you some reputation for the help ;)


Possibly Related Threads...
Thread / Author Replies Views Last Post
[Java] by PsychoJul 3, 2021 11:15 PM 24 1,975 Jul 3, 2021 11:15 PM
Last Post: Lookdadon
[Python] by Bora or HyunaFeb 14, 2020 12:49 AM 2 311 Feb 14, 2020 12:49 AM
Last Post: Bora or Hyuna
[Python] by SympthFeb 4, 2020 07:54 AM 6 390 Feb 4, 2020 07:54 AM
Last Post: Nikix