• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

screen resolution problem

 
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a problem with screen resolution. my project screen resolution is changing from one system to another system.
help me
 
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

prabhu ganapathylingam wrote:I have a problem with screen resolution. my project screen resolution is changing from one system to another system.
help me



What do you mean by "project screen resolution"? You mean the screen resolution of the systems are different? That's expected. What is happening? What do you want to happen instead?
 
prabhu ganapathylingam
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
thanks for your reply.

I have created a project in 1024X768 screen resolution. but the screen resolution is changed, the size of the panels in the frame are not changed according to the resolution. what I am trying to says is i want to run my project in any screen resolution with the same size or the size of the control are changed according to the resolution.
 
Kevin Workman
Ranch Hand
Posts: 151
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

prabhu ganapathylingam wrote:thanks for your reply.

I have created a project in 1024X768 screen resolution. but the screen resolution is changed, the size of the panels in the frame are not changed according to the resolution. what I am trying to says is i want to run my project in any screen resolution with the same size or the size of the control are changed according to the resolution.



Can I ask why you want this? I should point out that the components are the same size as measured in pixels. Chances are, you should probably not bother trying to force your application to do something like this: it's up to the user, and it's that way for a reason.
 
prabhu ganapathylingam
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
the user change the resolution it will reflect the application also. Because, i have given the set bounds to the panels. if the resolution is changed the the application is not look good. So that, i am trying to change this according to screen resolution.
 
Sheriff
Posts: 22781
131
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Use a proper layout managers (or multiple) next time. BorderLayout, FlowLayout, GridLayout, they all know how to handle resizes of the parent container. But it seems like you have used a null layout manager and are calling setBounds directly. That won't resize your controls, no.

As for which layout manager is best, you'll have to experiment. Check out the Java tutorial about it. Don't be afraid to add a JPanel with a different layout manager to some JPanel. Nested panels with different layout managers is very usual in AWT and Swing programming.

Oh, and moving to our GUI forum.
 
reply
    Bookmark Topic Watch Topic
  • New Topic