0

The things i put in "paint()" dont appear right away

https://code.sololearn.com/cDG0IJ2PUs44/?ref=app this is the code, when i run it in eclipse i get no errors or anything, but as you can see this code is supposed to paint a square on top of a black background, but instead it just paints a black background. in order for the square to appear i either need to put the window on fullscreen, resize it, or grab the window and shake it violently around in my computer screen. can someone help me fix this, or is it not my fault that this happens?

19th Dec 2017, 11:32 PM
kevin
6 Answers
+ 9
The GUI libraries that you are using are not supported by SL.
19th Dec 2017, 11:52 PM
Hatsy Rei
Hatsy Rei - avatar
+ 1
ohhhhhhhhhhhhhhh, yeah this code is not for solo learn i was just hoping some1 knew what i did wrong
20th Dec 2017, 2:01 AM
kevin
+ 1
neither of these things worked, but i think ill just finish my project as an applet for now instead
20th Dec 2017, 2:37 AM
kevin
0
ps. im not done with this code, i will eventually make the square move and shoot things, which is why i implemented keylistener
19th Dec 2017, 11:38 PM
kevin
0
i left out one very important detail, im a noob and dont know what SL is
19th Dec 2017, 11:59 PM
kevin
0
thanks, i will try that. the only thing ive ever coded is an applet so im not very good with JFrame
20th Dec 2017, 2:12 AM
kevin