Resizing Items in QListView
Unsolved
General and Desktop
-
Hi,
I have QListView and I want it to resize the items( iconSize() & gridSize() ) when I press ctrl + "+" or ctrl + "-" or ctrl + mousewheel. How should I do that? -
I found a way to set the Ctrl++ & Ctrl+- shortcuts:
QShortcut *shortcutAlbumPlus = new QShortcut(QKeySequence("Ctrl++"), ui->albumView);
shortcutAlbumPlus->setContext(Qt::WidgetShortcut);
connect(shortcutAlbumPlus, SIGNAL(activated()), this, SLOT(ctrlplusEntered()));QShortcut *shortcutAlbumMinus = new QShortcut(QKeySequence("Ctrl+-"), ui->albumView); shortcutAlbumMinus->setContext(Qt::WidgetShortcut); connect(shortcutAlbumMinus, SIGNAL(activated()), this, SLOT(ctrlminusEntered()));
but I have a problem with Ctrl+Roll(mousewheel). how do I know if it is wheeling down or up?