Scroll to navigation

XGetDeviceKeyMapping(3X11) X FUNCTIONS XGetDeviceKeyMapping(3X11)

̾??

XGetDeviceKeyMapping, XChangeDeviceKeyMapping - ?ǥХ????Υ????Υޥåԥ󥰤??䤤???碌???ѹ????Ԥʤ?

????

XChangeDeviceKeyMapping(display, device, first_keycode, keysyms_per_keycode, keysyms, keycode_count)


Display *display;
XDevice *device;
int first_keycode;
int keysyms_per_keycode;
KeySym *keysyms;
int keycode_count; KeySym *XGetDeviceKeyMapping(display, device, first_keycode, keycode_count, keysyms_per_keycode_return)
Display *display;
XDevice *device;
KeyCode first_keycode;
int keycode_count;
int *keysyms_per_keycode_return;

??????

X ?????Фؤ???³?????ꤹ?롣
?????ޥåԥ󥰤??䤤???碌???뤤???ѹ????оݤȤʤ??ǥХ????????ꤹ?롣
?֤??????ǽ??Υ????????ɤ????ꤹ?롣
?֤????롢???뤤???ѹ??????륭???????ɤο??????ꤹ?롣
?????????ɤ??????Υ????????ܥ??ο??????ꤹ?롣
?????????ɤ??????Υ????????ܥ??ο????֤????Ȥʤ??ѿ??Υ??ɥ쥹?????ꤹ?롣
?????????ܥ????????Υ??ɥ쥹?????ꤹ?롣

????

XGetDeviceKeyMapping ?ꥯ?????Ȥϡ????ꤵ?줿?ǥХ????ˤĤ??ơ? ???ꤷ?????Υ????????ɤ??Ф??륷???ܥ????֤??? ?????????ɤ? first_keycode ?????Ϥޤ롣 first_keycode ?ǻ??ꤵ?????ͤϡ?XListInputDevices ???֤? min_keycode ?ʾ??Ǥʤ????Фʤ??ʤ????????Ǥʤ??????ˤϡ????顼 BadValue ?Ȥʤ롣 ?????ˡ????μ??? XListInputDevices ???֤? max_keycode ?ʲ??Ǥʤ? ???Фʤ??ʤ?:

first_keycode + keycode_count - 1

?????Ǥʤ??????ϡ????顼 BadValue ?Ȥʤ롣 ?????????ܥ??Υꥹ?????????Ǥο??ϼ??Τ褦?ˤʤ?:

keycode_count * keysyms_per_keycode_return

?????????? K ???Ф??롢?ֹ? N ?? ?????????ܥ? (0??????????)?ϡ? ?ꥹ??????(0??????????)???Υ????ǥå?????????: (K - first_code) * keysyms_per_code_return + N

X ?????Ф? keysyms_per_keycode_return ???ͤȤ??ơ??׵ᤵ?줿???Ƥ? ?????ܥ????Τ餻?뤿???˽?ʬ??Ĺ????????Ǥ?դ??ͤ????֡? ?ü??ʥ????????ܥ??ͤǤ??? NoSymbol ???????Υ????????ɤν????ˤĤ??ơ?̤???Ѥ????Ǥ??????뤿???˻Ȥ????롣 XGetDeviceKeyMapping ???֤????ͤ??????????ˤϡ? XFree ?????Ѥ??뤳?ȡ?

???ꤵ?줿?ǥХ????????ϥ??饹 key ?򥵥ݡ??Ȥ??Ƥ??ʤ??????ϡ????顼 BadMatch ?Ȥʤ롣

XGetDeviceKeyMapping ?ϥ??顼 BadDevice, BadMatch, BadValue ?򵯤??????Ȥ????롣

XChangeDeviceKeyMapping ?ꥯ?????Ȥϡ????ꤵ?줿?ǥХ????ˤĤ??ơ? ???ꤵ?줿???Υ????????ɤ??Ф??륷???ܥ??????????롣 ?????????ɤ? first_keycode ?????Ϥޤ롣 ?????ϰϤ˴ޤޤ??ʤ??????????ɤ??Ф??륷???ܥ????Ѳ????ʤ??? ?????????ܥ????????Ǥο??ϼ??ο??Ǥʤ????Фʤ??ʤ?:

