[Qt-interest] QTableView and spans
Malyushytsky, Alex
alex at wai.com
Tue Aug 11 22:01:58 CEST 2009
>> Is it planned to support spans on the model side in future versions?
I am not QT developer, so I can't claim I know anything about QT future.
But I don't see why model is going to be extended to handle data presentation.
According to my understanding the purpose of the model is handling the data. View purpose is to display.
So logic assumption is that model will never be extended to handle view functionality, especially since view already have it implemented.
>> Or is there a special trick I don't know to have such simple spans without writing a
single line of code on the view side?
Since model knows nothing about the view it is attached to (if any), it has no influence on how the data is presented.
View is just notified about data changes by signals.
It means it can't effect how the data is presented in the view.
Regards,
Alex
-----Original Message-----
From: qt-interest-bounces at trolltech.com [mailto:qt-interest-bounces at trolltech.com] On Behalf Of Lars Amsel
Sent: Tuesday, August 11, 2009 7:57 AM
To: qt-interest at trolltech.com
Subject: [Qt-interest] QTableView and spans
Hi,
I want to use a table view with spans. The model behind is a list with
transaction. Each transaction has several actions. I want to display all
actions in that table. The first column should display the transaction itself.
This should look like this (monospaced font)
+----+---------------+
| T1 | action a |
+----+---------------+
| | action x |
| T2 | action y |
| | action z |
+----+---------------+
| T3 | action z |
+----+---------------+
The spans works in Qt 4.5 I am using. What I don't like is, that I have to set
the spans in the view component. I would rather implement this information on
the model size (somehow), but there seems to be no support in Qt itself,
neither in the QAbstractTableModel nor in the QTableView.
Is it planned to support spans on the model side in future versions? Or is
there a special trick I don't know to have such simple spans without writing a
single line of code on the view side?
regards
Lars
_______________________________________________
Qt-interest mailing list
Qt-interest at trolltech.com
http://lists.trolltech.com/mailman/listinfo/qt-interest
---------------------------------------------------------------------------------------------------
Weidlinger Associates, Inc. made the following annotations.
"This message and any attachments are solely for the intended recipient and may contain confidential or privileged information. If you are not the intended recipient, any disclosure, copying, use, or distribution of the information included in this message and any attachments is prohibited. If you have received this communication in error, please notify us by reply e-mail and immediately and permanently delete this message and any attachments. Thank you."
"Please consider our environment before printing this email."
More information about the Qt-interest-old
mailing list