Solved

Gird width problem with JDateChooser object

Posted on 2006-06-27
5
501 Views
Last Modified: 2006-11-18
I have a new date drop down selection box and I having problerms with the grid not making it wide enough so the date is actually there, but on digit is half cut off when viewing...

How do I widen the grid field to allow it wider.. I have included partial code below...

*** beginDateChooser is a JDateChooser object widget ***

GridBagConstraints gbc = new GridBagConstraints();
gbc.insets = new Insets(5, 2, 2, 2);
gbc.anchor = 17;

gbc.gridx = 0;
gbc.gridy = 0;
nPane.add(beginDateChooser, gbc);
nPane.add(new JLabel("Begin Date"), gbc);
gbc.gridx++;
nPane.add(beginDateChooser, gbc);  //point where field needs to be wider, but just not
0
Comment
Question by:TheVeee
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
5 Comments
 
LVL 86

Assisted Solution

by:CEHJ
CEHJ earned 100 total points
ID: 16996320
Try setting weightx for that column
0
 
LVL 5

Author Comment

by:TheVeee
ID: 16996603
CEHJ,

Tried that, nothing happened at all....

Its like the 5 columns are locked... looks like this is never set anywhere except on the default....
0
 
LVL 26

Expert Comment

by:ksivananth
ID: 16997163
why are u adding the date chooser two times?

try setting wightx and fill properties.

and gbc.anchor = GridBagConstraints.WEST;
0
 
LVL 26

Accepted Solution

by:
ksivananth earned 400 total points
ID: 16997165
also try setting ipadx value
0
 
LVL 86

Expert Comment

by:CEHJ
ID: 17013955
:-)
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Java contains several comparison operators (e.g., <, <=, >, >=, ==, !=) that allow you to compare primitive values. However, these operators cannot be used to compare the contents of objects. Interface Comparable is used to allow objects of a cl…
By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
Viewers will learn about basic arrays, how to declare them, and how to use them. Introduction and definition: Declare an array and cover the syntax of declaring them: Initialize every index in the created array: Example/Features of a basic arr…
Suggested Courses

632 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question