num_codes * keysyms_per_keycode

???ꤵ?줿 first_keycode ?? XListInputDevices ???֤??? min_keycode ?ʾ????ͤǤʤ????Фʤ??ʤ????????Ǥʤ??????ˤϡ????顼 BadValue ?Ȥʤ롣 ?????˼??μ??ϡ?XListInputDevices ???֤??? max_keycode ?ʲ??? ?ͤǤʤ????Фʤ餺???????Ǥʤ??????ˤϥ??顼 BadValue ?Ȥʤ?:

first_keycode + num_codes - 1

?????????? K ???Ф???(0??????????)N ???ܤΥ????????ܥ??ϡ? ?????????ܥ?????0?????????Ƽ??Υ????ǥå?????????:

(K - first_keycode) * keysyms_per_keycode + N

???饤?????Ȥϡ????ꤹ?? keysyms_per_keycode ?ˤĤ??ơ?ɬ?פ????Ƥ? ?????ܥ????ݻ??Ǥ??뽽ʬ??Ĺ???Ǥ???Ǥ?դο??????֤??Ȥ??Ǥ??롣 ???̤ʥ????????ܥ??ͤǤ??? NoSymbol ?ϡ??????Υ????????ɤν??????Ф???̤???Ѥ????Ǥ??????뤿???˻Ȥ????롣 NoSymbol ???????????ɤ??Ф???ͭ???ʥꥹ?ȤκǸ??Ǥʤ????֤˸????????Τ????????? XChangeDeviceKeyMapping ?ϡ????Υ????פΥ??٥??Ȥ????򤷤????Ƥ? ???饤?????Ȥ????????? DeviceMappingNotify ???٥??Ȥ????????롣

X ?????Фϡ????Υޥåԥ󥰤????᤹??ɬ?פϤʤ??? X ?????Фϡ????饤?????Ȥˤ????ɤ߽񤭤Τ?????ñ?˳?Ǽ???Ƥ????????? ???롣

???ꤵ?줿?ǥХ????????ϥ??饹 key ?򥵥ݡ??Ȥ??Ƥ??ʤ????硢???顼 BadMatch ?Ȥʤ롣

XChangeDeviceKeyMapping ?ϥ??顼 BadDevice, BadMatch, BadAlloc, BadValue ?򵯤??????Ȥ????롣

?֤???

?????ʥǥХ????????ꤵ?줿?????ꤵ?줿?ǥХ?????¸?ߤ??ʤ????? ???饤?????Ȥ? XOpenInputDevice ???Ȥäƥ????ץ󤷤Ƥ??ʤ??? ???Υ??顼?ϻ??ꤷ???ǥХ???????X ?Υ????ܡ??ɥǥХ????? X ?? ?ݥ??󥿥ǥХ????Ǥ????????ˤⵯ???롣
???Υ??顼?ϡ????????????ʤ??ǥХ????????ꤷ?? XGetDeviceKeyMapping ?ꥯ?????Ȥ? XChangeDeviceKeyMapping ?ꥯ?????Ȥ??Ԥä??????˵????롣
???ꤵ?줿???ͤˡ??ꥯ?????Ȥε????ϰϤ??ۤ??Ƥ??????Τ????롣?????????? ???????????ϰϤ????ꤵ???Ƥ??ʤ????С????????η????????????Ƥ??????Ƥ??? ?Ϥ????????롣???????Ȥ????????????Ƥ??????????Ϥ??Υ??顼?򵯤??????Ȥ? ???롣
?׵ᤵ?줿?꥽?????䥵???Х??????γ??????Ƥ˥????Ф????Ԥ?????

??Ϣ????

XSetDeviceButtonMapping(3X11)
XSetDeviceModifierMapping(3X11)
Programming with Xlib

Release 6.5 X Version 11