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

Conference bulova::decw_jan-89_to_nov-90

Title:DECWINDOWS 26-JAN-89 to 29-NOV-90
Notice:See 1639.0 for VMS V5.3 kit; 2043.0 for 5.4 IFT kit
Moderator:STAR::VATNE
Created:Mon Oct 30 1989
Last Modified:Mon Dec 31 1990
Last Successful Update:Fri Jun 06 1997
Number of topics:3726
Total number of notes:19516

2987.0. "setting color attr. of ListBoxItem" by MARX::BARLOW () Mon Jun 25 1990 11:38

    
    I am trying to set the color attributes for items in a list box.
    It seems that the list box itself will adopt the colors but the items
    in it and the scroll bar won't.  I saw an old note where someone
    mentioned using XtNumChildren, XtChildren and DwtChildren.
    They said that the Xt calls were defined in DwtPrivate.h.  Well,
    I encluded DwtPrivate.h and called XtChildren.  There seem to be 
    compilation errors in the header file.
    
    So, my questions are :
    	1. is this call documented in formal Digital documentation?
    	 (I can't find it anywhere, and I don't really want to use
    	 unsupported calls.)
    
    	2. will this call do the trick?
    
    Thanks
    Rachael Barlow
     
    
T.RTitleUserPersonal
Name
DateLines
2987.1setting color attr. of ListBoxItemRTL::JUNEMon Jun 25 1990 15:5219
   XtChildren and XtNumChildren are Intrinsics routines (actually macros)
and are documented in the current (R4) Intrinsics manual.  They are 
functionally equivalent to the routines DwtChildren and DwtNumChildren, 
which are documented on pages 3-4 and 3-9 of the Toolkit Routines Reference
Manual (Oct. 1989 version).

>    I saw an old note where someone mentioned using XtNumChildren, 
>    XtChildren and DwtChildren.....
   
   This note probably referred to an indirect method of setting the colors
of each list item.  In a list box, each item is actually a pushbutton
gadget (or maybe widget - I'm not sure) child of the list box.  So, it
is theoretically possible to traverse the list of children obtained
through the routines above, checking each one to see if it is a pushbutton
and setting its colors if so.  Whether or not this method is supported
or may have unwanted side effects is another matter.

Rich
2987.2MARX::BARLOWMon Jun 25 1990 17:122
    thanks for the info.