[Interest] TableView in Qt Quick Controls 2
shaan7in at gmail.com
Wed Jun 28 09:49:01 CEST 2017
You don't necessarily need a separate file,just import like this -
import QtQuick.Controls 1.4 as QQC1
import QtQuick.Controls 2.1
// this will be QtQuick Controls 2 Button
On Wed, Jun 28, 2017 at 12:48 PM, Andrew Ialacci <andrew at dkai.dk> wrote:
> Thank you for your time and response!
> I originally tried to use the current / old TableView but noticed when
> including the import in my QML file it also downgraded the other components
> like Button to the old style.
> Putting the QtQuick.Controls 1.4 import and declaring the TableView
> declaration in a separate qml file seems to solve the problem.
> Another question/s:
> For my model I’m using a QAbstractListModel that manages a list of plain,
> NON QObject objects.
> * Should each property of my objects be exposed to QML using named roles /
> roleNames? Is this the correct way to use a TableView from QML?
> StackOverflow has said no
> Yet this presentation by ICS said yes: (slides 5 - 7)
> My goal is to allow a user to show or hide columns at will. So again, if
> it was a table of People, they might want to hide the location column and
> only show Name, Age, and Gender.
> * Can you say if the NEW 5.11(ish) TableView will use the
> QAbstractListModel or the QAbstractTableModel?
> * Will the API be similar to the CURRENT TableView?
> * Will it rely on roleNames to denote columns?
> On 6/26/17, 6:19 PM, "Frederik Gladhorn" <frederik.gladhorn at qt.io> wrote:
> On søndag 25. juni 2017 10.32.27 CEST Andrew Ialacci wrote:
> > Hello,
> > I understand that there is currently no TableView in Qt Quick
> Controls 2.
> > According to this bug report, it’s slated for 5.10:
> > https://bugreports.qt.io/browse/QTBUG-51710
> I just commented on the bug, I doubt we'll get there in time. Simply
> we don't want to see all the issues (especially performance) we had
> with the
> table view again. It'll be a lot of looking into ListView and probably
> a new
> independent item, not based on ListView, I don't know the details. If
> Controls 1 table view is good enough, use it. It mixes nicely with
> Controls 2
> (use import as).
> > Does anyone know if this is still true? Or when 5.10 will be
> 5.10 is scheduled for the end of this year. I'd rather expect this to
> be in
> 5.11 - mid next-year. I hope we'll have something sooner for people to
> with though, let's see.
> > Can anyone think of a way to use a GridView or ListView that would
> > for:
> - Dynamic column contents based on the underlying model.
> > - Rearrange / resize table columns.
> > - Addition or removal of columns at run time.
> > and manipulation of cells.
> > Thanks to everyone for their time and ESPECIALLY to TeamQT!
> > ❤🌻🍍
> Interest mailing list
> Interest at qt-project.org
Shantanu Tushar (UTC +0530)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Interest