Presetting column width in JTable without disabling autoresize?
From: Anton Golovko (odinodin_at_gmail.com)
Date: 03/22/05
- Next message: Stanimir Stamenkov: "Re: JOptionPane custom options - button mnemonics"
- Previous message: Stanimir Stamenkov: "Re: JOptionPane custom options - button mnemonics"
- Next in thread: John McGrath: "Re: Presetting column width in JTable without disabling autoresize?"
- Reply: John McGrath: "Re: Presetting column width in JTable without disabling autoresize?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 22 Mar 2005 04:45:32 -0800
Hi!
Is there any way to preset column width in pixels wihtout disabling
auto resize in JTable?
Here is my situation:
1. The first column of the table needs to be preset to 30 pixels.
2. I don't want horizontal a scrollbar to appear.
3. I cannot use TableColumn.setMaxWidth, because I want user to be
able to resize column sizes.
TableColumn.setPreferredWidth doesn't work here, the table increases
the width of my column anyway.
Please help!
Regards,
Anton
- Next message: Stanimir Stamenkov: "Re: JOptionPane custom options - button mnemonics"
- Previous message: Stanimir Stamenkov: "Re: JOptionPane custom options - button mnemonics"
- Next in thread: John McGrath: "Re: Presetting column width in JTable without disabling autoresize?"
- Reply: John McGrath: "Re: Presetting column width in JTable without disabling autoresize?"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]