• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

full screen size of JFRame in swing

 
vipin parode
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all pleases can you tell me how to get full screen size of JFrame in swing
 
Rob Spoor
Sheriff
Pie
Posts: 20368
43
Chrome Eclipse IDE Java Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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:
Pass null to that last call to turn off full-screen mode.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic