]> Pileus Git - ~andy/gtk/blob - docs/reference/gdk/tmpl/colors.sgml
31a09f72ae079ff9b241ec056b29dc1733ecadfa
[~andy/gtk] / docs / reference / gdk / tmpl / colors.sgml
1 <!-- ##### SECTION Title ##### -->
2 Colormaps and Colors
3
4 <!-- ##### SECTION Short_Description ##### -->
5 Manipulation of colors and colormaps
6
7 <!-- ##### SECTION Long_Description ##### -->
8 <para>
9 These functions are used to modify colormaps.
10 A colormap is an object that contains the mapping
11 between the color values stored in memory and
12 the RGB values that are used to display color
13 values. In general, colormaps only contain
14 significant information for pseudo-color visuals,
15 but even for other visual types, a colormap object
16 is required in some circumstances.
17 </para>
18
19 <para>
20 There are a couple of special colormaps that can
21 be retrieved. The system colormap (retrieved 
22 with gdk_colormap_get_system()) is the default
23 colormap of the system. If you are using GdkRGB,
24 there is another colormap that is important - the
25 colormap in which GdkRGB works, retrieved with
26 gdk_rgb_get_colormap(). However, when using GdkRGB, 
27 it is not generally necessary to allocate colors
28 directly.
29 </para>
30
31 <para>
32 In previous revisions of this interface, a number
33 of functions that take a #GdkColormap parameter
34 were replaced with functions whose names began
35 with "gdk_colormap_". This process will probably
36 be extended somewhat in the future - 
37 gdk_color_white(), gdk_color_black(), and 
38 gdk_color_change() will probably become aliases.
39 </para>
40
41 <!-- ##### SECTION See_Also ##### -->
42 <para>
43
44 </para>
45
46 <!-- ##### SECTION Stability_Level ##### -->
47
48
49 <!-- ##### STRUCT GdkColor ##### -->
50 <para>
51 The #GdkColor structure is used to describe an 
52 allocated or unallocated color.
53 </para>
54
55 @pixel: For allocated colors, the value used to
56   draw this color on the screen.
57 @red: The red component of the color. This is
58   a value between 0 and 65535, with 65535 indicating
59   full intensitiy.
60 @green: The blue component of the color.
61 @blue: The green component of the color.
62
63 <!-- ##### STRUCT GdkColormap ##### -->
64 <para>
65 The colormap structure contains the following public fields.
66 </para>
67
68 @size: For pseudo-color colormaps, the number of colors
69   in the colormap.
70 @colors: An array containing the current values in the
71   colormap. This can be used to map from pixel values
72   back to RGB values. This is only meaningful for
73   pseudo-color colormaps.
74
75 <!-- ##### FUNCTION gdk_colormap_new ##### -->
76 <para>
77 </para>
78
79 @visual: 
80 @allocate: 
81 @Returns: 
82
83
84 <!-- ##### FUNCTION gdk_colormap_ref ##### -->
85 <para>
86
87 </para>
88
89 @cmap: 
90 @Returns: 
91
92
93 <!-- ##### FUNCTION gdk_colormap_unref ##### -->
94 <para>
95
96 </para>
97
98 @cmap: 
99
100
101 <!-- ##### FUNCTION gdk_colormap_get_system ##### -->
102 <para>
103 </para>
104
105 @Returns: 
106
107
108 <!-- ##### FUNCTION gdk_colormap_get_system_size ##### -->
109 <para>
110 </para>
111
112 @Returns: 
113
114
115 <!-- ##### FUNCTION gdk_colormap_change ##### -->
116 <para>
117 </para>
118
119 @colormap: 
120 @ncolors: 
121
122
123 <!-- ##### FUNCTION gdk_colormap_alloc_colors ##### -->
124 <para>
125 </para>
126
127 @colormap: 
128 @colors: 
129 @n_colors: 
130 @writeable: 
131 @best_match: 
132 @success: 
133 @Returns: 
134
135
136 <!-- ##### FUNCTION gdk_colormap_alloc_color ##### -->
137 <para>
138 </para>
139
140 @colormap: 
141 @color: 
142 @writeable: 
143 @best_match: 
144 @Returns: 
145
146
147 <!-- ##### FUNCTION gdk_colormap_free_colors ##### -->
148 <para>
149 </para>
150
151 @colormap: 
152 @colors: 
153 @n_colors: 
154
155
156 <!-- ##### FUNCTION gdk_colormap_query_color ##### -->
157 <para>
158
159 </para>
160
161 @colormap: 
162 @pixel: 
163 @result: 
164
165
166 <!-- ##### FUNCTION gdk_colormap_get_visual ##### -->
167 <para>
168 </para>
169
170 @colormap: 
171 @Returns: 
172
173
174 <!-- ##### FUNCTION gdk_colormap_get_screen ##### -->
175 <para>
176
177 </para>
178
179 @cmap: 
180 @Returns: 
181
182
183 <!-- ##### FUNCTION gdk_colors_store ##### -->
184 <para>
185 </para>
186
187 @colormap: 
188 @colors: 
189 @ncolors: 
190
191
192 <!-- ##### FUNCTION gdk_color_copy ##### -->
193 <para>
194 </para>
195
196 @color: 
197 @Returns: 
198
199
200 <!-- ##### FUNCTION gdk_color_free ##### -->
201 <para>
202 </para>
203
204 @color: 
205
206
207 <!-- ##### FUNCTION gdk_colors_alloc ##### -->
208 <para>
209 </para>
210
211 @colormap: 
212 @contiguous: 
213 @planes: 
214 @nplanes: 
215 @pixels: 
216 @npixels: 
217 @Returns: 
218
219
220 <!-- ##### FUNCTION gdk_colors_free ##### -->
221 <para>
222 </para>
223
224 @colormap: 
225 @pixels: 
226 @npixels: 
227 @planes: 
228
229
230 <!-- ##### FUNCTION gdk_color_white ##### -->
231 <para>
232 </para>
233
234 @colormap: 
235 @color: 
236 @Returns: 
237
238
239 <!-- ##### FUNCTION gdk_color_black ##### -->
240 <para>
241 </para>
242
243 @colormap: 
244 @color: 
245 @Returns: 
246
247
248 <!-- ##### FUNCTION gdk_color_parse ##### -->
249 <para>
250 </para>
251
252 @spec: 
253 @color: 
254 @Returns: 
255
256
257 <!-- ##### FUNCTION gdk_color_alloc ##### -->
258 <para>
259 </para>
260
261 @colormap: 
262 @color: 
263 @Returns: 
264
265
266 <!-- ##### FUNCTION gdk_color_change ##### -->
267 <para>
268 </para>
269
270 @colormap: 
271 @color: 
272 @Returns: 
273
274
275 <!-- ##### FUNCTION gdk_color_equal ##### -->
276 <para>
277 </para>
278
279 @colora: 
280 @colorb: 
281 @Returns: 
282
283
284 <!-- ##### FUNCTION gdk_color_hash ##### -->
285 <para>
286 </para>
287
288 @colora: 
289 @Returns: 
290
291
292 <!-- ##### FUNCTION gdk_color_to_string ##### -->
293 <para>
294
295 </para>
296
297 @color: 
298 @Returns: 
299
300