hey! I ve seen many of your java gui tutorials. They have helped me. I ve been looking all over the internet to find how can i make a JButton be clicked only once and with no luck. The setEnabled method doesnt work for me.. Is there anything else?
Great!!!!!! repaint() is what I've been looking for all over the internet. I hate my CS teacher. She could have taught us this easy method instead of all the jumbo mambos. Theory oriented people sucks!!! Thank you again. Plz keep up the good work.
@tuhinbhatt1 Simply go to the actionListener of the button and load up the new class there. You can create a new object from the other class file that will load the constructor of the new class, which will then load all the methods on the other class. You can also create a new frame in the actionListener, simply by JFrame frame = new JFrame("frame"); and you can also close the current frame by thisFrame.dispose();
I'm pretty sure paintComponent() will be envoked as soon as the frame displays on the screen, so there is no need to have a drawing() method to explicitly call repaint(); The only time you want a repaint(); is if you are changing the shape or coordinates in the paintComponent() method, and the you want to "repaint" the new shape opr coordinates.
WHEN U R READING THIS DONT STOP OR SOMETHING BAD WILL HAPPEN! {SORRYABOUT THIS} THIS GIRL’S NAME IS SUMMER SHE’S 15 YEARS OLD & hasBLONDE HAIR ,MANY SCARS no NOSE OR EARS.. SHE IS DEAD. IF U DONT COPYTHIS JUST LIKE FROM THERING, COPY N POSTTHIS ON 5 MORE SITES.. OR..SUMMER WILL APPEAR ONE DARK QUIET NIGHT WHEN UR NOT… ExPECTING IT BYYOUR BED WITH AKNIFE AND KILL U. THIS IS NO JOKE SOMETHING GOOD WILLHAPPEN TO U IF YOU POST THIS ON 5 MORE PAGES
yo im a having a problem. my graphics window opens but my blue rectangle isn't there. and i've done it exactly like u. maybe its because im using jGrasp to create my programs rather than watever u use? anyways if u think u know wats wrong, a response would be greatly appreciated! lol thx
omg, 3 comments for 2.125k views.. goes too show how much people don't show appreciation for these vid's, great vid man i needed too know how to make gui's and stuff like this 5/5 ^^
hey! I ve seen many of your java gui tutorials. They have helped me. I ve been looking all over the internet to find how can i make a JButton be clicked only once and with no luck. The setEnabled method doesnt work for me.. Is there anything else?
aproblepto222 1 month ago
you make me think i am in aeroplane...jesus,i can give you my microphone...
Meraklis56 2 months ago
Great!!!!!! repaint() is what I've been looking for all over the internet. I hate my CS teacher. She could have taught us this easy method instead of all the jumbo mambos. Theory oriented people sucks!!! Thank you again. Plz keep up the good work.
fuckthegmail 3 months ago in playlist Java Swing/GUI Tutorial/Help without Visual Editor
when ever i try to run this a frame just shows up and its blank
Magnamite9 3 months ago
Thanks, this really helped me out with a Checkers Game Project I'm creating.
excessiveforce03 3 months ago
how do you make a button open another class for you?
ultravanz 6 months ago
@ultravanz have you found the answer(How to make a button another class file
tuhinbhatt1 4 months ago
@tuhinbhatt1 Simply go to the actionListener of the button and load up the new class there. You can create a new object from the other class file that will load the constructor of the new class, which will then load all the methods on the other class. You can also create a new frame in the actionListener, simply by JFrame frame = new JFrame("frame"); and you can also close the current frame by thisFrame.dispose();
MrJavaHelp 3 months ago
Great vid.. good job
jeremyl3763 6 months ago
I'm having problems with the draw object = new draw();
thewhiteone102 6 months ago
@thewhiteone102
I know your comment was from 5 months ago, but hopefully I can help someone else.
The "shapes.java" and the "draw.java" have to be in the same package for that to work.
cheeseonamonkey 1 month ago
I'm pretty sure paintComponent() will be envoked as soon as the frame displays on the screen, so there is no need to have a drawing() method to explicitly call repaint(); The only time you want a repaint(); is if you are changing the shape or coordinates in the paintComponent() method, and the you want to "repaint" the new shape opr coordinates.
Astrovideo 7 months ago
awesome dude make some more java swing tutorial
nasaiah20 8 months ago
I think you make really good tutorials, but you should think about getting yourself a new microfone.
JG4m3r 8 months ago
This has been flagged as spam show
I really dont wanna do this! STOP READING NOW!
WHEN U R READING THIS DONT STOP OR SOMETHING BAD WILL HAPPEN! {SORRYABOUT THIS} THIS GIRL’S NAME IS SUMMER SHE’S 15 YEARS OLD & hasBLONDE HAIR ,MANY SCARS no NOSE OR EARS.. SHE IS DEAD. IF U DONT COPYTHIS JUST LIKE FROM THERING, COPY N POSTTHIS ON 5 MORE SITES.. OR..SUMMER WILL APPEAR ONE DARK QUIET NIGHT WHEN UR NOT… ExPECTING IT BYYOUR BED WITH AKNIFE AND KILL U. THIS IS NO JOKE SOMETHING GOOD WILLHAPPEN TO U IF YOU POST THIS ON 5 MORE PAGES
winxclubsky 8 months ago
ya man you gotta work on ur voice
alco19357 9 months ago
That is an unnecessary piece of method chaining you have there.
bobbyjninja 9 months ago
Heh, thanks for this... )
daGrevis 9 months ago
Java explained!!!!!
altu892 10 months ago
This code is so wrong its not funny
ScrewAttackChina 11 months ago 2
@ScrewAttackChina I know, right?!
MrBlockersPro 9 months ago
Hi its cool to have tutorials to learn how to create shapes in java.
vbBegin1957 1 year ago
It's all great but do somthing with the voice dude!
HunMASK 1 year ago
Thanks alot man! good tutorial
JacobMovieMaker 1 year ago
You saved my life! HAHA Didn't know it was this simple. Thank you!
kim3nidad 1 year ago
Thank you, I finally understand how to use the paintComponent() method.
killuayoukai 1 year ago
thankyou this is exactly what i was looking for *;D !!!
SuzerainEshi 1 year ago
Wasted 5 minutes of my life! I thought CUSTOM SHAPES >.<
ManIkWeet 1 year ago
thanks for the video, very helpful
StaticShock13 1 year ago
is the swing like the CSS of JAVA?
andyli123 1 year ago
Ahhhh thank you! You rock!!!
VoraciousLime 1 year ago
Thanks - that was very helpful.
afejes 1 year ago
yo im a having a problem. my graphics window opens but my blue rectangle isn't there. and i've done it exactly like u. maybe its because im using jGrasp to create my programs rather than watever u use? anyways if u think u know wats wrong, a response would be greatly appreciated! lol thx
703vaboyz 2 years ago
Thanks I've had alot of problems understanding this! At last I got my explaination!
PaXx 2 years ago
thanks ....pls upload more
saddamdon 2 years ago
really helpfull video. I have a question although. Is it possible to have a JPanel and add the 'object' on that instead of the frame?
Shadowdude04 2 years ago
omg, 3 comments for 2.125k views.. goes too show how much people don't show appreciation for these vid's, great vid man i needed too know how to make gui's and stuff like this 5/5 ^^
breached25 2 years ago
thanks.,.,love your videos,.,.so comprehensive.,.,
ystian123 2 years ago
Kkkkeeeeeeeyyyy
deadleg22 2 years ago
sweet thanx a million very good.
okpasha 2 years ago