File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Make it so: Java DB Connections & Transactions
this week in the
Swing / AWT / SWT
full screen size of JFRame in swing
Joined: Apr 28, 2010
May 04, 2010 13:50:09
hi all pleases can you tell me how to get full screen size of
Joined: Oct 27, 2005
May 04, 2010 14:12:01
Check out Frame.setExtendedState. If you want true full-screen you can use GraphicsDevice.setFullScreenWindow. Assuming you want to use your main (or only) screen:
GraphicsEnvironment environment = GraphicsEnvironment.getLocalGraphicsEnvironment(); GraphicsDevice device = GraphicsEnvironment.getDefaultScreenDevice(); device.setFullScreenWindow(frame);
Pass null to that last call to turn off full-screen mode.
SCJP 1.4 - SCJP 6 - SCWCD 5 - OCEEJBD 6 - OCEJPAD 6
How To Ask Questions
How To Answer Questions
I agree. Here's the link:
subject: full screen size of JFRame in swing
Stretch the image size.
JPanel and JFrame
How to Start Applet Maximized
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015