Page 1 of 1

How many characters can be placed in a ListIconGadget Column

Posted: Sun Sep 25, 2011 1:42 am
by nigel
I had placed 500 characters in a ListIconGadget column but only the first 259 are displayed.

As no column size limits (width or contents) are mentioned in the documentation (at least I couldn't find any), I am curious to know if this is a bug or if there are undocumented limits involved.

Re: How many characters can be placed in a ListIconGadget Co

Posted: Sun Sep 25, 2011 4:14 am
by Shield
It's set to the value of #MAX_PATH (which is 260), so the string gets cut off after 259.
That behavior is not a PureBasic but a Windows API limitation since the gadget is designed
to display general purpose information (such as paths) and not huge texts. :)

Note that (IIRC) the gadget does only display 259 characters but the original text is still stored in memory,
so it should be returned correctly by GetGadgetText.

But it still might be possible to increase the number of characters.

Re: How many characters can be placed in a ListIconGadget Co

Posted: Sun Sep 25, 2011 3:53 pm
by em_uk
Is that still a limitation on Win7x64?

I know that XP Explorer will fail to open paths longer than 255 chars, but this doesn't affect Win7x64.

Re: How many characters can be placed in a ListIconGadget Co

Posted: Sun Sep 25, 2011 4:16 pm
by nigel
Thanks for the explanation Shield. I'll just have to live with this one as the alternative of splitting the data over two columns would be somewhat untidy.