• 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

GridBagConstraints methods question.

 
Ranch Hand
Posts: 65
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello everyone!
Well i started learning of swing through the GridBagLayout and this object GridBagConstraint();
But i didn't understand meanings of following methods:
1. gs.weightx ???

gs.weighty ???

2. gs.fill = GridBagConstraints.; ???

3.gs.anchor = GridBagConstraints.; ???

4.gs.insets = new Insets(arg, arg arg, arg); ???

Please if you have aware about it - to do more explanations for me here?
or if it possible in some scheme.
Thank you!
with regards.
 
Rancher
Posts: 3324
32
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Start by reading the section from the Swing tutorial on How to Use GridBagLayout for an explanation of all the constraints.
 
Marshal
Posts: 79151
377
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It is often easier to use a class like Cay Horstmann's GBC class than plain simple GridBagConstraints.
 
reply
    Bookmark Topic Watch Topic
  • New Topic