aspose file tools*
The moose likes Swing / AWT / SWT and the fly likes JFrame without titlebar Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "JFrame without titlebar" Watch "JFrame without titlebar" New topic
Author

JFrame without titlebar

Fardeen Siddiqui
Greenhorn

Joined: Dec 08, 2000
Posts: 21
Hi all,
can someone tell me of a method with which i can have a Jframe without a titlebar...
thanx
deekasha gunwant
Ranch Hand

Joined: May 06, 2000
Posts: 396
Hi fardeen,
I think u should use JWindow instead of JFrame which does not have any title bar.

regards
Deekasha
Fardeen Siddiqui
Greenhorn

Joined: Dec 08, 2000
Posts: 21
Hi Deekasha,
if i use JWindow then it becomes static on the left top coner and i am not able to move it on the screen..i am making a ticker which should be able to move all over the desktop..is there any other way out
thanx
fardeen
parul patidar
Ranch Hand

Joined: Sep 07, 2001
Posts: 53
hi deekasha (did i typed correct?)
i am using free java ide when i run mu prog it shows winow without titlebar over process window of ide but when i switch between tasks it disappears y is it not persistent
please guide
thanx in advance
Nathan Pruett
Bartender

Joined: Oct 18, 2000
Posts: 4121

Fardeen,

Since the window doesn't have a titlebar, there is no built in way to move it ( try it on a normal window... the only place you can grab a regular window to move it is the title bar... ) so you have to program in your own code to move the window... something like the following should suffice :



parul,

What OS are you running on? I am using Windows NT and the window doesn't disappear when I switch processes... it doesn't have a box on the taskbar ( since it doesn't have a titlebar it isn't a full-fledged window... ), but if you use alt-tab, you will be able to switch back to it...

Also... depending on the IDE, your class may be running inside the IDE process if you launch it from the IDE... try running your class from DOS to see if this is still a problem.

And, before asking if we can make the window always be on top... No... sorry... You can't make a system level modal window in java... only an application level modal window...

-Nate


-Nate
Write once, run anywhere, because there's nowhere to hide! - /. A.C.
Carlos Cuevas
Greenhorn

Joined: Sep 26, 2002
Posts: 9
just when u create ur frame, on its init method, use this:
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: JFrame without titlebar