1
2/*
3 * Code and supporting documentation (c) Copyright 1990 1991 Tektronix, Inc.
4 * 	All Rights Reserved
5 *
6 * This file is a component of an X Window System-specific implementation
7 * of Xcms based on the TekColor Color Management System.  Permission is
8 * hereby granted to use, copy, modify, sell, and otherwise distribute this
9 * software and its documentation for any purpose and without fee, provided
10 * that this copyright, permission, and disclaimer notice is reproduced in
11 * all copies of this software and in supporting documentation.  TekColor
12 * is a trademark of Tektronix, Inc.
13 *
14 * Tektronix makes no representation about the suitability of this software
15 * for any purpose.  It is provided "as is" and with all faults.
16 *
17 * TEKTRONIX DISCLAIMS ALL WARRANTIES APPLICABLE TO THIS SOFTWARE,
18 * INCLUDING THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
19 * PARTICULAR PURPOSE.  IN NO EVENT SHALL TEKTRONIX BE LIABLE FOR ANY
20 * SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER
21 * RESULTING FROM LOSS OF USE, DATA, OR PROFITS, WHETHER IN AN ACTION OF
22 * CONTRACT, NEGLIGENCE, OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
23 * CONNECTION WITH THE USE OR THE PERFORMANCE OF THIS SOFTWARE.
24 *
25 *
26 *	NAME
27 *		XcmsOfCCC.c - Color Conversion Context Querying Routines
28 *
29 *	DESCRIPTION
30 *		Routines to query components of a Color Conversion
31 *		Context structure.
32 *
33 *
34 */
35
36#ifdef HAVE_CONFIG_H
37#include <config.h>
38#endif
39#include "Xlib.h"
40#include "Xcms.h"
41
42
43
44/************************************************************************
45 *									*
46 *			PUBLIC INTERFACES				*
47 *									*
48 ************************************************************************/
49
50/*
51 *	NAME
52 *		XcmsDisplayOfCCC
53 *
54 *	SYNOPSIS
55 */
56
57Display *
58XcmsDisplayOfCCC(
59    XcmsCCC ccc)
60/*
61 *	DESCRIPTION
62 *		Queries the Display of the specified CCC.
63 *
64 *	RETURNS
65 *		Pointer to the Display.
66 *
67 */
68{
69    return(ccc->dpy);
70}
71
72
73/*
74 *	NAME
75 *		XcmsVisualOfCCC
76 *
77 *	SYNOPSIS
78 */
79
80Visual *
81XcmsVisualOfCCC(
82    XcmsCCC ccc)
83/*
84 *	DESCRIPTION
85 *		Queries the Visual of the specified CCC.
86 *
87 *	RETURNS
88 *		Pointer to the Visual.
89 *
90 */
91{
92    return(ccc->visual);
93}
94
95
96/*
97 *	NAME
98 *		XcmsScreenNumberOfCCC
99 *
100 *	SYNOPSIS
101 */
102
103int
104XcmsScreenNumberOfCCC(
105    XcmsCCC ccc)
106/*
107 *	DESCRIPTION
108 *		Queries the screen number of the specified CCC.
109 *
110 *	RETURNS
111 *		screen number.
112 *
113 */
114{
115    return(ccc->screenNumber);
116}
117
118
119/*
120 *	NAME
121 *		XcmsScreenWhitePointOfCCC
122 *
123 *	SYNOPSIS
124 */
125
126XcmsColor *
127XcmsScreenWhitePointOfCCC(
128    XcmsCCC ccc)
129/*
130 *	DESCRIPTION
131 *		Queries the screen white point of the specified CCC.
132 *
133 *	RETURNS
134 *		Pointer to the XcmsColor containing the screen white point.
135 *
136 */
137{
138    return(&ccc->pPerScrnInfo->screenWhitePt);
139}
140
141
142/*
143 *	NAME
144 *		XcmsClientWhitePointOfCCC
145 *
146 *	SYNOPSIS
147 */
148
149XcmsColor *
150XcmsClientWhitePointOfCCC(
151    XcmsCCC ccc)
152/*
153 *	DESCRIPTION
154 *		Queries the client white point of the specified CCC.
155 *
156 *	RETURNS
157 *		Pointer to the XcmsColor containing the client white point.
158 *
159 */
160{
161    return(&ccc->clientWhitePt);
162}
163