1 #ifndef __WIN_CONFIG_H__
2 #define __WIN_CONFIG_H__
4 *Copyright (C) 1994-2000 The XFree86 Project, Inc. All Rights Reserved.
6 *Permission is hereby granted, free of charge, to any person obtaining
7 * a copy of this software and associated documentation files (the
8 *"Software"), to deal in the Software without restriction, including
9 *without limitation the rights to use, copy, modify, merge, publish,
10 *distribute, sublicense, and/or sell copies of the Software, and to
11 *permit persons to whom the Software is furnished to do so, subject to
12 *the following conditions:
14 *The above copyright notice and this permission notice shall be
15 *included in all copies or substantial portions of the Software.
17 *THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
18 *EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
19 *MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
20 *NONINFRINGEMENT. IN NO EVENT SHALL THE XFREE86 PROJECT BE LIABLE FOR
21 *ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
22 *CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
23 *WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
25 *Except as contained in this notice, the name of the XFree86 Project
26 *shall not be used in advertising or otherwise to promote the sale, use
27 *or other dealings in this Software without prior written authorization
28 *from the XFree86 Project.
30 * Authors: Alexander Gottwald
34 #ifdef XWIN_XF86CONFIG
35 #include "../xfree86/parser/xf86Parser.h"
38 /* These are taken from hw/xfree86/common/xf86str.h */
41 CARD32 red
, green
, blue
;
45 float red
, green
, blue
;
55 struct _confscreenrec
*myScreenSection
;
62 int screen
; /* For multi-CRTC cards */
68 pointer commonOptions
;
87 typedef struct _confxvportrec
{
90 } confXvPortRec
, *confXvPortPtr
;
92 typedef struct _confxvadaptrec
{
97 } confXvAdaptorRec
, *confXvAdaptorPtr
;
99 typedef struct _confscreenrec
{
109 confXvAdaptorPtr xvadaptors
;
111 } confScreenRec
, *confScreenPtr
;
123 typedef struct _screenlayoutrec
{
124 confScreenPtr screen
;
128 confScreenPtr bottom
;
137 confScreenPtr refscreen
;
138 } screenLayoutRec
, *screenLayoutPtr
;
140 typedef struct _serverlayoutrec
{
142 screenLayoutPtr screens
;
146 } serverLayoutRec
, *serverLayoutPtr
;
154 #ifdef XWIN_XF86CONFIG
159 /* input devices - keyboard */
160 #ifdef XWIN_XF86CONFIG
172 Bool emulate3buttons
;
173 long emulate3timeout
;
174 } WinCmdlineRec
, *WinCmdlinePtr
;
176 extern WinCmdlineRec g_cmdline
;
178 #ifdef XWIN_XF86CONFIG
179 extern XF86ConfigPtr g_xf86configptr
;
181 extern serverLayoutRec g_winConfigLayout
;
184 * Function prototypes
187 Bool
winReadConfigfile(void);
188 Bool
winConfigFiles(void);
189 Bool
winConfigOptions(void);
190 Bool
winConfigScreens(void);
191 Bool
winConfigKeyboard(DeviceIntPtr pDevice
);
192 Bool
winConfigMouse(DeviceIntPtr pDevice
);
210 OPTV_STRING
, /* a non-empty string */
211 OPTV_ANYSTR
, /* Any string, including an empty one */
227 OptionValueType type
;
230 } OptionInfoRec
, *OptionInfoPtr
;
233 * Function prototypes
236 char *winSetStrOption(pointer optlist
, const char *name
, char *deflt
);
237 int winSetBoolOption(pointer optlist
, const char *name
, int deflt
);
238 int winSetIntOption(pointer optlist
, const char *name
, int deflt
);
239 double winSetRealOption(pointer optlist
, const char *name
, double deflt
);
240 double winSetPercentOption(pointer optlist
, const char *name
, double deflt
);
242 #ifdef XWIN_XF86CONFIG
243 XF86OptionPtr
winFindOption(XF86OptionPtr list
, const char *name
);
244 char *winFindOptionValue(XF86OptionPtr list
, const char *name
);
246 int winNameCompare(const char *s1
, const char *s2
);
247 char *winNormalizeName(const char *s
);
257 Bool emulate3Buttons
;
258 long emulate3Timeout
;
260 } winInfoRec
, *winInfoPtr
;
262 extern winInfoRec g_winInfo
;