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

Home » Public Forums » archive » Re: Color text within WIDGET_TEXT?
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: Color text within WIDGET_TEXT? [message #29143] Sun, 03 February 2002 14:29
Andrew Cool is currently offline  Andrew Cool
Messages: 219
Registered: January 1996
Senior Member
Chia Chang wrote:
>
> I am looking to spice up my text widget.
> Is there a way to make it display color text.
>
> Regards,
> Chia Chang

Hi,

The answer here is probably platform dependent.

Under VMS, it's all too easy by defining X Resources in your
.IDLDE file.

It's taken a coupla minutes to knock up a little text widget
that had a green background in the text entry field, and the colour of
the text that I typed in was red. Gross combination!

I guess the same should work on *NIXy things running X.

Example :

PRO text_widget
base = widget_base(Resource_name='widgettext')
Text_id = widget_text(base,Value=' ',/Edit,$
Resource_name = 'frequency')

Widget_control,base,/real
END

Entries in .IDLDE file:

Idl*widgettext*frequency*Background:green
Idl*widgettext*frequency*Foreground:red


HTH,

Andrew

------------------------------------------------------------ ---------
Andrew D. Cool .->-.
Electromagnetics & Propagation Group `-<-'
Surveillance Systems Division Transmitted on
Defence Science & Technology Organisation 100% recycled
PO Box 1500, Salisbury electrons
South Australia 5108

Phone : 061 8 8259 5740 Fax : 061 8 8259 6673
Email : andrew.cool@dsto.defence.gov.au
------------------------------------------------------------ ---------
Re: Color text within WIDGET_TEXT? [message #29146 is a reply to message #29143] Sun, 03 February 2002 08:10 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
Chia Chang (chia@photon.com) writes:

> I am looking to spice up my text widget.
> Is there a way to make it display color text.

IDL is not really into "spice", I'm afraid. You
would be further ahead spending your time learning
sexy new pick-up lines.

"My, that's a bold looking widget you have there."

Cheers,

Miss Manners
--
David W. Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438, E-mail: david@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: Double-precision plotting doesn't work in object graphics
Next Topic: Simple question on Arrays

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

Current Time: Fri Oct 10 10:19:11 PDT 2025

Total time taken to generate the page: 1.19727 seconds