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

Home » Public Forums » archive » IDL 5.2 GUI Builder Tutorial ?
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
IDL 5.2 GUI Builder Tutorial ? [message #15556] Thu, 20 May 1999 00:00 Go to next message
Karl Young is currently offline  Karl Young
Messages: 31
Registered: April 1996
Member
In my style of always looking for a quick fix I was wondering if anyone
knew of any kind of tutorial on the GUI builder in IDL 5.2. From some
brief fiddling it looks reasonably easy to use but I'd like to see a
couple of simple examples of building an interface and filling in the
code so's to get started on the right foot. I'd be amazed if David
didn't have something up his sleeve but I haven't scoured his web page
very thouroughly lately. Thanks for any tips (including any advice to
stay away from the GUI builder ...)

-- KY

Karl Young
UCSF,VA Medical Center
MRS Unit (114M)
4150 Clement Street
San Francisco, CA 94121

Email: kyoung@itsa.ucsf.edu
Phone: (415) 750-2158 lab
(415) 750-9463 home
FAX: (415) 668-2864
Re: IDL 5.2 GUI Builder Tutorial ? [message #15619 is a reply to message #15556] Thu, 27 May 1999 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Mike Schienle (mgs@ivsoftware.com) writes:

> Let me jump on this bandwagon with a rant of my own. I just spent a year
> dealing with a very disgusting usage of WIDED. Our tax dollars (in the
> U.S.) have been used to create this:

Your honor, I rest my case.

Cheers,

David

--
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: IDL 5.2 GUI Builder Tutorial ? [message #15621 is a reply to message #15556] Thu, 27 May 1999 00:00 Go to previous message
mgs is currently offline  mgs
Messages: 144
Registered: March 1995
Senior Member
In article <7ij5ea$ckr$1@nnrp1.deja.com>, rmlongfield@my-deja.com wrote:

> Hi Karl and all,
> I haven't seen the GUI tool but when I first started with widgets, I
> used WIDED, which I thought was useful at least in getting used to
> widgets and how the programs should look.
...

Let me jump on this bandwagon with a rant of my own. I just spent a year
dealing with a very disgusting usage of WIDED. Our tax dollars (in the
U.S.) have been used to create this:

base1 = WIDGET_BASE(base0, /ROW)
label1 = WIDGET_LABEL(base1, VALUE = 'Input L0 file ')
gwid.ifile = WIDGET_TEXT(base1, /EDIT, XSIZE = 40, $
VALUE = '')
gwid.select = WIDGET_BUTTON(base1, VALUE='Select')

base1 = WIDGET_BASE(base0, /ROW)
label1 = WIDGET_LABEL(base1, VALUE = 'Output directory')
gwid.outdir = WIDGET_TEXT(base1, /EDIT, XSIZE = 40, VALUE = './')
gwid.oselect = WIDGET_BUTTON(base1, VALUE='Select')

label1 = WIDGET_LABEL (base0, VALUE=' ')

base1 = WIDGET_BASE(base0, /ROW)
label1 = WIDGET_LABEL(base1, VALUE="Log file (for submit only) :")
gwid.logfile = WIDGET_TEXT(base1, /EDIT, VALUE='/dev/null', XS=35)

You might be thinking "Oh that's just someone's quick attempt at
understanding something." You'd be wrong, because this is production code
being used in the SeaDAS project by NASA and released to the public. This
is a random file selected from 3 MB of this crap. I was the lucky person
that had to add another satellite into this mess for a different company.
It took a hell of a lot longer than it should have because of this useless
naming. If you ever think your project will be used by someone other than
yourself, think about the savings you could accomplish by doing the right
thing from the start. Unfortunately, NASA has created a sinkhole and ought
to be embarrassed for ever letting this project out in its current form.
This example came from a file of 160+ lines with two lines of generic
comments.

Before I go tilt at another windmill, let me suggest an IDL Style Guide
that I put together earlier this year. It was written about 4 years ago,
but cleaned up and put on the web in January. It's available at
<http://www.ivsoftware.com/IDL_Style.html>. I'd like to get some feedback
to make it an acceptable document for others to use, as well.

--
Mike Schienle Interactive Visuals, Inc.
mgs@ivsoftware.com Remote Sensing and Image Processing
http://www.ivsoftware.com/ Analysis and Application Development
Re: IDL 5.2 GUI Builder Tutorial ? [message #15624 is a reply to message #15556] Thu, 27 May 1999 00:00 Go to previous message
rmlongfield is currently offline  rmlongfield
Messages: 68
Registered: August 1998
Member
Hi Karl and all,
I haven't seen the GUI tool but when I first started with widgets, I
used WIDED, which I thought was useful at least in getting used to
widgets and how the programs should look. I also found it useful in
learning how to position items ON the screen. The connection of bases
and subbases and buttons and draw windows was very confusing.
This tool helped in this respect. It was also useful, as was mentioned,
in getting used to the proper syntax of a WIDGET definition.
I must, however, agree with David when it comes to actually using the
resulting program to do something. I recall putting print statements in
the event handlers so that at least I could find out where the program
went when I pressed on a button.

In article <MPG.11af0de4659f2d9897b3@news.frii.com>,
davidf@dfanning.com (David Fanning) wrote:
> Karl Young (kyoung@itsa.ucsf.edu) writes:
> ---about the GUI Builder ---------
> But, of course, the code doesn't *do* anything. All the
> event handlers are stubbed out "shells", there are no
> positional or keyword parameters defined to get data into
> the program, no provision for passing information around
> in the widget program, etc. Oh, oh. Bad news here. You
> are going to have to learn some widget programming anyway
> or you aren't going to be able to get any but the
> very simplest programs to work!

The biggest "paradym shift" (as I would call it, if only I could spell
it right) was the understanding that the flow of a program was no longer
from top to bottom. The main program code, which defines everything,
ran from top to bottom. This makes the widget window that appears on the
monitor. But the "action", the things that you want to happen, all
are located in the event handler code, which had to be placed ABOVE the
main program. This part was not included in WIDED and I suspect it
isn't in the GUI either.
The simplest widget I have is one that draws an image and has a delete
button on the bottom. This I can write in five minutes. (After about a
year of learning IDL and widget programming, but I am pretty slow, I
think). I got sidetracked badly with compound widgets, though others
find them easy, it seems. Learning to use the UVALUE was also a major
achievement (here's where David's book was particularly handy).

Do a widget search on this group. There's lots of stuff.

Anyhow, good luck!
Rose



--== Sent via Deja.com http://www.deja.com/ ==--
---Share what you know. Learn what you don't.---
Re: IDL 5.2 GUI Builder Tutorial ? [message #15626 is a reply to message #15556] Wed, 26 May 1999 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Karl Young (kyoung@itsa.ucsf.edu) writes:

> So despite the fact that experts like David
> sneer at we widget challenged weaklings,
> I'm now convinced that the GUI-builder
> has its place.

Now, I don't recall sneering and I *certainly* believe the
GUI-Builder has a place. I think we just disagree about
where that place is. :-)

Cheers,

David

P.S. And like Jonas, I am looking forward to future versions
of the GUI-Builder too. :-)

--
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
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Including files
Next Topic: Anyone called NCSA Java HDF server from IDL?

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

Current Time: Wed Oct 08 15:47:42 PDT 2025

Total time taken to generate the page: 0.00771 seconds