Slick Forums

Discuss the Slick 2D Library
It is currently Fri May 24, 2013 4:51 pm

All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
PostPosted: Fri Jun 15, 2012 6:38 pm 
Offline
Oldbie

Joined: Thu Mar 15, 2012 12:38 am
Posts: 260
Hello!

I am now trying to create a Dialog window similar to Swing's JDialog component.

From my investigation, it seems that I need to use PopupWindow. I have managed to successfully add some widgets to this type of widget and it works.

But is there a way to set the title of the PopupWindow? I don't see any setTitle() method present on this. I assume I would have to subclass PopupWindow and implement the same sort of functionality that ResizableFrame has. I just want to make sure there isn't an easier way that I'm overlooking.

I'm going to be making a few windows that must be modal and I would like to give them titles (ie: Options, etc).

Thanks again!


Top
 Profile  
 
PostPosted: Fri Jun 15, 2012 9:43 pm 
Offline
Slick Zombie

Joined: Fri Jan 29, 2010 7:02 pm
Posts: 1173
PopupWindow itself does not render anything (but you can set a background image). Take a look at SimpleDialog.
Making a Title is mostly as simple as placing a Label on the top and the rest is handled by the background image.

_________________
TWL - The Themable Widget Library


Top
 Profile  
 
PostPosted: Fri Jun 15, 2012 9:56 pm 
Offline
Oldbie

Joined: Thu Mar 15, 2012 12:38 am
Posts: 260
Great, thanks!


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group