30 August 2023
Ссылка
click to show
click to show
Are the kanban entries stored within a Qt Model, like QTableModel? Then take a look at https://doc.qt.io/qt-6/qcolumnview.html, maybe that is applicable for you and can simplify the view a lot. You just have to provide a Delegate to render individual entries. (There are some examples for this in the Qt docs.)
Павелvertically within a column
Hmm. I’m not that proficient in those manual layouts.
Have you set the internal widget via setWidget()? Also "doesn't work" with no source code is quite vague. Do the internal widgets show up?
Try setting the verticalScrollBarPolicy of the QScrollAreas to Qt.ScrollBarPolicy.ScrollBarAlwaysVisible. That may reveal the source of the "doesn't work" by reasoning on the shown behavior.
Павелthat is, I need to add a QColumnview and already place a QSrollArea on it?
For the UI layout, you would do
QMainWindow
QColumnView
And that's it.
Then simply call setModel() on the QColumnView, and it will render the model column wise
Ссылка
click to show
click to show
This should work, if your data is already in a Qt model, so you can apply https://doc.qt.io/qt-6/model-view-programming.html. If not, this approach may require larger refactorings and re-writing of stuff.
In that case, it may be easier to debug your initial code instead.