Re: ListView first column indent in win32lib
- Posted by CChris <christian.cuvier at agr?culture.gou?.fr> Jun 03, 2008
- 688 views
marky1124 wrote: > > Hi, > > It seems that win32lib forces an indent for the first column of data in a > listview > object to allow for an icon to be displayed, even if one is not required. > > I believe it has been requested before that win32lib be modified to make this > an option, see this post from 2001 > > <a > href="http://www.openeuphoria.org/cgi-bin/esearch.exu?thread=1&fromMonth=3&fromYear=6&toMonth=5&toYear=6&keywords=%22Win32Lib+hacks%22">http://www.openeuphoria.org/cgi-bin/esearch.exu?thread=1&fromMonth=3&fromYear=6&toMonth=5&toYear=6&keywords=%22Win32Lib+hacks%22</a> > > I've checked and commenting out line 2412 in win32lib.ew v0.70.4 does prevent > an ident on the first column (at the cost of not being able to display an icon > I suspect). > > Is there any chance of win32lib being enhanced to make this first column > indent > optional? > > Cheers, > Mark I'll check whether having no icon to display has any undesirable side effect. If it hasn't, then I'll probably add a custom LVS_EX_NOIMAGELIST style, so that no image list is associated to the LV when the style is given to createEx(). Inn the meantime, you can always try to: w32VOID=sendMessage(lv_id,LVM_SETIMAGELIST,LVSI_NORMAL,0) w32VOID=sendMessage(lv_id,LVM_SETIMAGELIST,LVSI_SMALL,0) However, I am not sure you can remove the white soace where the image would go, since MSDN says the following about the LVS_REPORT style, which I waaume you are using: " The leftmost column is always left justified and contains the small icon and label. Subsequent columns contain subitems as specified by the application. " HTH CChris