1XmColorSelector(3X)                                        XmColorSelector(3X)
2
3
4

NAME

6       The Color Selector widget
7

SYNOPSIS

9       #include <Xm/ColorS.h>
10

DESCRIPTION

12       The  Color  Selector  widget  allows  users  to choose a color by using
13       either a set of RGB sliders or choosing  from  a  list  of  all  colors
14       available  in  the  rgb database. The name or rgb value, as well as the
15       color selected, are dynamically displayed to the user as they pick  and
16       choose different colors.
17

Normal Resources

19       Name                Class           Type                  Initial Value
20       blueSliderLabel     SliderLabel     XmString              "Blue"
21       colorListTogLabel   TogLabel        XmString              "Color List"
22       colorMode           ColorMode       XiColorMode           XmScaleMode
23       colorName           String          String                White
24       fileReadError       FileReadError   XmString              "Could not read
25                                                                  RGB.txt file"
26       greenSliderLabel    SliderLabel     XmString              "Green"
27       marginHeight        MarginHeight    VerticalDimension     2
28       marginWidth         MarginWidth     HorizontalDimension   2
29       noCellError         NoCellError     XmString              "No Color Cell
30                                                                  Available"
31       redSliderLabel      SliderLabel     XmString              "Red"
32       rgbFile             String          String                /usr/share/X11/rgb.txt
33       sliderTogLabel      TogLabel        XmString              "Color Sliders"
34
35       All  resource  names  begin with XmN and all resource class names begin
36       with XmC.
37

blueSliderLabel

39       The string appearing for the label of the blue slider
40

colorListTogLabel

42       The string appearing for the label of the color list toggle
43

colorMode

45       The color list can be used in either slider or  list  mode.  Acceptable
46       values  are XmListMode and XmScaleMode. This resource allows the appli‐
47       cation to determine the mode that the color selector should use when it
48       is  created. After this point, the user may freely change modes by uti‐
49       lizing a pair of radio buttons in the color selector. A type  converter
50       is  registered  to  convert  the  strings "ScaleMode" and "ListMode" to
51       color modes for use with the resource database.
52

colorName

54       This resource controls the color name that is  currently  displayed  to
55       the  user.  This value can be modified to change the color displayed in
56       the color selector or queried to find the color the user has  selected.
57       The  string  returned  here  is either a color name or a pound sign (#)
58       followed by a set of rgb values as specified in the Xlib specification.
59

fileReadError

61       The message which is displayed when the Color Selector cannot read  the
62       rgb.txt  file.  The  message  is  displayed at the top of the window in
63       which the color list would normally appear.
64

greenSliderLabel

66       The string appearing for the label of the green slider
67

marginHeight

marginWidth

70       This is the amount of space left between each of the  children  in  the
71       color  selector  and  between  the outside children and the edge of the
72       color selector widget.
73

noCellError

75       This resource controls the message which is  displayed  in  the  sample
76       color  field when the Color Selector cannot allocate a read/write color
77       cell
78

redSliderLabel

80       The string appearing for the label of the red slider
81

rgbFile

83       This is the name of the file to be loaded,  which  contains  the  valid
84       color  names.  Each of these names is sorted and the duplicates removed
85       before being shown to the user.
86

sliderTogLabel

88       The string appearing for the label of the color slider toggle
89

Convenience Routine

91
92
93
94

XmCreateColorSelector - Widget creation convenience routine

96       Widget XmCreateColorSelector(
97                        Widget parent,     /* Widget id of parent for ColorSelector */
98                        String name,       /* Name of the created widget */
99                        ArgList args,      /* argument list */
100                        Cardinal num_args  /* number of items in argument list */
101                        )
102
103

Children

105       The color selector is composed of many sub-widgets. As  with  all  wid‐
106       gets,  most  values are passed to this widget through the argument list
107       at creation time or via set values and are passed to each of this  wid‐
108       get's  children,  although get values requests must be made on a child-
109       by-child basis. The children of the color selector  are  listed  below.
110       The  documentation  for  each of the children should be consulted for a
111       list of resources for each child.
112
113
114       XmColorSelector<named by application>
115
116            XmScrolledWindowscrolled
117
118            XmScrollBarListvScrollBar
119
120            XmScrollBarListhScrollBar
121
122            XmListlist
123
124            XmButtonBoxbuttonBox
125
126            XmScalescale
127
128            XmLabelGadgetscale_title
129
130            XmScrollBarscale_scrollbar
131
132            XmRowColumnradioBox
133
134            XmToggleButtoncolorListToggle
135
136            XmToggleButtoncolorSlidersToggle
137
138            XmFramecolorFrame
139
140            XmLabelcolorWindow
141
143       Copyright (c) 1992 by Integrated Computer Solutions, Inc.
144
145
146
147                                                           XmColorSelector(3X)
Impressum