[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference noted::motif

Title:"OSF/Motif" is a trademark
Notice:MOTIF kit note in 7.*
Moderator:GOOEY::GRASS
Created:Mon Aug 07 1989
Last Modified:Thu Jun 05 1997
Last Successful Update:Fri Jun 06 1997
Number of topics:5973
Total number of notes:24620

5970.0. "Text colors for XtVaSetValue, new feature?" by TPOVC::MOBBYLIN (Network Navigator) Mon Jun 02 1997 00:47

    I am very new to Motif concept. My customer wants to program
    XtVaSetValue to have text with different colors. Can Digital UNIX or
    OpenVMS support this one? Which version of Motif, X11R? can do it?
    He notices me that Motif V2.0 can program it, Is it true?
    
    regards,
    Mobby.
T.RTitleUserPersonal
Name
DateLines
5970.1GRIM::MESSENGERBob MessengerMon Jun 02 1997 11:519
Any version of Motif should be able to handle this as long as the Xt
intrinsics are R4 or later (which they are for all version of DECwindows
Motif for OpenVMS).  Just set the foreground resource for the text widget,
label or whatever widget that is displaying the text.  To draw blue text
in a label widget called labelw, for example:

	XtVaSetValues( labelw, XtNforeground, "blue", NULL);

				-- Bob
5970.2different color for different positions of widget?TPOVC::MOBBYLINNetwork NavigatorMon Jun 02 1997 22:495
    The customer tells me that he needs the separate color for some fields
    or positions in the same widget or label. Is it possible?
    
    regards,
    Mobby
5970.3GRIM::MESSENGERBob MessengerTue Jun 03 1997 09:384
That's not possible in Motif 1.2, as far as I know.  You'd have to split
up your widget into smaller widgets, one for each color.

				-- Bob