I'm trying to get wxListView to display large (32x32) icons on multiple columns. I managed to get it to display one column but I don't know how to add more.
This is what I have so far:
Code: Select all
wxListView* listView = new wxListView(this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLC_ICON);
wxImageList* imageList = new wxImageList(32, 32);
for (int i = 0; i < 4; i++) {
wxIcon* icon = IconGetter::GetExecutableIcon(_T("c:\\windows\\system32\\shell32.dll"), 32, i);
int imageIndex = imageList->Add(*icon);
wxListItem* item = new wxListItem();
item->SetText(_T("text"));
item->SetImage(imageIndex);
listView->InsertItem(*item);
}
listView->SetImageList(imageList, wxIMAGE_LIST_NORMAL);
Thank you,
Laurent