[Qt-interest] How to SAVE DATA for 'Tree Model '?
Andreas Pakulat
apaku at gmx.de
Wed May 27 11:48:24 CEST 2009
On 27.05.09 15:28:27, Gan Xiebin wrote:
> Hi All,
>
> I'd implement my own tree model base QAbstractItemModel,
> and set data to Nodes( Items ).
> For example, insert child, etc ...
>
> However, when I restart my application, I found that the change disappear.
>
> How should my change be stored ??
However you want, you'll need to write that code yourself, as Qt doesn't
know the internal structure of your model and hence cannot persist it
easily. There's QPersistentModelIndex, but I'm not sure how much of your
own data that would store.
Andreas
--
You need more time; and you probably always will.
More information about the Qt-interest-old
mailing list