We're giving hints here, not producing free solutions for every problem. You should first try to do something on your own and then if you have particular problems, ask for help. And we are very strict about it when it comes to academic projects like yours.Originally Posted by nupul
But you didn't ask how to modify icon size when the container size changes, you just stated what final behaviour you want to have.ummm, I knew this is the answer, but I wanted to know how to do it![]()
You're probably using QListView so I guess you should reimplement QListView::iconSize() or use QListView::setIconSize() from within resizeEvent (or resize() method reimplementation).
I don't think a snippet is needed heredidn't know this, thanks for the pointer...but can i do so without actually displaying a scrollbar, but buttons, as i mentioned...I'd appreciate if you can help me with some code snippet rather than plain text...it'll help me understand better!Use QAbstractScrollArea::scrollContentsBy() from within a slot connected to the clicked() signal of those buttons. The only problem is implementing buttons themselves
If you want to place them on the inside of the view, you can't use layouts but rather use setGeometry() from resizeEvent to move them to appropriate places. When they are to be outside, layouts should be fine, but you waste some space. Of course you have to make sure the scroll bar is hidden.
Bookmarks