Full Screen feature in Java ?

K

KS

Hi,

is it possible to implement a full screen feature in Java (like in
Windows Media Player), so that I just have to type Alt+Enter and voilá
... full screen without any borders or menu bar.

Any ideas ?

Tristan

How about using Window instead of Frame to show what ever you want to
show. Window has no menu, no frames etc..

Just an idea.

-Kari
 
M

Minh

Hi,

is it possible to implement a full screen feature in Java (like in
Windows Media Player), so that I just have to type Alt+Enter and voilá
.... full screen without any borders or menu bar.

Any ideas ?

Tristan
 
R

R. Kevin Cole

Do something like this to create a fullscreen
JFrame.


public FullScreenFrame extends JFrame
{
public FullScreenFrame( String title )
{
super(title)

setUndecorated(true);
Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
setBounds(0,0,screenSize.width, screenSize.height);
}
}



Hope this helps,

Kevin
 
D

Deepak Nayal

I am not absolutely sure, but I think I read somewhere that JDK 1.4 has
this functionality.

Regards
Deepak
 
A

Andrew Thompson

KS said:
....
How about using Window instead of Frame to show what ever you want to
show. Window has no menu, no frames etc..

The PhySci ImageBrowser uses a JWindow for the
slideshow. You can get the .jar containing the source
at http://www.physci.org/PhySci.jar for an example.

The OP might be able to put their GUI into
a JPanel that can be displayed in either
the original JFrame, or the fullscreen JWindow..
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top