I am wondering why the part titled "Create the offscreen graphics context" in that method checks if the offGraphics exists, and if it doesn't creates it. Why didn't they create it in the init() method instead? They also check if the size has changed, can the size of an applet change at run time? (And if they can, can i prevent this so that I don't need to check for creation at each update() call?)

They probably put the code there so it would be in one place, since they were checking for size changes anyway.

I think it is possibel to change the size of an applety dynamically, but it is not common. I don't know what the normal method for doing it would be. Perhaps some jscript and manipulating the size in the DOM?

Thanks for your reply. I thought that I would use setResizable(false); in the init() method, but it's not available. Still I can set my own applet size from that method using (in my case) setSize(400, 400);. A bit strange, I guess it won't be a problem.

I think it is possibel to change the size of an applety dynamically, but it is not common. I don't know what the normal method for doing it would be. Perhaps some jscript and manipulating the size in the DOM?

I managed to crash both Netscape and IE when I tried that stunt back in the day. These days I'd just do it in AJAX.

java-gaming.org is not responsible for the content posted by its members, including references to external websites,
and other references that may or may not have a relation with our primarily
gaming and game production oriented community.
inquiries and complaints can be sent via email to the info‑account of the
company managing the website of java‑gaming.org