1 /************************************************************
2 Copyright (c) 1993 by Silicon Graphics Computer Systems, Inc.
4 Permission to use, copy, modify, and distribute this
5 software and its documentation for any purpose and without
6 fee is hereby granted, provided that the above copyright
7 notice appear in all copies and that both that copyright
8 notice and this permission notice appear in supporting
9 documentation, and that the name of Silicon Graphics not be
10 used in advertising or publicity pertaining to distribution
11 of the software without specific prior written permission.
12 Silicon Graphics makes no representation about the suitability
13 of this software for any purpose. It is provided "as is"
14 without any express or implied warranty.
16 SILICON GRAPHICS DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS
17 SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
18 AND FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON
19 GRAPHICS BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL
20 DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
21 DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
22 OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH
23 THE USE OR PERFORMANCE OF THIS SOFTWARE.
25 ********************************************************/
30 #define XkbAllocClientMap SrvXkbAllocClientMap
31 #define XkbAllocServerMap SrvXkbAllocServerMap
32 #define XkbChangeTypesOfKey SrvXkbChangeTypesOfKey
33 #define XkbCopyKeyTypes SrvXkbCopyKeyTypes
34 #define XkbFreeClientMap SrvXkbFreeClientMap
35 #define XkbFreeServerMap SrvXkbFreeServerMap
36 #define XkbKeyTypesForCoreSymbols SrvXkbKeyTypesForCoreSymbols
37 #define XkbApplyCompatMapToKey SrvXkbApplyCompatMapToKey
38 #define XkbResizeKeyActions SrvXkbResizeKeyActions
39 #define XkbResizeKeySyms SrvXkbResizeKeySyms
40 #define XkbResizeKeyType SrvXkbResizeKeyType
41 #define XkbAllocCompatMap SrvXkbAllocCompatMap
42 #define XkbAllocControls SrvXkbAllocControls
43 #define XkbAllocIndicatorMaps SrvXkbAllocIndicatorMaps
44 #define XkbAllocKeyboard SrvXkbAllocKeyboard
45 #define XkbAllocNames SrvXkbAllocNames
46 #define XkbFreeCompatMap SrvXkbFreeCompatMap
47 #define XkbFreeKeyboard SrvXkbFreeKeyboard
48 #define XkbFreeNames SrvXkbFreeNames
49 #define XkbLatchModifiers SrvXkbLatchModifiers
50 #define XkbLatchGroup SrvXkbLatchGroup
51 #define XkbVirtualModsToReal SrvXkbVirtualModsToReal
52 #define XkbChangeKeycodeRange SrvXkbChangeKeycodeRange
53 #define XkbApplyVirtualModChanges SrvXkbApplyVirtualModChanges
55 #include <X11/extensions/XKBproto.h>
61 typedef struct _XkbInterest
{
65 struct _XkbInterest
*next
;
66 CARD16 extDevNotifyMask
;
67 CARD16 stateNotifyMask
;
68 CARD16 namesNotifyMask
;
69 CARD32 ctrlsNotifyMask
;
70 CARD8 compatNotifyMask
;
72 BOOL actionMessageMask
;
73 CARD16 accessXNotifyMask
;
74 CARD32 iStateNotifyMask
;
75 CARD32 iMapNotifyMask
;
76 CARD16 altSymsNotifyMask
;
78 CARD32 autoCtrlValues
;
79 } XkbInterestRec
, *XkbInterestPtr
;
81 typedef struct _XkbRadioGroup
{
86 CARD8 members
[XkbRGMaxMembers
];
87 } XkbRadioGroupRec
, *XkbRadioGroupPtr
;
89 typedef struct _XkbEventCause
{
95 } XkbEventCauseRec
, *XkbEventCausePtr
;
97 #define XkbSetCauseKey(c,k,e) { (c)->kc= (k),(c)->event= (e),\
98 (c)->mjr= (c)->mnr= 0; \
100 #define XkbSetCauseReq(c,j,n,cl) { (c)->kc= (c)->event= 0,\
101 (c)->mjr= (j),(c)->mnr= (n);\
103 #define XkbSetCauseCoreReq(c,e,cl) XkbSetCauseReq(c,e,0,cl)
104 #define XkbSetCauseXkbReq(c,e,cl) XkbSetCauseReq(c,XkbReqCode,e,cl)
105 #define XkbSetCauseUnknown(c) XkbSetCauseKey(c,0,0)
108 #define _KRG_WARN_TIMER 1
110 #define _SK_TIMEOUT_TIMER 3
111 #define _ALL_TIMEOUT_TIMER 4
114 #define _BEEP_FEATURE_ON 1
115 #define _BEEP_FEATURE_OFF 2
116 #define _BEEP_FEATURE_CHANGE 3
117 #define _BEEP_SLOW_WARN 4
118 #define _BEEP_SLOW_PRESS 5
119 #define _BEEP_SLOW_ACCEPT 6
120 #define _BEEP_SLOW_REJECT 7
121 #define _BEEP_SLOW_RELEASE 8
122 #define _BEEP_STICKY_LATCH 9
123 #define _BEEP_STICKY_LOCK 10
124 #define _BEEP_STICKY_UNLOCK 11
125 #define _BEEP_LED_ON 12
126 #define _BEEP_LED_OFF 13
127 #define _BEEP_LED_CHANGE 14
128 #define _BEEP_BOUNCE_REJECT 15
130 typedef struct _XkbFilter
{
137 int (*filter
) (struct _XkbSrvInfo
* /* xkbi */ ,
138 struct _XkbFilter
* /* filter */ ,
139 unsigned /* keycode */ ,
140 XkbAction
* /* action */
142 struct _XkbFilter
*next
;
143 } XkbFilterRec
, *XkbFilterPtr
;
145 typedef struct _XkbSrvInfo
{
146 XkbStateRec prev_state
;
151 KbdCtrlProcPtr kbdProc
;
153 XkbRadioGroupPtr radioGroups
;
161 double mouseKeysCurve
;
162 double mouseKeysCurveFactor
;
165 CARD8 mouseKeysFlags
;
167 CARD8 mouseKeysCounter
;
169 CARD8 lockedPtrButtons
;
174 KeyCode slowKeyEnableKey
;
176 CARD8 krgTimerActive
;
181 CARD32 lastPtrEventTime
;
182 CARD32 lastShiftEventTime
;
183 OsTimerPtr beepTimer
;
184 OsTimerPtr mouseKeyTimer
;
185 OsTimerPtr slowKeysTimer
;
186 OsTimerPtr bounceKeysTimer
;
187 OsTimerPtr repeatKeyTimer
;
191 XkbFilterPtr filters
;
192 } XkbSrvInfoRec
, *XkbSrvInfoPtr
;
194 #define XkbSLI_IsDefault (1L<<0)
195 #define XkbSLI_HasOwnState (1L<<1)
197 typedef struct _XkbSrvLedInfo
{
206 CARD32 physIndicators
;
208 CARD32 explicitState
;
209 CARD32 effectiveState
;
213 XkbIndicatorMapPtr maps
;
219 CARD32 usesEffective
;
223 CARD32 usedComponents
;
224 } XkbSrvLedInfoRec
, *XkbSrvLedInfoPtr
;
227 * Settings for xkbClientFlags field (used by DIX)
228 * These flags _must_ not overlap with XkbPCF_*
230 #define _XkbClientInitialized (1<<15)
232 #define _XkbWantsDetectableAutoRepeat(c)\
233 ((c)->xkbClientFlags&XkbPCF_DetectableAutoRepeatMask)
236 * Settings for flags field
238 #define _XkbStateNotifyInProgress (1<<0)
241 ProcessInputProc processInputProc
;
242 /* If processInputProc is set to something different than realInputProc,
243 * UNWRAP and COND_WRAP will not touch processInputProc and update only
244 * realInputProc. This ensures that
245 * processInputProc == (frozen ? EnqueueEvent : realInputProc)
247 * WRAP_PROCESS_INPUT_PROC should only be called during initialization,
248 * since it may destroy this invariant.
250 ProcessInputProc realInputProc
;
251 DeviceUnwrapProc unwrapProc
;
252 } xkbDeviceInfoRec
, *xkbDeviceInfoPtr
;
254 #define WRAP_PROCESS_INPUT_PROC(device, oldprocs, proc, unwrapproc) \
255 device->public.processInputProc = proc; \
256 oldprocs->processInputProc = \
257 oldprocs->realInputProc = device->public.realInputProc; \
258 device->public.realInputProc = proc; \
259 oldprocs->unwrapProc = device->unwrapProc; \
260 device->unwrapProc = unwrapproc;
262 #define COND_WRAP_PROCESS_INPUT_PROC(device, oldprocs, proc, unwrapproc) \
263 if (device->public.processInputProc == device->public.realInputProc)\
264 device->public.processInputProc = proc; \
265 oldprocs->processInputProc = \
266 oldprocs->realInputProc = device->public.realInputProc; \
267 device->public.realInputProc = proc; \
268 oldprocs->unwrapProc = device->unwrapProc; \
269 device->unwrapProc = unwrapproc;
271 #define UNWRAP_PROCESS_INPUT_PROC(device, oldprocs, backupproc) \
272 backupproc = device->public.realInputProc; \
273 if (device->public.processInputProc == device->public.realInputProc)\
274 device->public.processInputProc = oldprocs->realInputProc; \
275 device->public.realInputProc = oldprocs->realInputProc; \
276 device->unwrapProc = oldprocs->unwrapProc;
278 extern _X_EXPORT DevPrivateKeyRec xkbDevicePrivateKeyRec
;
280 #define xkbDevicePrivateKey (&xkbDevicePrivateKeyRec)
282 #define XKBDEVICEINFO(dev) ((xkbDeviceInfoPtr)dixLookupPrivate(&(dev)->devPrivates, xkbDevicePrivateKey))
284 extern void xkbUnwrapProc(DeviceIntPtr
, DeviceHandleProc
, pointer
);
286 /***====================================================================***/
288 /***====================================================================***/
290 #define XkbAX_KRGMask (XkbSlowKeysMask|XkbBounceKeysMask)
291 #define XkbAllFilteredEventsMask \
292 (XkbAccessXKeysMask|XkbRepeatKeysMask|XkbMouseKeysAccelMask|XkbAX_KRGMask)
294 /***====================================================================***/
296 extern _X_EXPORT
int XkbReqCode
;
297 extern _X_EXPORT
int XkbEventBase
;
298 extern _X_EXPORT
int XkbKeyboardErrorCode
;
299 extern _X_EXPORT
const char *XkbBaseDirectory
;
300 extern _X_EXPORT
const char *XkbBinDirectory
;
302 extern _X_EXPORT CARD32 xkbDebugFlags
;
304 #define _XkbLibError(c,l,d) /* Epoch fail */
306 /* "a" is a "unique" numeric identifier that just defines which error
307 * code statement it is. _XkbErrCode2(4, foo) means "this is the 4th error
308 * statement in this function". lovely.
310 #define _XkbErrCode2(a,b) ((XID)((((unsigned int)(a))<<24)|((b)&0xffffff)))
311 #define _XkbErrCode3(a,b,c) _XkbErrCode2(a,(((unsigned int)(b))<<16)|(c))
312 #define _XkbErrCode4(a,b,c,d) _XkbErrCode3(a,b,((((unsigned int)(c))<<8)|(d)))
316 extern _X_EXPORT
void XkbUseMsg(void
319 extern _X_EXPORT
int XkbProcessArguments(int /* argc */ ,
324 extern _X_EXPORT Bool
XkbInitPrivates(void);
326 extern _X_EXPORT
void XkbSetExtension(DeviceIntPtr device
,
327 ProcessInputProc proc
);
329 extern _X_EXPORT
void XkbFreeCompatMap(XkbDescPtr
/* xkb */ ,
330 unsigned int /* which */ ,
334 extern _X_EXPORT
void XkbFreeNames(XkbDescPtr
/* xkb */ ,
335 unsigned int /* which */ ,
339 extern _X_EXPORT
int _XkbLookupAnyDevice(DeviceIntPtr
*pDev
,
342 Mask access_mode
, int *xkb_err
);
344 extern _X_EXPORT
int _XkbLookupKeyboard(DeviceIntPtr
*pDev
,
347 Mask access_mode
, int *xkb_err
);
349 extern _X_EXPORT
int _XkbLookupBellDevice(DeviceIntPtr
*pDev
,
352 Mask access_mode
, int *xkb_err
);
354 extern _X_EXPORT
int _XkbLookupLedDevice(DeviceIntPtr
*pDev
,
357 Mask access_mode
, int *xkb_err
);
359 extern _X_EXPORT
int _XkbLookupButtonDevice(DeviceIntPtr
*pDev
,
362 Mask access_mode
, int *xkb_err
);
364 extern _X_EXPORT XkbDescPtr
XkbAllocKeyboard(void
367 extern _X_EXPORT Status
XkbAllocClientMap(XkbDescPtr
/* xkb */ ,
368 unsigned int /* which */ ,
369 unsigned int /* nTypes */
372 extern _X_EXPORT Status
XkbAllocServerMap(XkbDescPtr
/* xkb */ ,
373 unsigned int /* which */ ,
374 unsigned int /* nNewActions */
377 extern _X_EXPORT
void XkbFreeClientMap(XkbDescPtr
/* xkb */ ,
378 unsigned int /* what */ ,
382 extern _X_EXPORT
void XkbFreeServerMap(XkbDescPtr
/* xkb */ ,
383 unsigned int /* what */ ,
387 extern _X_EXPORT Status
XkbAllocIndicatorMaps(XkbDescPtr
/* xkb */
390 extern _X_EXPORT Status
XkbAllocCompatMap(XkbDescPtr
/* xkb */ ,
391 unsigned int /* which */ ,
392 unsigned int /* nInterpret */
395 extern _X_EXPORT Status
XkbAllocNames(XkbDescPtr
/* xkb */ ,
396 unsigned int /* which */ ,
398 int /* nTotalAliases */
401 extern _X_EXPORT Status
XkbAllocControls(XkbDescPtr
/* xkb */ ,
402 unsigned int /* which */
405 extern _X_EXPORT Status
XkbCopyKeyTypes(XkbKeyTypePtr
/* from */ ,
406 XkbKeyTypePtr
/* into */ ,
410 extern _X_EXPORT Status
XkbResizeKeyType(XkbDescPtr
/* xkb */ ,
412 int /* map_count */ ,
413 Bool
/* want_preserve */ ,
414 int /* new_num_lvls */
417 extern _X_EXPORT
void XkbFreeKeyboard(XkbDescPtr
/* xkb */ ,
418 unsigned int /* which */ ,
422 extern _X_EXPORT
void XkbFreeComponentNames(XkbComponentNamesPtr
/* names */ ,
426 extern _X_EXPORT
void XkbSetActionKeyMods(XkbDescPtr
/* xkb */ ,
427 XkbAction
* /* act */ ,
428 unsigned int /* mods */
431 extern _X_EXPORT
unsigned int XkbMaskForVMask(XkbDescPtr
/* xkb */ ,
432 unsigned int /* vmask */
435 extern _X_EXPORT Bool
XkbVirtualModsToReal(XkbDescPtr
/* xkb */ ,
436 unsigned int /* virtua_mask */ ,
437 unsigned int * /* mask_rtrn */
440 extern _X_EXPORT
unsigned int XkbAdjustGroup(int /* group */ ,
441 XkbControlsPtr
/* ctrls */
444 extern _X_EXPORT KeySym
*XkbResizeKeySyms(XkbDescPtr
/* xkb */ ,
449 extern _X_EXPORT XkbAction
*XkbResizeKeyActions(XkbDescPtr
/* xkb */ ,
454 extern _X_EXPORT
void XkbUpdateKeyTypesFromCore(DeviceIntPtr
/* pXDev */ ,
455 KeySymsPtr
/* syms */ ,
456 KeyCode
/* first */ ,
458 XkbChangesPtr
/* pChanges */
461 extern _X_EXPORT
void XkbUpdateDescActions(XkbDescPtr
/* xkb */ ,
462 KeyCode
/* first */ ,
464 XkbChangesPtr
/* changes */
467 extern _X_EXPORT
void XkbUpdateActions(DeviceIntPtr
/* pXDev */ ,
468 KeyCode
/* first */ ,
470 XkbChangesPtr
/* pChanges */ ,
471 unsigned int * /* needChecksRtrn */ ,
472 XkbEventCausePtr
/* cause */
475 extern _X_EXPORT KeySymsPtr
XkbGetCoreMap(DeviceIntPtr
/* keybd */
478 extern _X_EXPORT
void XkbApplyMappingChange(DeviceIntPtr
/* pXDev */ ,
479 KeySymsPtr
/* map */ ,
480 KeyCode
/* firstKey */ ,
482 CARD8
* /* modmap */ ,
483 ClientPtr
/* client */
486 extern _X_EXPORT
void XkbSetIndicators(DeviceIntPtr
/* pXDev */ ,
487 CARD32
/* affect */ ,
488 CARD32
/* values */ ,
489 XkbEventCausePtr
/* cause */
492 extern _X_EXPORT
void XkbUpdateIndicators(DeviceIntPtr
/* keybd */ ,
493 CARD32
/* changed */ ,
494 Bool
/* check_edevs */ ,
495 XkbChangesPtr
/* pChanges */ ,
496 XkbEventCausePtr
/* cause */
499 extern _X_EXPORT XkbSrvLedInfoPtr
XkbAllocSrvLedInfo(DeviceIntPtr
/* dev */ ,
500 KbdFeedbackPtr
/* kf */ ,
501 LedFeedbackPtr
/* lf */ ,
502 unsigned int /* needed_parts */
505 extern _X_EXPORT XkbSrvLedInfoPtr
XkbCopySrvLedInfo(DeviceIntPtr
/* dev */ ,
506 XkbSrvLedInfoPtr
/* src */ ,
507 KbdFeedbackPtr
/* kf */ ,
508 LedFeedbackPtr
/* lf */
511 extern _X_EXPORT XkbSrvLedInfoPtr
XkbFindSrvLedInfo(DeviceIntPtr
/* dev */ ,
512 unsigned int /* class */ ,
513 unsigned int /* id */ ,
514 unsigned int /* needed_parts */
517 extern _X_EXPORT
void XkbApplyLedNameChanges(DeviceIntPtr
/* dev */ ,
518 XkbSrvLedInfoPtr
/* sli */ ,
519 unsigned int /* changed_names */ ,
520 xkbExtensionDeviceNotify
* /* ed */
522 XkbChangesPtr
/* changes */ ,
523 XkbEventCausePtr
/* cause */
526 extern _X_EXPORT
void XkbApplyLedMapChanges(DeviceIntPtr
/* dev */ ,
527 XkbSrvLedInfoPtr
/* sli */ ,
528 unsigned int /* changed_maps */ ,
529 xkbExtensionDeviceNotify
* /* ed */
531 XkbChangesPtr
/* changes */ ,
532 XkbEventCausePtr
/* cause */
535 extern _X_EXPORT
void XkbApplyLedStateChanges(DeviceIntPtr
/* dev */ ,
536 XkbSrvLedInfoPtr
/* sli */ ,
537 unsigned int /* changed_leds */ ,
538 xkbExtensionDeviceNotify
*
540 XkbChangesPtr
/* changes */ ,
541 XkbEventCausePtr
/* cause */
544 extern _X_EXPORT
void XkbFlushLedEvents(DeviceIntPtr
/* dev */ ,
545 DeviceIntPtr
/* kbd */ ,
546 XkbSrvLedInfoPtr
/* sli */ ,
547 xkbExtensionDeviceNotify
* /* ed */ ,
548 XkbChangesPtr
/* changes */ ,
549 XkbEventCausePtr
/* cause */
552 extern _X_EXPORT
unsigned int XkbIndicatorsToUpdate(DeviceIntPtr
/* dev */ ,
554 /* state_changes */ ,
555 Bool
/* enabled_ctrl_changes */
558 extern _X_EXPORT
void XkbComputeDerivedState(XkbSrvInfoPtr
/* xkbi */
561 extern _X_EXPORT
void XkbCheckSecondaryEffects(XkbSrvInfoPtr
/* xkbi */ ,
562 unsigned int /* which */ ,
563 XkbChangesPtr
/* changes */ ,
564 XkbEventCausePtr
/* cause */
567 extern _X_EXPORT
void XkbCheckIndicatorMaps(DeviceIntPtr
/* dev */ ,
568 XkbSrvLedInfoPtr
/* sli */ ,
569 unsigned int /* which */
572 extern _X_EXPORT
unsigned int XkbStateChangedFlags(XkbStatePtr
/* old */ ,
573 XkbStatePtr
/* new */
576 extern _X_EXPORT
void XkbSendStateNotify(DeviceIntPtr
/* kbd */ ,
577 xkbStateNotify
* /* pSN */
580 extern _X_EXPORT
void XkbSendMapNotify(DeviceIntPtr
/* kbd */ ,
581 xkbMapNotify
* /* ev */
584 extern _X_EXPORT
int XkbComputeControlsNotify(DeviceIntPtr
/* kbd */ ,
585 XkbControlsPtr
/* old */ ,
586 XkbControlsPtr
/* new */ ,
587 xkbControlsNotify
* /* pCN */ ,
588 Bool
/* forceCtrlProc */
591 extern _X_EXPORT
void XkbSendControlsNotify(DeviceIntPtr
/* kbd */ ,
592 xkbControlsNotify
* /* ev */
595 extern _X_EXPORT
void XkbSendCompatMapNotify(DeviceIntPtr
/* kbd */ ,
596 xkbCompatMapNotify
* /* ev */
599 extern _X_EXPORT
void XkbHandleBell(BOOL
/* force */ ,
600 BOOL
/* eventOnly */ ,
601 DeviceIntPtr
/* kbd */ ,
602 CARD8
/* percent */ ,
606 WindowPtr
/* pWin */ ,
607 ClientPtr
/* pClient */
610 extern _X_EXPORT
void XkbSendAccessXNotify(DeviceIntPtr
/* kbd */ ,
611 xkbAccessXNotify
* /* pEv */
614 extern _X_EXPORT
void XkbSendNamesNotify(DeviceIntPtr
/* kbd */ ,
615 xkbNamesNotify
* /* ev */
618 extern _X_EXPORT
void XkbSendActionMessage(DeviceIntPtr
/* kbd */ ,
619 xkbActionMessage
* /* ev */
622 extern _X_EXPORT
void XkbSendExtensionDeviceNotify(DeviceIntPtr
/* kbd */ ,
623 ClientPtr
/* client */ ,
624 xkbExtensionDeviceNotify
* /* ev */
627 extern _X_EXPORT
void XkbSendNotification(DeviceIntPtr
/* kbd */ ,
628 XkbChangesPtr
/* pChanges */ ,
629 XkbEventCausePtr
/* cause */
632 extern _X_EXPORT
void XkbProcessKeyboardEvent(DeviceEvent
* /* event */ ,
633 DeviceIntPtr
/* keybd */
636 extern _X_EXPORT
void XkbHandleActions(DeviceIntPtr
/* dev */ ,
637 DeviceIntPtr
/* kbd */ ,
638 DeviceEvent
* /* event */
641 extern _X_EXPORT Bool
XkbEnableDisableControls(XkbSrvInfoPtr
/* xkbi */ ,
642 unsigned long /* change */ ,
643 unsigned long /* newValues */ ,
644 XkbChangesPtr
/* changes */ ,
645 XkbEventCausePtr
/* cause */
648 extern _X_EXPORT
void AccessXInit(DeviceIntPtr
/* dev */
651 extern _X_EXPORT Bool
AccessXFilterPressEvent(DeviceEvent
* /* event */ ,
652 DeviceIntPtr
/* keybd */
655 extern _X_EXPORT Bool
AccessXFilterReleaseEvent(DeviceEvent
* /* event */ ,
656 DeviceIntPtr
/* keybd */
659 extern _X_EXPORT
void AccessXCancelRepeatKey(XkbSrvInfoPtr
/* xkbi */ ,
663 extern _X_EXPORT
void AccessXComputeCurveFactor(XkbSrvInfoPtr
/* xkbi */ ,
664 XkbControlsPtr
/* ctrls */
667 extern _X_EXPORT XkbInterestPtr
XkbFindClientResource(DevicePtr
/* inDev */ ,
668 ClientPtr
/* client */
671 extern _X_EXPORT XkbInterestPtr
XkbAddClientResource(DevicePtr
/* inDev */ ,
672 ClientPtr
/* client */ ,
676 extern _X_EXPORT
int XkbRemoveResourceClient(DevicePtr
/* inDev */ ,
680 extern _X_EXPORT
int XkbDDXAccessXBeep(DeviceIntPtr
/* dev */ ,
681 unsigned int /* what */ ,
682 unsigned int /* which */
685 extern _X_EXPORT
int XkbDDXUsesSoftRepeat(DeviceIntPtr
/* dev */
688 extern _X_EXPORT
void XkbDDXKeybdCtrlProc(DeviceIntPtr
/* dev */ ,
689 KeybdCtrl
* /* ctrl */
692 extern _X_EXPORT
void XkbDDXChangeControls(DeviceIntPtr
/* dev */ ,
693 XkbControlsPtr
/* old */ ,
694 XkbControlsPtr
/* new */
697 extern _X_EXPORT
void XkbDDXUpdateDeviceIndicators(DeviceIntPtr
/* dev */ ,
698 XkbSrvLedInfoPtr
/* sli */ ,
699 CARD32
/* newState */
702 extern _X_EXPORT
int XkbDDXTerminateServer(DeviceIntPtr
/* dev */ ,
704 XkbAction
* /* act */
707 extern _X_EXPORT
int XkbDDXSwitchScreen(DeviceIntPtr
/* dev */ ,
709 XkbAction
* /* act */
712 extern _X_EXPORT
int XkbDDXPrivate(DeviceIntPtr
/* dev */ ,
714 XkbAction
* /* act */
717 extern _X_EXPORT
void XkbDisableComputedAutoRepeats(DeviceIntPtr
/* pXDev */ ,
718 unsigned int /* key */
721 extern _X_EXPORT
void XkbSetRepeatKeys(DeviceIntPtr
/* pXDev */ ,
726 extern _X_EXPORT
int XkbLatchModifiers(DeviceIntPtr
/* pXDev */ ,
731 extern _X_EXPORT
int XkbLatchGroup(DeviceIntPtr
/* pXDev */ ,
735 extern _X_EXPORT
void XkbClearAllLatchesAndLocks(DeviceIntPtr
/* dev */ ,
736 XkbSrvInfoPtr
/* xkbi */ ,
738 XkbEventCausePtr
/* cause */
741 extern _X_EXPORT
void XkbGetRulesDflts(XkbRMLVOSet
* /* rmlvo */
744 extern _X_EXPORT
void XkbFreeRMLVOSet(XkbRMLVOSet
* /* rmlvo */ ,
748 extern _X_EXPORT
void XkbSetRulesDflts(XkbRMLVOSet
* /* rmlvo */
751 extern _X_EXPORT
void XkbDeleteRulesDflts(void
754 extern _X_EXPORT
void XkbDeleteRulesUsed(void
757 extern _X_EXPORT
int SProcXkbDispatch(ClientPtr
/* client */
760 extern _X_EXPORT XkbGeometryPtr
XkbLookupNamedGeometry(DeviceIntPtr
/* dev */ ,
762 Bool
* /* shouldFree */
765 extern _X_EXPORT
void XkbConvertCase(KeySym
/* sym */ ,
766 KeySym
* /* lower */ ,
770 extern _X_EXPORT Status
XkbChangeKeycodeRange(XkbDescPtr
/* xkb */ ,
773 XkbChangesPtr
/* changes */
776 extern _X_EXPORT
void XkbFreeSrvLedInfo(XkbSrvLedInfoPtr
/* sli */
779 extern _X_EXPORT
void XkbFreeInfo(XkbSrvInfoPtr
/* xkbi */
782 extern _X_EXPORT Status
XkbChangeTypesOfKey(XkbDescPtr
/* xkb */ ,
785 unsigned int /* groups */ ,
786 int * /* newTypesIn */ ,
787 XkbMapChangesPtr
/* changes */
790 extern _X_EXPORT
int XkbKeyTypesForCoreSymbols(XkbDescPtr
/* xkb */ ,
791 int /* map_width */ ,
792 KeySym
* /* core_syms */ ,
793 unsigned int /* protected */ ,
794 int * /* types_inout */ ,
795 KeySym
* /* xkb_syms_rtrn */
798 extern _X_EXPORT Bool
XkbApplyCompatMapToKey(XkbDescPtr
/* xkb */ ,
800 XkbChangesPtr
/* changes */
803 extern _X_EXPORT Bool
XkbApplyVirtualModChanges(XkbDescPtr
/* xkb */ ,
804 unsigned int /* changed */ ,
805 XkbChangesPtr
/* changes */
808 extern _X_EXPORT
void XkbSendNewKeyboardNotify(DeviceIntPtr
/* kbd */ ,
809 xkbNewKeyboardNotify
* /* pNKN */
812 extern Bool
XkbCopyKeymap(XkbDescPtr
/* dst */ ,
813 XkbDescPtr
/* src */ );
815 extern _X_EXPORT Bool
XkbCopyDeviceKeymap(DeviceIntPtr
/* dst */ ,
816 DeviceIntPtr
/* src */ );
818 extern void XkbFilterEvents(ClientPtr
/* pClient */ ,
822 extern int XkbGetEffectiveGroup(XkbSrvInfoPtr
/* xkbi */ ,
823 XkbStatePtr
/* xkbstate */ ,
824 CARD8
/* keycode */ );
826 extern void XkbMergeLockedPtrBtns(DeviceIntPtr
/* master */ );
828 extern void XkbFakeDeviceButton(DeviceIntPtr
/* dev */ ,
833 #include "xkbrules.h"
835 #define _XkbListKeycodes 0
836 #define _XkbListTypes 1
837 #define _XkbListCompat 2
838 #define _XkbListSymbols 3
839 #define _XkbListGeometry 4
840 #define _XkbListNumComponents 5
842 extern _X_EXPORT
unsigned int XkbDDXLoadKeymapByNames(DeviceIntPtr
/* keybd */ ,
845 unsigned int /* want */ ,
846 unsigned int /* need */ ,
850 /* keymapNameRtrn */ ,
851 int /* keymapNameRtrnLen */
854 extern _X_EXPORT Bool
XkbDDXNamesFromRules(DeviceIntPtr
/* keybd */ ,
856 XkbRF_VarDefsPtr
/* defs */ ,
857 XkbComponentNamesPtr
/* names */
860 extern _X_EXPORT XkbDescPtr
XkbCompileKeymap(DeviceIntPtr
/* dev */ ,
861 XkbRMLVOSet
* /* rmlvo */
864 #endif /* _XKBSRV_H_ */