comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Confusion about IDLgrViewgroup
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: Confusion about IDLgrViewgroup [message #77361] Sat, 27 August 2011 13:56 Go to next message
Jianbao is currently offline  Jianbao
Messages: 16
Registered: December 2008
Junior Member
Oh well. Just found a work-around. You can group the attribute objects all together into an array, such as
<code>
attrObj = !null
attrObj = [attrObj, someAttrObj]
</code>
Then, you can destroy all the attribute objects by
<code>
obj_destroy, attrObj
</code>

That's it.
Re: Confusion about IDLgrViewgroup [message #77449 is a reply to message #77361] Mon, 29 August 2011 09:28 Go to previous message
Michael Galloy is currently offline  Michael Galloy
Messages: 1114
Registered: April 2006
Senior Member
On 8/27/11 2:56 PM, Jim wrote:
> Oh well. Just found a work-around. You can group the attribute objects all together into an array, such as
> <code>
> attrObj = !null
> attrObj = [attrObj, someAttrObj]
> </code>
> Then, you can destroy all the attribute objects by
> <code>
> obj_destroy, attrObj
> </code>
>
> That's it.

Yes, this is the workaround.

I think this is a strange case since normally an object is either part
of the hierarchy in which case it is automatically cleaned up or it is
an attribute so it can be added to the IDLgrViewGroup to be cleaned up.

The docs say about the TITLE property of an axis:

> Note: Objects specified via this property are not automatically
> cleaned up when the IDLgrAxis object is destroyed.
>
> The IDLgrText object becomes a child of the IDLgrAxis object;
> therefore, to use the same IDLgrText object for multiple axes, you
> must use multiple IDLgrAxis objects."

So this particular attribute is also a child, but NOT automatically
cleaned up. This makes it necessary to use tricks like your workaround.
I'll have to add a note in the object graphics chapter about this case.

Mike
--
Michael Galloy
www.michaelgalloy.com
Modern IDL, A Guide to Learning IDL: http://modernidl.idldev.com
Research Mathematician
Tech-X Corporation
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: WIDGET_LABEL color
Next Topic: Confusion about IDLgrViewgroup

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 06:28:14 PDT 2025

Total time taken to generate the page: 0.63171 seconds