GDB/MI (Was: Embedded development)

Roberto Raggi roberto at kdevelop.org
Wed Sep 14 12:06:05 UTC 2005


Hi Vladimir!

On Wednesday 14 September 2005 11:53, Vladimir Prus wrote:
> Yes, but even if I implement delegates on the view side, I'd much prefer if
> the (imaginary) ThreadsAndFrameModel class provided a clean way to find out
> if an item should use this special rendering. Or I should not try to fit
> everything into QAbstractItemModel and just use

QAbstractItemModel provides the method data() and the concept of "Role" that 
can help you to solve the problem. You can create a UserRole and returns a 
QVariant (e.g. item-hints of type whatever..). The Delegate can query the 
model and use the `hint' to draw the item. 

>
>    bool isFrameStackContinuation(const QModelIndex& index);
>
> For a bit of context: when program goes into infinite recursion, it

the model provides the support for "fetching more data". It is need for things 
like the SQL model. Please Vladimir, take a look at
http://doc.trolltech.com/4.0/qabstractitemmodel.html#fetchMore
http://doc.trolltech.com/4.0/qabstractitemmodel.html#canFetchMore
.. and friend

> Ok, good then.
:-)

ciao robe




More information about the KDevelop-devel mailing list