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

Home » Public Forums » archive » Re: taking the widget plunge. help
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: taking the widget plunge. help [message #21628] Fri, 08 September 2000 01:43 Go to next message
Martin Schultz is currently offline  Martin Schultz
Messages: 515
Registered: August 1997
Senior Member
David Fanning wrote:
>
>
>
> P.S. Let's just say I spent a couple of days writing
> documentation for FSC_PSConfig, *the* best program I've
> ever written, and no one downloads it or uses it. You just
> figure after a while, what's the point?
>

Oh, don't be so disappointed! I would say, you are just way ahead of
time! Wait until a few more people catch up with the niceties of
objects, and I am sure you will see your psconfig being used more and
more.
Also, this probably has to do with the way a lot of code gets written:
copy and paste. So, most people will have some sort of psopen and
psclose in their programs already, and they just copy it into their
new programs without thinking how it could be improved. And when they
really need to produce a beautifully scaled postscript file, it's
usually with the boss standing right behind them, so they wouldn't
dare to try out something new but rather fiddle with the device
keywords manually 6-10 times.

Cheer(s|up),
Martin


--
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[ [[[[[[[
[[ Dr. Martin Schultz Max-Planck-Institut fuer Meteorologie [[
[[ Bundesstr. 55, 20146 Hamburg [[
[[ phone: +49 40 41173-308 [[
[[ fax: +49 40 41173-298 [[
[[ martin.schultz@dkrz.de [[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[ [[[[[[[
Re: taking the widget plunge. help [message #21634 is a reply to message #21628] Thu, 07 September 2000 08:26 Go to previous messageGo to next message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Pavel Romashkin (promashkin@cmdl.noaa.gov) writes:

> I have a different problem. It is so much fun to write them that I am
> beginning to like that better than using them :-)

This, in a nutshell, is *exactly* the problem with objects.
And don't even get me started on documentation, in which
you have to document each and every method in addition to
the usual rigamarole. And, of course, they are so much
fun to write that you have about 50 methods. Sigh...

I usually just give up and console myself with the thought
that at least *my* programs are really cool. Even if no one
else (as a result of my sloth) can figure out how they work. :-(

Cheers,

David

P.S. Let's just say I spent a couple of days writing
documentation for FSC_PSConfig, *the* best program I've
ever written, and no one downloads it or uses it. You just
figure after a while, what's the point?

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: taking the widget plunge. help [message #21643 is a reply to message #21634] Thu, 07 September 2000 00:51 Go to previous messageGo to next message
Martin Schultz is currently offline  Martin Schultz
Messages: 515
Registered: August 1997
Senior Member
Peter Brooker wrote:
>
> I need to write a program to learn how easy/hard IDL widgets are to
> use. I figure that a starting point would be a well documented simple
> program that demostrates how they are to use.
>
> Any suggestions?
>
> thanks-Peter Brooker


Ohh! *Using* widgets is really easy, it's the making that sometimes
causes a little more trouble ;-)

Cheers,
Martin

--
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[ [[[[[[[
[[ Dr. Martin Schultz Max-Planck-Institut fuer Meteorologie [[
[[ Bundesstr. 55, 20146 Hamburg [[
[[ phone: +49 40 41173-308 [[
[[ fax: +49 40 41173-298 [[
[[ martin.schultz@dkrz.de [[
[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[ [[[[[[[
Re: taking the widget plunge. help [message #21652 is a reply to message #21643] Wed, 06 September 2000 13:26 Go to previous messageGo to next message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Peter Brooker (ra5589@email.sps.mot.com) writes:

> I need to write a program to learn how easy/hard IDL widgets are to
> use. I figure that a starting point would be a well documented simple
> program that demostrates how they are to use.
>
> Any suggestions?

I've completely re-written the IDL programming
chapters of my book for the 2nd Edition, which is
due out in October. This includes, in particular,
all the widget programming material. You might
want to try the example widget program I wrote
for this book. It is named Histo_GUI and you
can find it here:

ftp://ftp.dfanning.com/pub/dfanning/outgoing/coyote2nd/histo _gui.pro

That's all you will need if you just want to
study how a program is written. If you want to
run the program, you will need other programs
in the Coyote library. I would just download
all the programs in the coyote2nd directory.
I think all the programs you need are there,
although I haven't done the final run-through
to be absolutely certain. You will definitely
need these files:

colorbar.pro
error_message.pro
fsc_droplist.pro
fsc_fileselect.pro
fsc_inputfield.pro
fsc_plotwindow.pro
fsc_ps_config__define.pro
getcolor.pro
histoimage.pro
loaddata.pro
openimage.pro
pickcolorname.pro
psconfig.pro
pswindow.pro
tvimage.pro

If you need more explanation (other than what appears
in the program comments), you can always read the book. :-)

Best Regards,

David

P.S. Let's just say I wouldn't be using too many programs
in the lib directory as examples. :-(
--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
Re: taking the widget plunge. help [message #21702 is a reply to message #21643] Thu, 07 September 2000 08:02 Go to previous messageGo to next message
promashkin is currently offline  promashkin
Messages: 169
Registered: December 1999
Senior Member
I have a different problem. It is so much fun to write them that I am
beginning to like that better than using them :-)
Cheers,
Pavel

Martin Schultz wrote:
>
> Ohh! *Using* widgets is really easy, it's the making that sometimes
> causes a little more trouble ;-)
>
> Cheers,
> Martin*
Re: taking the widget plunge. help [message #21703 is a reply to message #21634] Mon, 11 September 2000 16:25 Go to previous message
John-David T. Smith is currently offline  John-David T. Smith
Messages: 384
Registered: January 2000
Senior Member
> P.S. Let's just say I spent a couple of days writing
> documentation for FSC_PSConfig, *the* best program I've
> ever written, and no one downloads it or uses it. You just
> figure after a while, what's the point?


I took this as a friendly reminder to check out your new stuff, and I was
frankly amazed at how much work you'd put into the documentation. Really an
astounding effort. I will try to integrate FSC_PSConfig into some of my
programs around here.

One note which I think is instructive. You include a section on customization
where you outline how to directly modify your source to add personal or
company-wide set-up lists. This is a very useful feature, but I think you're
going to cause yourself and potential users grief here. It's a *perfect* place
to flex our object oriented muscles. The problem will be that in a year you'll
think of a great way to redesign it, or maybe RSI makes some changes to device
which prompt a rewrite. Then, either all the users who have made their own
modifications will be out of luck, or you'll be contrained in what kind of
updates you can do. It is exactly these types of situations that scream out for
some sort of object relationship. If, rather than giving direction on how to
change your code, you gave a simple example of INHERIT'ing your class, and
chaining to its setup code, you could fully preserve "forward compatibility" --
i.e. drop-in replacement of your updated code.

Or, since in this case the local setup changes are data-only (no fundamental
method changes), you could simply provide access to an internally growable list
of setups. Inheritance is not even really required.

I haven't looked closely, but a method which allows you to add setup lists
(e.g. self->AddSetup,"Company Viewgraph",/EUROPEAN, FontNameSet="Helvetica"),
would seem to do the trick. This might be called automatically in Init with all
the built-in defaults. A user could INHERIT it, override and chain to AddSetup
for a fully internal solution, or they could use a compound relationship and add
the setups "from the outside" in whatever wrapper routine (or object) they
use.

The details of how set-ups are stored, manipulated, etc., would be hidden, only
the published interface of AddSetup need remain the same (or backwards
compatible anyway... nothing to stop you adding new keywords as new features
become available).

Anyway, it's just a thought. Perhaps you're afraid of scaring off potential
users with objects. You shouldn't be. It's good for them.

JD

--
J.D. Smith /*\ WORK: (607) 255-6263
Cornell University Dept. of Astronomy \*/ (607) 255-5842
304 Space Sciences Bldg. /*\ FAX: (607) 255-5875
Ithaca, NY 14853 \*/
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Structure field concatenation
Next Topic: IDL USERS IN ALBERTA, CANADA

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

Current Time: Wed Oct 08 13:36:31 PDT 2025

Total time taken to generate the page: 0.00422 seconds