1

I'm working on a project in which I'd like to make something like the pattern explorer in Photoshop (as in this picture http://uploads.siteduzero.com/files/392001_393000/392193.png)`;

I originally was doing so using a custom QAbstractTableModel coupled with a QTableView but I have to set the numbers of rows and cols from the Model itself. This is a problem because I want the columns to adapt to the viewer width as in the FlowLayout example : http://qt-project.org/doc/qt-4.8/layouts-flowlayout.html

It seems that the model/view system isn't adapted to what I want to do, but I don't know how to make my widget look like a table (as in the screenshot above).

Could you help me on that point ?

Thanks a lot !

1 Answer 1

3

Use QListView with

setViewMode(QListView::IconMode);
setFlow(QListView::LeftToRight);

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.