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

Home » Public Forums » archive » Re: widget colours
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: widget colours [message #13296 is a reply to message #13294] Tue, 03 November 1998 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
LC's No-Spam Newsreading account (nospam@ifctr.mi.cnr.it) writes:

> We wish the background of the widgets to be coloured.
>
> Apparently this is not a "normal" attribute of a WIDGET_TEXT.
> I solved the problem (for demonstrating a prototype) under Unix and X with
> a statement like :
>
> sct1 = WIDGET_TEXT(scts,XSIZE =8,YSIZE = 15,VALUE = a, resource_name='quad1')
>
> where I define colours in an X resource file with things like
>
> Idl*voe*quad1*background: red
>
> but this mechanism is intrinsically unportable to NT, and the documentation
> gives no hints about colour attributes for text widgets under NT.
>
> Any idea ?
> Other than using a DRAW widget instead of a TEXT widget ?

I think you may be completely out of luck here, as colored text
widgets are not really the "IDL way". :-)

A draw widget with text in it is not really such a bad hack
sometimes, especially if it is written as a compound widget.
You can even "hide" a text widget under the draw widget so
you can pick up typing events, etc. This is a little more
than beginners can usually chew, but you seem to know what
you are doing. :-)

> I would sorely regret to be forced to use another language
> *just* because of this.

No, it seems a rather flimsy excuse. Most of the old timers
here have gotten used to considering capability first and
design second. It's been awhile since we were young enough
to think the correct way. :-)

An alternative may be to use something like Visual Basic
to create some or all of the interface and IDL (through its
Active X component) to display the results. The combination
of VB and IDL can sometimes create promising results.

Cheers,

David

----------------------------------------------------------
David Fanning, Ph.D.
Fanning Software Consulting
E-Mail: davidf@dfanning.com
Phone: 970-221-0438, Toll-Free Book Orders: 1-888-461-0155
Coyote's Guide to IDL Programming: http://www.dfanning.com/
[Message index]
 
Read Message
Read Message
Previous Topic: Re: curvefit hang-ups ?????
Next Topic: widget colours

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

Current Time: Fri Oct 10 23:02:20 PDT 2025

Total time taken to generate the page: 0.88687 seconds