Page 1 of 1

ListIcon Column : size is useless

Posted: Tue Nov 01, 2016 9:54 am
by falsam
Code Test

Code: Select all

ExamineDesktops()
OpenWindow(0, 0, 0, 800, 600, "", #PB_Window_ScreenCentered)

;Enter 0, 100, 200, ... The width of the column does not change
ListIconGadget(0, 0, 0, 800, 600, "Col 0",  100, #PB_ListIcon_CheckBoxes | #PB_ListIcon_FullRowSelect)

;AddGadgetColumn(0, 1, "Col 1", 200)
For i = 1 To 10
  AddGadgetItem(0, -1, "Note " + i)
Next
P.S : The Header and the Row Columns doesn't match
http://forums.spiderbasic.com/viewtopic.php?f=11&t=734

Re: ListIcon Column : size is useless

Posted: Tue Nov 01, 2016 3:56 pm
by T4r4ntul4
With width in AddGadgetColumn doesnt do much either

Code: Select all

ExamineDesktops()
OpenWindow(0, 0, 0, 800, 600, "", #PB_Window_ScreenCentered)

;Enter 0, 100, 200, ... The width of the column does not change
ListIconGadget(0, 0, 0, 800, 600, "Col 0",  10, #PB_ListIcon_CheckBoxes | #PB_ListIcon_FullRowSelect)

AddGadgetColumn(0,1,"Col 1",10)
AddGadgetColumn(0,2,"Col 2",10)
AddGadgetColumn(0,3,"Col 3",10)
AddGadgetColumn(0,4,"Col 4",10)

;AddGadgetColumn(0, 1, "Col 1", 200)
For i = 1 To 10
  AddGadgetItem(0, -1, "Note " + i)
Next
And a second bug is visible in above code, it shows that the title columns are not the same width as the Note 1 to Note 10 columns.

Re: ListIcon Column : size is useless

Posted: Thu Nov 10, 2016 8:05 am
by Fred
A column can't be smaller than it's title length, and the last column always takes the remaining length. Here is a test code, it seems to work

Code: Select all

OpenWindow(0, 0, 0, 800, 600, "", #PB_Window_ScreenCentered)

ListIconGadget(0, 0, 0, 800, 600, "Col 0",  50, #PB_ListIcon_CheckBoxes | #PB_ListIcon_FullRowSelect)

AddGadgetColumn(0,1,"Col 1",100)
AddGadgetColumn(0,2,"Col 2",200)
AddGadgetColumn(0,3,"Col 3",300)
AddGadgetColumn(0,4,"Col 4",100)

For i = 1 To 10
  AddGadgetItem(0, -1, "Note " + i)
Next