Starting with Windows XP (Comctl32.dll version 6) there is a very simple method to draw an up-arrow or down-arrow in the header of a ListView control.
We just need to add a flag HDF_SORTDOWN for a down-arrow or HDF_SORTUP for an up-arrow, in the fmt field of the HDITEM structure.
This point was discussed in this thread:
http://www.powerbasic.com/support/pb...ad.php?t=40798
To size the width of the columns correctly i.e. to be sure the columns are large enough including the header string and the arrow, I would like to know if there is a function that can return either:
- The size of the column header including the arrow
I tried the API ListView_SetColumnWidth() with %LVSCW_AUTOSIZE or %LVSCW_AUTOSIZE_USEHEADER with no success; the arrow are never included.
Is-there any simple algorithm to compute the column width including the header text, the arrow and the necessary padding spaces.
Thank a lot.
Jean-Pierre
We just need to add a flag HDF_SORTDOWN for a down-arrow or HDF_SORTUP for an up-arrow, in the fmt field of the HDITEM structure.
This point was discussed in this thread:
http://www.powerbasic.com/support/pb...ad.php?t=40798
To size the width of the columns correctly i.e. to be sure the columns are large enough including the header string and the arrow, I would like to know if there is a function that can return either:
- The size of the column header including the arrow
I tried the API ListView_SetColumnWidth() with %LVSCW_AUTOSIZE or %LVSCW_AUTOSIZE_USEHEADER with no success; the arrow are never included.
Is-there any simple algorithm to compute the column width including the header text, the arrow and the necessary padding spaces.
Thank a lot.
Jean-Pierre
Comment