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

Home » Public Forums » archive » Confusion about IDLgrViewgroup
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Confusion about IDLgrViewgroup [message #77362] Sat, 27 August 2011 08:42 Go to previous message
Jianbao is currently offline  Jianbao
Messages: 16
Registered: December 2008
Junior Member
Hello folks,

I encountered a counterintuitive behavior when I was using IDLgrViewgroup. Here is the code.

<code>
viewgroup = obj_new('IDLgrViewgroup')
xtitle = obj_new('IDLgrText', string = 'x')
viewgroup->add, xtitle
xAxis = obj_new('IDLgrAxis', direction = 0)
xAxis->SetProperty, title = xtitle
</code>

When I ran this piece of code, IDL gave an error message saying that
% IDLGRAXIS::SETPROPERTY: Objects can only have one parent at a time: TITLE

I got this impression from Modern IDL by Michael Galloy that IDLgrViewgroup is useful to contain attribute objects for convenient destruction. But this example shows that if I use an IDLgrText object as an axis title, I have to destroy it explicitly, which seems absolutely dumb. Or am I missing something here?

Thank you very much.
[Message index]
 
Read Message
Read Message
Previous Topic: Re: Confusion about IDLgrViewgroup
Next Topic: Printing array to text file

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

Current Time: Sun Oct 12 11:31:28 PDT 2025

Total time taken to generate the page: 1.04033 seconds