[Qt-interest] setParentItem() is hanging
trinathpujari
trinathpujari at tataelxsi.co.in
Thu Feb 18 12:41:19 CET 2010
Hi Andre,
Thanks for your earliest reply....
Actually we are now trying to replace
QGraphicsItem::setParentItem( ) with QGraphicsScene::addItem(object)
which will add the object directly to the scene but this is also not
working and regarding your query about warning,
> Calling this function on an item that is an ancestor of parent have
undefined behaviour.
No warning is coming in my code. If you know some alternative solution
for the same please help me.
Regards
Trinath
Andre Somers wrote:
> trinathpujari wrote:
>
>> Hi All,
>>
>> When i am using setParentItem(), screen is hanging at the point
>> of setParentItem() function call.
>> Can anybody tell any other way of implementing the setParentItem(
>> ) function.
>>
>> Thanking in Advance
>>
>> Regards
>> Trinath
>>
>>
> It would have been helpful if you would have given slightly more
> context, but I will assume for now that you are refering to
> QGraphicsItem::setParentItem, as that seems to be the only function with
> that name in Qt.
>
> Did you head the warning in the documentation?
> > Calling this function on an item that is an ancestor of parent have
> undefined behaviour.
>
> André
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
>
More information about the Qt-interest-old
mailing list