Re: [wxpython-users] Column widths in ListCtrl
by Jacek Poplawski other posts by this author
May 8 2008 6:40AM messages near this date
Re: [wxpython-users] Column widths in ListCtrl
|
Re: [wxpython-users] Column widths in ListCtrl
Hello Andrea,
On Thu, May 8, 2008 at 3:29 PM, Andrea Gavana <andrea.gavana@[...].com>
wrote:
> width can be a width in pixels
This is the way I was using it.
> or wxLIST_AUTOSIZE (-1) or
> wxLIST_AUTOSIZE_USEHEADER (-2). wxLIST_AUTOSIZE will resize the column
> to the length of its longest item. wxLIST_AUTOSIZE_USEHEADER will
> resize the column to the length of the header (Win32) or 80 pixels
> (other platforms).
Thanks, I tried it and I have three comments:
1) SetColumndWidth must be called _after_ the list is filled with data, it
doesn't work correctly if I call it after column creation (probably it looks
at already created elements)
2) When the column is empty it sets is to 0 or something similiar, so it
doesn't look good
3) "the longest item" can be shorter than header, and the header can be
shorter than longest item
So how to use max(longest_item, header, const)?
Must I do it manually?
--
Free Software - find interesting programs and change them
NetHack - meet interesting creatures, kill them and eat their bodies
Usenet - meet interesting people from all over the world and flame them
Decopter - unrealistic helicopter simulator, get it from
http://decopter.sf.net
Thread:
Jacek Poplawski
Andrea Gavana
Jacek Poplawski
Andrea Gavana
Chester
|