Page 1 of 1

[Implemented] Manipulate ExplorerListGadget Column

Posted: Thu Jun 12, 2003 1:12 am
by fsw
Would be nice to be able to change the width of the name column by command like SetExplorerColumnWidth(GadgetID,ColumnID,Width).
GetExplorerColumnWidth(GadgetID,ColumnID,Width) would also be nice (so it can be stored and while the application starts read the value and set it.

Also to be able to delete a column would be nice (the TYPE column is mostly not needed).
Maybe just set the column width to 0 :?:

The ColumnWidth function could be useful for the other ListGadgets too...

(Implemented trough the gadget attribute: '#PB_Explorer_ColumnWidth')

Posted: Thu Jun 12, 2003 1:17 am
by RJP Computing
And on that note, to be able to add columns would be great. (ie. attributes of the files) Also it would be great to get the right click message when you right-clicked on the header.
Just some thoughts. Great gadget!

Thanks

Posted: Thu Jun 12, 2003 9:35 pm
by freak
On the list for the next update, i'll see what i can do...

Timo

Posted: Thu Jun 12, 2003 10:18 pm
by fsw
8)

Posted: Sun Jun 15, 2003 2:33 pm
by Denis
Hi fsw and RJP Computing,

To add a column, just use AddGadgetColumn() command. I try it with explorergeadget and it works well.


I'm wrinting a lib for listicongadget and i have tested the command to set width of column on ExplorerGadget. It works well.
ExplorerGadget is a listiconGadget.

Use this message to set column width :

sendmessage_(GadgetID(#ExplorerGadget),#LVM_SETCOLUMNWIDTH , ColumnIndex,Width)

Use this message to get column width :

sendmessage_(GadgetID(#ExplorerGadget),#LVM_GETCOLUMNWIDTH , ColumnIndex, 0)


Denis

Posted: Sun Jun 15, 2003 3:23 pm
by freak
Yes, ExplorerListGadget is a Listicon, and you can easily modify it
with the API commands.

However, I don't know, what happens, if you remove a column atm, as the
Gadget will continue to write data to it, so better set the with of the unused
columns to 0.

btw: ExplorerTreeGadget is a usual TreeGadget, I'm sure you can find
some hacks there as well :wink:

Timo

Posted: Sun Jun 15, 2003 6:15 pm
by Denis
You're 100% rigth Freak,

Better to add new commands for next version. :wink:


Denis

Posted: Tue Sep 16, 2003 12:53 pm
by Blade
Denis wrote: To add a column, just use AddGadgetColumn() command. I try it with explorergeadget and it works well.
...
ExplorerGadget is a listiconGadget.
...
Hello, I wonder how we then can fill that column. Perhaps with some callback (that I still can't understand at all)?
For example I'd like to show there the fist 100 byes of each file, if the file is a .txt
Is it possible? I could scan all the files after every refresh, but how can I know that when a refresh has finished?