Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.15.1, 6.2.0
-
-
f7a4a79c62daeba9ab5545c5e0a1f36d5e1fce6b (qt/qtbase/dev) 22d74333732ba0d5a5b8fd94f2b539bba989298a (qt/qtbase/6.2) a2797c7ddbcf7b0942b871c145967e92df31bfad (qt/tqtc-qtbase/5.15)
Description
[Code]
#include <QComboBox> #include <QScroller> #include <QAbstractItemView> MainWindow::MainWindow(QWidget *parent) : QMainWindow(parent) { QComboBox *comboBox = new QComboBox(this); for (int i = 0; i < 60; i++) { comboBox->addItem(" item " + QString::number(i + 1)); } QScroller::grabGesture(comboBox->view(), QScroller::LeftMouseButtonGesture); }
[Steps]
1.Click the QComboBox component and scroll the mouse to hide a part of the item above;
2.At this moment, press the left mouse button and drag the QComboBoxListView down;
3.Release the left mouse button, QComboBoxListView will automatically return to position;
4.But the position has been misplaced, and there is a blank underneath;
5.On the contrary, if you drag upwards, there will be a blank space above.
[Hope]
I hope that there will be no blank space on the top or bottom after the scrolling is over
Attachments
For Gerrit Dashboard: QTBUG-94769 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
357025,8 | Take overshoot into account when laying out QAbstractScrollArea | dev | qt/qtbase | Status: MERGED | +2 | 0 |
357173,1 | Overshoot should be considered after QAbstractScrollArea viewport->setGeometry() | dev | qt/qtbase | Status: ABANDONED | 0 | 0 |
360069,8 | Consider layout when scrolling QListView | dev | qt/qtbase | Status: ABANDONED | -1 | 0 |
376590,2 | Take overshoot into account when laying out QAbstractScrollArea | 6.2 | qt/qtbase | Status: MERGED | +2 | 0 |
376591,2 | Take overshoot into account when laying out QAbstractScrollArea | tqtc/lts-5.15 | qt/tqtc-qtbase | Status: MERGED | +2 | 0 |