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

Home » Public Forums » archive » Re: widget_text, CW_FIELD
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_text, CW_FIELD [message #59300 is a reply to message #59297] Mon, 17 March 2008 08:23 Go to previous messageGo to previous message
Michael Galloy is currently offline  Michael Galloy
Messages: 1114
Registered: April 2006
Senior Member
On Mar 17, 8:26 am, steverajiv <Rajiv.Paneersel...@gmail.com> wrote:
> Hi all,
> I am developing a macro language text editor using IDL.
>  I have the following questions:
> 1)Is there any way to add colors to the texts displayed using
> 'widget_text' or 'CW_field' .? (using direct graphics)
> 2)Can I use IDL Object Graphics (eg,'IDLgrText' ) to change text color
> and display the colored text in the text space created by
> 'widget_text'.

You can't use the graphics systems with WIDGET_TEXT. I can think of
two alternatives (not for the faint of heart):

* create a WIDGET_DRAW instead of a WIDGET_TEXT and output your text
into it. If this is the main editing window of your text editor, good
luck. But for a label or single line somewhere it is not too bad.
There are keywords to WIDGET_INFO to get the right background color,
font, width of a given string in pixels, etc.

* if on Unix, use Xdefaults.

I don't see any reasonable "IDL only" solutions if you are trying to
chromo-code the code in your macro language text editor. Maybe there's
something you could use with WIDGET_ACTIVEX if you are on Windows?

Mike
--
www.michaelgalloy.com
Tech-X Corporation
Software Developer II
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: how to draw streamline
Next Topic: GOES Follow-up Question

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

Current Time: Sun Oct 12 16:31:57 PDT 2025

Total time taken to generate the page: 0.00266 seconds