Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

show dilog at bottom of the screen

 
swapnel surade
Ranch Hand
Posts: 129
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I want to show the JDialog at the bottom of the screen.
how I can achieve this

thanks
swapnil
 
Chiranjeevi Kanthraj
Ranch Hand
Posts: 290
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
use dialog.setLocation(width,height);

 
swapnel surade
Ranch Hand
Posts: 129
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
its for just width and height of the dialog. how could this work for position of the dialog
 
Chiranjeevi Kanthraj
Ranch Hand
Posts: 290
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i just gave the name of the variables as height and width , if you see the method which i told is setLocation where it places the dialog to specified x and y position

 
Campbell Ritchie
Sheriff
Posts: 48910
58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The setBounds method is an alternative.
 
Rob Camick
Ranch Hand
Posts: 2580
9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
its for just width and height of the dialog. how could this work for position of the dialog


If you know the size of the screen and the size of the dialog, then you use simple math to calculate where the location should be.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic