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

Home » Public Forums » archive » Re: [Q] IDL 5.1, passing keyword params to subprocedures
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: [Q] IDL 5.1, passing keyword params to subprocedures [message #12086] Sun, 28 June 1998 00:00
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Darran Edmundson writes:

> I am trying to create a setproperty procedure for a class that contains
> several atomic IDL graphics objects. Something along the lines of:
>
> pro myclass::setproperty, _REF_EXTRA = ex
>
> self.axis1 -> setproperty, ['axis1_hide']
> self.axis2 -> setproperty, ['axis2_hide']
> [...]
> end
>
> which should accept calls like the following:
>
> a = obj_new('myclass')
> a->setproperty,axis1_hide=/hide
> a->setproperty,axis2_hide=/hide
>
> This and several variants I have tried don't work. Can you
> see what I am getting at and offer a decent solution?

How about something like this:

pro myclass::setproperty, _Ref_Extra=extra

self.axis1 -> setproperty, _Ref_Extra=extra
self.axis2 -> setproperty, _Ref_Extra=extra
[...]
end

which will accept calls like this:

a = obj_new('myclass')
a->setproperty, /hide

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
E-Mail: davidf@dfanning.com
Phone: 970-221-0438
Coyote's Guide to IDL Programming: http://www.dfanning.com/
[Message index]
 
Read Message
Previous Topic: Re: [Q] structure definition with variable array size
Next Topic: Re: [Q] OOP IDL and the self parameter ...

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

Current Time: Thu Oct 30 11:38:16 PDT 2025

Total time taken to generate the page: 0.04222 seconds