'\" t .\" SetColC.sgm /main/9 1996/09/08 21:01:53 rws $ .de P! .fl \!!1 setgray .fl \\&.\" .fl \!!0 setgray .fl \" force out current output buffer \!!save /psv exch def currentpoint translate 0 0 moveto \!!/showpage{}def .fl \" prolog .sy sed -e 's/^/!/' \\$1\" bring in postscript file \!!psv restore . .de pF .ie \\*(f1 .ds f1 \\n(.f .el .ie \\*(f2 .ds f2 \\n(.f .el .ie \\*(f3 .ds f3 \\n(.f .el .ie \\*(f4 .ds f4 \\n(.f .el .tm ? font overflow .ft \\$1 .. .de fP .ie !\\*(f4 \{\ . ft \\*(f4 . ds f4\" ' br \} .el .ie !\\*(f3 \{\ . ft \\*(f3 . ds f3\" ' br \} .el .ie !\\*(f2 \{\ . ft \\*(f2 . ds f2\" ' br \} .el .ie !\\*(f1 \{\ . ft \\*(f1 . ds f1\" ' br \} .el .tm ? font underflow .. .ds f1\" .ds f2\" .ds f3\" .ds f4\" .ta 8n 16n 24n 32n 40n 48n 56n 64n 72n .TH "XmSetColorCalculation" 3 .SH "NAME" \fBXmSetColorCalculation\fP \(em A function to set the procedure used for default color calculation "XmSetColorCalculation" "Color functions" "XmSetColorCalculation" .SH "SYNOPSIS" .PP .nf #include \fBXmColorProc \fBXmSetColorCalculation\fP\fR( \fBXmColorProc \fBcolor_proc\fR\fR); .fi .SH "DESCRIPTION" .PP \fBXmSetColorCalculation\fP sets the procedure to calculate default colors\&. This procedure is used to calculate the foreground, top shadow, bottom shadow, and select colors on the basis of a given background color\&. If called with an argument of NULL, it restores the default procedure used to calculate colors\&. .IP "\fIcolor_proc\fP" 10 Specifies the procedure to use for color calculation\&. .PP Following is a description of the \fBXmColorProc\fR type used by \fBXmSetColorCalculation\fP: .PP .nf void (*\fIcolor_proc\fP) (\fIbackground_color, foreground_color, select_color, top_shadow_color, bottom_shadow_color\fP) XColor \fI*background_color\fP; XColor \fI*foreground_color\fP; XColor \fI*select_color\fP; XColor \fI*top_shadow_color\fP; XColor \fI*bottom_shadow_color\fP; \fB\fR(\fBvoid\fR) .fi .PP Specifies the procedure used to calculate default colors\&. The procedure is passed a pointer to an \fBXColor\fP structure representing the background color\&. The \fIpixel\fP, \fIred\fP, \fIgreen\fP, and \fIblue\fP members of this structure are filled in with values that are valid for the current colormap\&. .PP The procedure is passed pointers to \fBXColor\fP structures representing the foreground, select, top shadow, and bottom shadow colors to be calculated\&. The procedure calculates and fills in the \fIred\fP, \fIgreen\fP, and \fIblue\fP members of these structures\&. The procedure should not allocate color cells for any of these colors\&. .IP "\fIbackground_color\fP" 10 Specifies the background color\&. .IP "\fIforeground_color\fP" 10 Specifies the foreground color to be calculated\&. .IP "\fIselect_color\fP" 10 Specifies the select color to be calculated\&. .IP "\fItop_shadow_color\fP" 10 Specifies the top shadow color to be calculated\&. .IP "\fIbottom_shadow_color\fP" 10 Specifies the bottom shadow color to be calculated\&. .SH "RETURN" .PP Returns the color calculation procedure that was used at the time this routine was called\&. .SH "RELATED" .PP \fBXmChangeColor\fP(3), \fBXmGetColors\fP(3), and \fBXmGetColorCalculation\fP(3)\&. .\" created by instant / docbook-to-man, Sun 22 Dec 1996, 20:30