€•d)Œsphinx.addnodes”Œdocument”“”)�”}”(Œ rawsource”Œ”Œchildren”]”(Œ translations”Œ LanguagesNode”“”)�”}”(hhh]”(hŒ pending_xref”“”)�”}”(hhh]”Œdocutils.nodes”ŒText”“”ŒChinese (Simplified)”…”�”}”Œparent”hsbaŒ attributes”}”(Œids”]”Œclasses”]”Œnames”]”Œdupnames”]”Œbackrefs”]”Œ refdomain”Œstd”Œreftype”Œdoc”Œ reftarget”Œ"/translations/zh_CN/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuŒtagname”hhh ubh)�”}”(hhh]”hŒChinese (Traditional)”…”�”}”hh2sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ"/translations/zh_TW/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒItalian”…”�”}”hhFsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ"/translations/it_IT/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒJapanese”…”�”}”hhZsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ"/translations/ja_JP/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒKorean”…”�”}”hhnsbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ"/translations/ko_KR/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒPortuguese (Brazilian)”…”�”}”hh‚sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ"/translations/pt_BR/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubh)�”}”(hhh]”hŒSpanish”…”�”}”hh–sbah}”(h]”h ]”h"]”h$]”h&]”Œ refdomain”h)Œreftype”h+Œ reftarget”Œ"/translations/sp_SP/input/notifier”Œmodname”NŒ classname”NŒ refexplicit”ˆuh1hhh ubeh}”(h]”h ]”h"]”h$]”h&]”Œcurrent_language”ŒEnglish”uh1h hhŒ _document”hŒsource”NŒline”NubhŒsection”“”)�”}”(hhh]”(hŒtitle”“”)�”}”(hŒKeyboard notifier”h]”hŒKeyboard notifier”…”�”}”(hh¼h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hºhh·h²hh³Œ):”h]”hŒÁOne can use register_keyboard_notifier to get called back on keyboard events (see kbd_keycode() function for details). The passed structure is keyboard_notifier_param (see ):”…”�”}”(hhÍh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khh·h²hubhŒ bullet_list”“”)�”}”(hhh]”(hŒ list_item”“”)�”}”(hŒ@'vc' always provide the VC for which the keyboard event applies;”h]”hÌ)�”}”(hhäh]”hŒD‘vc’ always provide the VC for which the keyboard event applies;”…”�”}”(hhæh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K hhâubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒ7'down' is 1 for a key press event, 0 for a key release;”h]”hÌ)�”}”(hhûh]”hŒ;‘down’ is 1 for a key press event, 0 for a key release;”…”�”}”(hhýh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K hhùubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒA'shift' is the current modifier state, mask bit indexes are KG_*;”h]”hÌ)�”}”(hjh]”hŒE‘shift’ is the current modifier state, mask bit indexes are KG_*;”…”�”}”(hjh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K hjubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒ$'ledstate' is the current LED state;”h]”hÌ)�”}”(hj)h]”hŒ(‘ledstate’ is the current LED state;”…”�”}”(hj+h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K hj'ubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒ&'value' depends on the type of event. ”h]”hÌ)�”}”(hŒ%'value' depends on the type of event.”h]”hŒ)‘value’ depends on the type of event.”…”�”}”(hjBh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K hj>ubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒMKBD_KEYCODE events are always sent before other events, value is the keycode.”h]”hÌ)�”}”(hjXh]”hŒMKBD_KEYCODE events are always sent before other events, value is the keycode.”…”�”}”(hjZh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´KhjVubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒbKBD_UNBOUND_KEYCODE events are sent if the keycode is not bound to a keysym. value is the keycode.”h]”hÌ)�”}”(hŒbKBD_UNBOUND_KEYCODE events are sent if the keycode is not bound to a keysym. value is the keycode.”h]”hŒbKBD_UNBOUND_KEYCODE events are sent if the keycode is not bound to a keysym. value is the keycode.”…”�”}”(hjqh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khjmubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒzKBD_UNICODE events are sent if the keycode -> keysym translation produced a unicode character. value is the unicode value.”h]”hÌ)�”}”(hŒzKBD_UNICODE events are sent if the keycode -> keysym translation produced a unicode character. value is the unicode value.”h]”hŒzKBD_UNICODE events are sent if the keycode -> keysym translation produced a unicode character. value is the unicode value.”…”�”}”(hj‰h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khj…ubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒvKBD_KEYSYM events are sent if the keycode -> keysym translation produced a non-unicode character. value is the keysym.”h]”hÌ)�”}”(hŒvKBD_KEYSYM events are sent if the keycode -> keysym translation produced a non-unicode character. value is the keysym.”h]”hŒvKBD_KEYSYM events are sent if the keycode -> keysym translation produced a non-unicode character. value is the keysym.”…”�”}”(hj¡h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khj�ubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubhá)�”}”(hŒ‰KBD_POST_KEYSYM events are sent after the treatment of non-unicode keysyms. That permits one to inspect the resulting LEDs for instance. ”h]”hÌ)�”}”(hŒˆKBD_POST_KEYSYM events are sent after the treatment of non-unicode keysyms. That permits one to inspect the resulting LEDs for instance.”h]”hŒˆKBD_POST_KEYSYM events are sent after the treatment of non-unicode keysyms. That permits one to inspect the resulting LEDs for instance.”…”�”}”(hj¹h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khjµubah}”(h]”h ]”h"]”h$]”h&]”uh1hàhhÝh²hh³hÊh´Nubeh}”(h]”h ]”h"]”h$]”h&]”Œbullet”Œ-”uh1hÛh³hÊh´K hh·h²hubhÌ)�”}”(hŒ£For each kind of event but the last, the callback may return NOTIFY_STOP in order to "eat" the event: the notify loop is stopped and the keyboard event is dropped.”h]”hŒ§For each kind of event but the last, the callback may return NOTIFY_STOP in order to “eatâ€� the event: the notify loop is stopped and the keyboard event is dropped.”…”�”}”(hjÕh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khh·h²hubhÌ)�”}”(hŒIn a rough C snippet, we have::”h]”hŒIn a rough C snippet, we have:”…”�”}”(hjãh²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´Khh·h²hubhŒ literal_block”“”)�”}”(hXnkbd_keycode(keycode) { ... params.value = keycode; if (notifier_call_chain(KBD_KEYCODE,¶ms) == NOTIFY_STOP) || !bound) { notifier_call_chain(KBD_UNBOUND_KEYCODE,¶ms); return; } if (unicode) { param.value = unicode; if (notifier_call_chain(KBD_UNICODE,¶ms) == NOTIFY_STOP) return; emit unicode; return; } params.value = keysym; if (notifier_call_chain(KBD_KEYSYM,¶ms) == NOTIFY_STOP) return; apply keysym; notifier_call_chain(KBD_POST_KEYSYM,¶ms); }”h]”hXnkbd_keycode(keycode) { ... params.value = keycode; if (notifier_call_chain(KBD_KEYCODE,¶ms) == NOTIFY_STOP) || !bound) { notifier_call_chain(KBD_UNBOUND_KEYCODE,¶ms); return; } if (unicode) { param.value = unicode; if (notifier_call_chain(KBD_UNICODE,¶ms) == NOTIFY_STOP) return; emit unicode; return; } params.value = keysym; if (notifier_call_chain(KBD_KEYSYM,¶ms) == NOTIFY_STOP) return; apply keysym; notifier_call_chain(KBD_POST_KEYSYM,¶ms); }”…”�”}”hjósbah}”(h]”h ]”h"]”h$]”h&]”Œ xml:space”Œpreserve”uh1jñh³hÊh´Khh·h²hubhŒnote”“”)�”}”(hŒ7This notifier is usually called from interrupt context.”h]”hÌ)�”}”(hjh]”hŒ7This notifier is usually called from interrupt context.”…”�”}”(hj h²hh³Nh´Nubah}”(h]”h ]”h"]”h$]”h&]”uh1hËh³hÊh´K7hjubah}”(h]”h ]”h"]”h$]”h&]”uh1jhh·h²hh³hÊh´Nubeh}”(h]”Œkeyboard-notifier”ah ]”h"]”Œkeyboard notifier”ah$]”h&]”uh1hµhhh²hh³hÊh´Kubeh}”(h]”h ]”h"]”h$]”h&]”Œsource”hÊuh1hŒcurrent_source”NŒ current_line”NŒsettings”Œdocutils.frontend”ŒValues”“”)�”}”(hºNŒ generator”NŒ datestamp”NŒ source_link”NŒ source_url”NŒ toc_backlinks”Œentry”Œfootnote_backlinks”KŒ sectnum_xform”KŒstrip_comments”NŒstrip_elements_with_classes”NŒ strip_classes”NŒ report_level”KŒ halt_level”KŒexit_status_level”KŒdebug”NŒwarning_stream”NŒ traceback”ˆŒinput_encoding”Œ utf-8-sig”Œinput_encoding_error_handler”Œstrict”Œoutput_encoding”Œutf-8”Œoutput_encoding_error_handler”jGŒerror_encoding”Œutf-8”Œerror_encoding_error_handler”Œbackslashreplace”Œ language_code”Œen”Œrecord_dependencies”NŒconfig”NŒ id_prefix”hŒauto_id_prefix”Œid”Œ dump_settings”NŒdump_internals”NŒdump_transforms”NŒdump_pseudo_xml”NŒexpose_internals”NŒstrict_visitor”NŒ_disable_config”NŒ_source”hÊŒ _destination”NŒ _config_files”]”Œ7/var/lib/git/docbuild/linux/Documentation/docutils.conf”aŒfile_insertion_enabled”ˆŒ raw_enabled”KŒline_length_limit”M'Œpep_references”NŒ pep_base_url”Œhttps://peps.python.org/”Œpep_file_url_template”Œpep-%04d”Œrfc_references”NŒ rfc_base_url”Œ&https://datatracker.ietf.org/doc/html/”Œ tab_width”KŒtrim_footnote_reference_space”‰Œsyntax_highlight”Œlong”Œ smart_quotes”ˆŒsmartquotes_locales”]”Œcharacter_level_inline_markup”‰Œdoctitle_xform”‰Œ docinfo_xform”KŒsectsubtitle_xform”‰Œ image_loading”Œlink”Œembed_stylesheet”‰Œcloak_email_addresses”ˆŒsection_self_link”‰Œenv”NubŒreporter”NŒindirect_targets”]”Œsubstitution_defs”}”Œsubstitution_names”}”Œrefnames”}”Œrefids”}”Œnameids”}”j!jsŒ nametypes”}”j!‰sh}”jh·sŒ footnote_refs”}”Œ citation_refs”}”Œ autofootnotes”]”Œautofootnote_refs”]”Œsymbol_footnotes”]”Œsymbol_footnote_refs”]”Œ footnotes”]”Œ citations”]”Œautofootnote_start”KŒsymbol_footnote_start”KŒ id_counter”Œ collections”ŒCounter”“”}”…”R”Œparse_messages”]”Œtransform_messages”]”Œ transformer”NŒ include_log”]”Œ decoration”Nh²hub.