Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qxkbcommon.cpp
Go to the documentation of this file.
1// Copyright (C) 2019 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#include "qxkbcommon_p.h"
5
6#include <private/qmakearray_p.h>
7
8#include <QtCore/private/qstringiterator_p.h>
9#include <QtCore/qvarlengtharray.h>
10#include <QtCore/QMetaMethod>
11
12#include <QtGui/QKeyEvent>
13#include <QtGui/private/qguiapplication_p.h>
14
15#include <qpa/qplatforminputcontext.h>
16#include <qpa/qplatformintegration.h>
17
19
20Q_LOGGING_CATEGORY(lcXkbcommon, "qt.xkbcommon")
21
22static int keysymToQtKey_internal(xkb_keysym_t keysym, Qt::KeyboardModifiers modifiers,
23 xkb_state *state, xkb_keycode_t code,
24 bool superAsMeta, bool hyperAsMeta);
25
26typedef struct xkb2qt
27{
28 unsigned int xkb;
29 unsigned int qt;
30
31 constexpr bool operator <=(const xkb2qt &that) const noexcept
32 {
33 return xkb <= that.xkb;
34 }
35
36 constexpr bool operator <(const xkb2qt &that) const noexcept
37 {
38 return xkb < that.xkb;
39 }
41
42template<std::size_t Xkb, std::size_t Qt>
43struct Xkb2Qt
44{
45 using Type = xkb2qt_t;
46 static constexpr Type data() noexcept { return Type{Xkb, Qt}; }
47};
48
49static constexpr const auto KeyTbl = qMakeArray(
51 // misc keys
52
64 Xkb2Qt<0x1005FF60, Qt::Key_SysReq>, // hardcoded Sun SysReq
65 Xkb2Qt<0x1007ff00, Qt::Key_SysReq>, // hardcoded X386 SysReq
66
67 // cursor movement
68
77
78 // modifiers
79
98 Xkb2Qt<0x1000FF74, Qt::Key_Backtab>, // hardcoded HP backtab
99 Xkb2Qt<0x1005FF10, Qt::Key_F11>, // hardcoded Sun F36 (labeled F11)
100 Xkb2Qt<0x1005FF11, Qt::Key_F12>, // hardcoded Sun F37 (labeled F12)
101
102 // numeric and function keypad keys
103
125
126 // special non-XF86 function keys
127
132
133 // International input method support keys
134
135 // International & multi-key character composition
142
143 // Misc Functions
146
147 // Japanese keyboard support
150 //Xkb2Qt<XKB_KEY_Henkan_Mode, Qt::Key_Henkan_Mode>,
166 //Xkb2Qt<XKB_KEY_Kanji_Bangou, Qt::Key_Kanji_Bangou>,
167 //Xkb2Qt<XKB_KEY_Zen_Koho, Qt::Key_Zen_Koho>,
168 //Xkb2Qt<XKB_KEY_Mae_Koho, Qt::Key_Mae_Koho>,
172
173 // Korean keyboard support
180 //Xkb2Qt<XKB_KEY_Hangul_Codeinput, Qt::Key_Hangul_Codeinput>,
186 //Xkb2Qt<XKB_KEY_Hangul_SingleCandidate,Qt::Key_Hangul_SingleCandidate>,
187 //Xkb2Qt<XKB_KEY_Hangul_MultipleCandidate,Qt::Key_Hangul_MultipleCandidate>,
188 //Xkb2Qt<XKB_KEY_Hangul_PreviousCandidate,Qt::Key_Hangul_PreviousCandidate>,
193 //Xkb2Qt<XKB_KEY_Hangul_switch, Qt::Key_Hangul_switch>,
195
196 // dead keys
246
247 // Special keys from X.org - This include multimedia keys,
248 // wireless/bluetooth/uwb keys, special launcher keys, etc.
392 >::Data{}
393);
394
396{
397 xkb_keysym_t lower, upper;
398
399 xkbcommon_XConvertCase(ks, &lower, &upper);
400
401 return upper;
402}
403
404QString QXkbCommon::lookupString(struct xkb_state *state, xkb_keycode_t code)
405{
407 const int size = xkb_state_key_get_utf8(state, code, chars.data(), chars.size());
408 if (Q_UNLIKELY(size + 1 > chars.size())) { // +1 for NUL
409 chars.resize(size + 1);
410 xkb_state_key_get_utf8(state, code, chars.data(), chars.size());
411 }
412 return QString::fromUtf8(chars.constData(), size);
413}
414
416{
418 const int size = xkb_keysym_to_utf8(keysym, chars.data(), chars.size());
419 if (size == 0)
420 return QString(); // the keysym does not have a Unicode representation
421
422 if (Q_UNLIKELY(size > chars.size())) {
423 chars.resize(size);
424 xkb_keysym_to_utf8(keysym, chars.data(), chars.size());
425 }
426 return QString::fromUtf8(chars.constData(), size - 1);
427}
428
430{
431 QList<xkb_keysym_t> keysyms;
432 int qtKey = event->key();
433
434 if (qtKey >= Qt::Key_F1 && qtKey <= Qt::Key_F35) {
435 keysyms.append(XKB_KEY_F1 + (qtKey - Qt::Key_F1));
436 } else if (event->modifiers() & Qt::KeypadModifier) {
437 if (qtKey >= Qt::Key_0 && qtKey <= Qt::Key_9)
438 keysyms.append(XKB_KEY_KP_0 + (qtKey - Qt::Key_0));
439 } else if (isLatin1(qtKey) && event->text().isUpper()) {
440 keysyms.append(qtKey);
441 }
442
443 if (!keysyms.isEmpty())
444 return keysyms;
445
446 // check if we have a direct mapping
447 auto it = std::find_if(KeyTbl.cbegin(), KeyTbl.cend(), [&qtKey](xkb2qt_t elem) {
448 return elem.qt == static_cast<uint>(qtKey);
449 });
450 if (it != KeyTbl.end()) {
451 keysyms.append(it->xkb);
452 return keysyms;
453 }
454
455 QList<uint> ucs4;
456 if (event->text().isEmpty())
457 ucs4.append(qtKey);
458 else
459 ucs4 = event->text().toUcs4();
460
461 // From libxkbcommon keysym-utf.c:
462 // "We allow to represent any UCS character in the range U-00000000 to
463 // U-00FFFFFF by a keysym value in the range 0x01000000 to 0x01ffffff."
464 for (uint utf32 : std::as_const(ucs4))
465 keysyms.append(utf32 | 0x01000000);
466
467 return keysyms;
468}
469
470int QXkbCommon::keysymToQtKey(xkb_keysym_t keysym, Qt::KeyboardModifiers modifiers)
471{
472 return keysymToQtKey(keysym, modifiers, nullptr, 0);
473}
474
475int QXkbCommon::keysymToQtKey(xkb_keysym_t keysym, Qt::KeyboardModifiers modifiers,
476 xkb_state *state, xkb_keycode_t code,
477 bool superAsMeta, bool hyperAsMeta)
478{
479 // Note 1: All standard key sequences on linux (as defined in platform theme)
480 // that use a latin character also contain a control modifier, which is why
481 // checking for Qt::ControlModifier is sufficient here. It is possible to
482 // override QPlatformTheme::keyBindings() and provide custom sequences for
483 // QKeySequence::StandardKey. Custom sequences probably should respect this
484 // convention (alternatively, we could test against other modifiers here).
485 // Note 2: The possibleKeys() shorcut mechanism is not affected by this value
486 // adjustment and does its own thing.
488 // With standard shortcuts we should prefer a latin character, this is
489 // for checks like "some qkeyevent == QKeySequence::Copy" to work even
490 // when using for example 'russian' keyboard layout.
491 xkb_keysym_t latinKeysym = QXkbCommon::lookupLatinKeysym(state, code);
492 if (latinKeysym != XKB_KEY_NoSymbol)
493 keysym = latinKeysym;
494 }
495
496 return keysymToQtKey_internal(keysym, modifiers, state, code, superAsMeta, hyperAsMeta);
497}
498
499static int keysymToQtKey_internal(xkb_keysym_t keysym, Qt::KeyboardModifiers modifiers,
500 xkb_state *state, xkb_keycode_t code,
501 bool superAsMeta, bool hyperAsMeta)
502{
503 int qtKey = 0;
504
505 // lookup from direct mapping
506 if (keysym >= XKB_KEY_F1 && keysym <= XKB_KEY_F35) {
507 // function keys
508 qtKey = Qt::Key_F1 + (keysym - XKB_KEY_F1);
509 } else if (keysym >= XKB_KEY_KP_0 && keysym <= XKB_KEY_KP_9) {
510 // numeric keypad keys
511 qtKey = Qt::Key_0 + (keysym - XKB_KEY_KP_0);
512 } else if (QXkbCommon::isLatin1(keysym)) {
513 // Most Qt::Key values are determined by their upper-case version,
514 // where this is in the Latin-1 repertoire. So start with that:
516 // However, Key_mu and Key_ydiaeresis are U+00B5 MICRO SIGN and
517 // U+00FF LATIN SMALL LETTER Y WITH DIAERESIS, both lower-case,
518 // with upper-case forms outside Latin-1, so use them as they are
519 // since they're the Qt::Key values.
521 qtKey = keysym;
522 } else {
523 // check if we have a direct mapping
524 xkb2qt_t searchKey{keysym, 0};
525 auto it = std::lower_bound(KeyTbl.cbegin(), KeyTbl.cend(), searchKey);
526 if (it != KeyTbl.end() && !(searchKey < *it))
527 qtKey = it->qt;
528
529 // translate Super/Hyper keys to Meta if we're using them as the MetaModifier
530 if (superAsMeta && (qtKey == Qt::Key_Super_L || qtKey == Qt::Key_Super_R))
532 if (hyperAsMeta && (qtKey == Qt::Key_Hyper_L || qtKey == Qt::Key_Hyper_R))
534 }
535
536 if (qtKey)
537 return qtKey;
538
539 // lookup from unicode
542 // Control modifier changes the text to ASCII control character, therefore we
543 // can't use this text to map keysym to a qt key. We can use the same keysym
544 // (it is not affectd by transformation) to obtain untransformed text. For details
545 // see "Appendix A. Default Symbol Transformations" in the XKB specification.
547 } else {
549 }
550 if (!text.isEmpty()) {
551 if (text.unicode()->isDigit()) {
552 // Ensures that also non-latin digits are mapped to corresponding qt keys,
553 // e.g CTRL + Û² (arabic two), is mapped to CTRL + Qt::Key_2.
555 } else {
556 text = text.toUpper();
558 qtKey = i.next(0);
559 }
560 }
561
562 return qtKey;
563}
564
565Qt::KeyboardModifiers QXkbCommon::modifiers(struct xkb_state *state, xkb_keysym_t keysym)
566{
567 Qt::KeyboardModifiers modifiers = Qt::NoModifier;
568
569 if (xkb_state_mod_name_is_active(state, XKB_MOD_NAME_CTRL, XKB_STATE_MODS_EFFECTIVE) > 0)
571 if (xkb_state_mod_name_is_active(state, XKB_MOD_NAME_ALT, XKB_STATE_MODS_EFFECTIVE) > 0)
573 if (xkb_state_mod_name_is_active(state, XKB_MOD_NAME_SHIFT, XKB_STATE_MODS_EFFECTIVE) > 0)
575 if (xkb_state_mod_name_is_active(state, XKB_MOD_NAME_LOGO, XKB_STATE_MODS_EFFECTIVE) > 0)
577
578 if (keysym >= XKB_KEY_KP_Space && keysym <= XKB_KEY_KP_9)
580
581 return modifiers;
582}
583
584// Possible modifier states.
585static const Qt::KeyboardModifiers ModsTbl[] = {
586 Qt::NoModifier, // 0
590 Qt::AltModifier, // 4
594 Qt::NoModifier // Fall-back to raw Key_*, for non-latin1 kb layouts
595};
596
598 bool superAsMeta, bool hyperAsMeta)
599{
601 quint32 keycode = event->nativeScanCode();
602 if (!keycode)
603 return result;
604
605 Qt::KeyboardModifiers modifiers = event->modifiers();
606 xkb_keymap *keymap = xkb_state_get_keymap(state);
607 // turn off the modifier bits which doesn't participate in shortcuts
608 Qt::KeyboardModifiers notNeeded = Qt::KeypadModifier | Qt::GroupSwitchModifier;
609 modifiers &= ~notNeeded;
610 // create a fresh kb state and test against the relevant modifier combinations
611 ScopedXKBState scopedXkbQueryState(xkb_state_new(keymap));
612 xkb_state *queryState = scopedXkbQueryState.get();
613 if (!queryState) {
614 qCWarning(lcXkbcommon) << Q_FUNC_INFO << "failed to compile xkb keymap";
615 return result;
616 }
617 // get kb state from the master state and update the temporary state
618 xkb_layout_index_t lockedLayout = xkb_state_serialize_layout(state, XKB_STATE_LAYOUT_LOCKED);
619 xkb_mod_mask_t latchedMods = xkb_state_serialize_mods(state, XKB_STATE_MODS_LATCHED);
620 xkb_mod_mask_t lockedMods = xkb_state_serialize_mods(state, XKB_STATE_MODS_LOCKED);
621 xkb_mod_mask_t depressedMods = xkb_state_serialize_mods(state, XKB_STATE_MODS_DEPRESSED);
622 xkb_state_update_mask(queryState, depressedMods, latchedMods, lockedMods, 0, 0, lockedLayout);
623 // handle shortcuts for level three and above
624 xkb_layout_index_t layoutIndex = xkb_state_key_get_layout(queryState, keycode);
625 xkb_level_index_t levelIndex = 0;
626 if (layoutIndex != XKB_LAYOUT_INVALID) {
627 levelIndex = xkb_state_key_get_level(queryState, keycode, layoutIndex);
628 if (levelIndex == XKB_LEVEL_INVALID)
629 levelIndex = 0;
630 }
631 if (levelIndex <= 1)
632 xkb_state_update_mask(queryState, 0, latchedMods, lockedMods, 0, 0, lockedLayout);
633
634 xkb_keysym_t sym = xkb_state_key_get_one_sym(queryState, keycode);
635 if (sym == XKB_KEY_NoSymbol)
636 return result;
637
638 int baseQtKey = keysymToQtKey_internal(sym, modifiers, queryState, keycode, superAsMeta, hyperAsMeta);
639 if (baseQtKey)
640 result += (baseQtKey + int(modifiers));
641
642 xkb_mod_index_t shiftMod = xkb_keymap_mod_get_index(keymap, "Shift");
643 xkb_mod_index_t altMod = xkb_keymap_mod_get_index(keymap, "Alt");
644 xkb_mod_index_t controlMod = xkb_keymap_mod_get_index(keymap, "Control");
645 xkb_mod_index_t metaMod = xkb_keymap_mod_get_index(keymap, "Meta");
646
647 Q_ASSERT(shiftMod < 32);
648 Q_ASSERT(altMod < 32);
649 Q_ASSERT(controlMod < 32);
650
651 xkb_mod_mask_t depressed;
652 int qtKey = 0;
653 // obtain a list of possible shortcuts for the given key event
654 for (uint i = 1; i < sizeof(ModsTbl) / sizeof(*ModsTbl) ; ++i) {
655 Qt::KeyboardModifiers neededMods = ModsTbl[i];
656 if ((modifiers & neededMods) == neededMods) {
657 if (i == 8) {
658 if (isLatin1(baseQtKey))
659 continue;
660 // add a latin key as a fall back key
661 sym = lookupLatinKeysym(state, keycode);
662 } else {
663 depressed = 0;
664 if (neededMods & Qt::AltModifier)
665 depressed |= (1 << altMod);
666 if (neededMods & Qt::ShiftModifier)
667 depressed |= (1 << shiftMod);
668 if (neededMods & Qt::ControlModifier)
669 depressed |= (1 << controlMod);
670 if (metaMod < 32 && neededMods & Qt::MetaModifier)
671 depressed |= (1 << metaMod);
672 xkb_state_update_mask(queryState, depressed, latchedMods, lockedMods, 0, 0, lockedLayout);
673 sym = xkb_state_key_get_one_sym(queryState, keycode);
674 }
675 if (sym == XKB_KEY_NoSymbol)
676 continue;
677
678 Qt::KeyboardModifiers mods = modifiers & ~neededMods;
679 qtKey = keysymToQtKey_internal(sym, mods, queryState, keycode, superAsMeta, hyperAsMeta);
680 if (!qtKey || qtKey == baseQtKey)
681 continue;
682
683 // catch only more specific shortcuts, i.e. Ctrl+Shift+= also generates Ctrl++ and +,
684 // but Ctrl++ is more specific than +, so we should skip the last one
685 bool ambiguous = false;
686 for (int shortcut : std::as_const(result)) {
687 if (int(shortcut & ~Qt::KeyboardModifierMask) == qtKey && (shortcut & mods) == mods) {
688 ambiguous = true;
689 break;
690 }
691 }
692 if (ambiguous)
693 continue;
694
695 result += (qtKey + int(mods));
696 }
697 }
698
699 return result;
700}
701
702void QXkbCommon::verifyHasLatinLayout(xkb_keymap *keymap)
703{
704 const xkb_layout_index_t layoutCount = xkb_keymap_num_layouts(keymap);
705 const xkb_keycode_t minKeycode = xkb_keymap_min_keycode(keymap);
706 const xkb_keycode_t maxKeycode = xkb_keymap_max_keycode(keymap);
707
708 const xkb_keysym_t *keysyms = nullptr;
709 int nrLatinKeys = 0;
710 for (xkb_layout_index_t layout = 0; layout < layoutCount; ++layout) {
711 for (xkb_keycode_t code = minKeycode; code < maxKeycode; ++code) {
712 xkb_keymap_key_get_syms_by_level(keymap, code, layout, 0, &keysyms);
713 if (keysyms && isLatin1(keysyms[0]))
714 nrLatinKeys++;
715 if (nrLatinKeys > 10) // arbitrarily chosen threshold
716 return;
717 }
718 }
719 // This means that lookupLatinKeysym() will not find anything and latin
720 // key shortcuts might not work. This is a bug in the affected desktop
721 // environment. Usually can be solved via system settings by adding e.g. 'us'
722 // layout to the list of selected layouts, or by using command line, "setxkbmap
723 // -layout rus,en". The position of latin key based layout in the list of the
724 // selected layouts is irrelevant. Properly functioning desktop environments
725 // handle this behind the scenes, even if no latin key based layout has been
726 // explicitly listed in the selected layouts.
727 qCDebug(lcXkbcommon, "no keyboard layouts with latin keys present");
728}
729
730xkb_keysym_t QXkbCommon::lookupLatinKeysym(xkb_state *state, xkb_keycode_t keycode)
731{
732 xkb_layout_index_t layout;
733 xkb_keysym_t sym = XKB_KEY_NoSymbol;
734 xkb_keymap *keymap = xkb_state_get_keymap(state);
735 const xkb_layout_index_t layoutCount = xkb_keymap_num_layouts_for_key(keymap, keycode);
736 // Look at user layouts in the order in which they are defined in system
737 // settings to find a latin keysym.
738 for (layout = 0; layout < layoutCount; ++layout) {
739 const xkb_keysym_t *syms = nullptr;
740 xkb_level_index_t level = xkb_state_key_get_level(state, keycode, layout);
741 if (xkb_keymap_key_get_syms_by_level(keymap, keycode, layout, level, &syms) != 1)
742 continue;
743 if (isLatin1(syms[0])) {
744 sym = syms[0];
745 break;
746 }
747 }
748
749 return sym;
750}
751
752void QXkbCommon::setXkbContext(QPlatformInputContext *inputContext, struct xkb_context *context)
753{
754 if (!inputContext || !context)
755 return;
756
757 const char *const inputContextClassName = "QComposeInputContext";
758 const char *const normalizedSignature = "setXkbContext(xkb_context*)";
759
760 if (inputContext->objectName() != QLatin1StringView(inputContextClassName))
761 return;
762
763 static const QMetaMethod setXkbContext = [&]() {
764 int methodIndex = inputContext->metaObject()->indexOfMethod(normalizedSignature);
765 QMetaMethod method = inputContext->metaObject()->method(methodIndex);
766 Q_ASSERT(method.isValid());
767 if (!method.isValid())
768 qCWarning(lcXkbcommon) << normalizedSignature << "not found on" << inputContextClassName;
769 return method;
770 }();
771
772 if (!setXkbContext.isValid())
773 return;
774
775 setXkbContext.invoke(inputContext, Qt::DirectConnection, Q_ARG(struct xkb_context*, context));
776}
777
constexpr bool isDigit() const noexcept
Returns true if the character is a decimal digit (Number_DecimalDigit); otherwise returns false.
Definition qchar.h:473
int digitValue() const noexcept
Returns the numeric value of the digit, or -1 if the character is not a digit.
Definition qchar.h:447
The QKeyEvent class describes a key event.
Definition qevent.h:423
Definition qlist.h:74
bool isEmpty() const noexcept
Definition qlist.h:390
void append(parameter_type t)
Definition qlist.h:441
\inmodule QtCore
Definition qmetaobject.h:18
QString objectName
the name of this object
Definition qobject.h:94
The QPlatformInputContext class abstracts the input method dependent data and composing state.
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:127
static QString fromUtf8(QByteArrayView utf8)
This is an overloaded member function, provided for convenience. It differs from the above function o...
Definition qstring.cpp:5857
bool isEmpty() const
Returns true if the string has no characters; otherwise returns false.
Definition qstring.h:1083
QString toUpper() const &
Definition qstring.h:372
const QChar * unicode() const
Returns a Unicode representation of the string.
Definition qstring.h:1085
constexpr size_type size() const noexcept
void resize(qsizetype sz)
const T * constData() const
T * data() noexcept
static QString lookupStringNoKeysymTransformations(xkb_keysym_t keysym)
static void xkbcommon_XConvertCase(xkb_keysym_t sym, xkb_keysym_t *lower, xkb_keysym_t *upper)
static bool isLatin1(xkb_keysym_t sym)
static QString lookupString(struct xkb_state *state, xkb_keycode_t code)
static void verifyHasLatinLayout(xkb_keymap *keymap)
std::unique_ptr< struct xkb_state, XKBStateDeleter > ScopedXKBState
static QList< xkb_keysym_t > toKeysym(QKeyEvent *event)
static Qt::KeyboardModifiers modifiers(struct xkb_state *state, xkb_keysym_t keysym=XKB_KEY_VoidSymbol)
static xkb_keysym_t lookupLatinKeysym(xkb_state *state, xkb_keycode_t keycode)
static QList< int > possibleKeys(xkb_state *state, const QKeyEvent *event, bool superAsMeta=false, bool hyperAsMeta=false)
static void setXkbContext(QPlatformInputContext *inputContext, struct xkb_context *context)
static int keysymToQtKey(xkb_keysym_t keysym, Qt::KeyboardModifiers modifiers)
static xkb_keysym_t qxkbcommon_xkb_keysym_to_upper(xkb_keysym_t ks)
EGLImageKHR int int EGLuint64KHR * modifiers
QString text
QSet< QString >::iterator it
else opt state
[0]
Combined button and popup list for selecting options.
@ Key_Super_R
Definition qnamespace.h:721
@ Key_9
Definition qnamespace.h:538
@ Key_Super_L
Definition qnamespace.h:720
@ Key_F35
Definition qnamespace.h:719
@ Key_0
Definition qnamespace.h:529
@ Key_Meta
Definition qnamespace.h:680
@ Key_F1
Definition qnamespace.h:685
@ Key_Hyper_R
Definition qnamespace.h:724
@ Key_Hyper_L
Definition qnamespace.h:723
@ ShiftModifier
@ ControlModifier
@ MetaModifier
@ GroupSwitchModifier
@ KeypadModifier
@ KeyboardModifierMask
@ NoModifier
@ AltModifier
@ DirectConnection
static void * context
#define Q_UNLIKELY(x)
#define Q_FUNC_INFO
DBusConnection const char DBusError DBusBusType DBusError return DBusConnection DBusHandleMessageFunction void DBusFreeFunction return DBusConnection return DBusConnection return const char DBusError return DBusConnection DBusMessage dbus_uint32_t return DBusConnection dbus_bool_t DBusConnection DBusAddWatchFunction DBusRemoveWatchFunction DBusWatchToggledFunction void DBusFreeFunction return DBusConnection DBusDispatchStatusFunction void DBusFreeFunction DBusTimeout return DBusTimeout return DBusWatch return DBusWatch unsigned int return DBusError const DBusError return const DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessage return DBusMessageIter int const void return DBusMessageIter DBusMessageIter return DBusMessageIter void DBusMessageIter void int return DBusMessage DBusMessageIter return DBusMessageIter return DBusMessageIter DBusMessageIter const char const char const char const char * method
#define Q_LOGGING_CATEGORY(name,...)
#define qCWarning(category,...)
#define qCDebug(category,...)
constexpr QtPrivate::ArrayType< ManualType, Types... > qMakeArray(Types &&... t) noexcept
#define Q_ARG(Type, data)
Definition qobjectdefs.h:62
GLenum GLuint GLint level
GLenum GLuint GLintptr GLsizeiptr size
[1]
struct _cl_event * event
GLuint64EXT * result
[6]
#define Q_ASSERT(cond)
Definition qrandom.cpp:47
static bool operator<(const QSettingsIniKey &k1, const QSettingsIniKey &k2)
static QString qtKey(CFStringRef cfkey)
unsigned int quint32
Definition qtypes.h:45
unsigned int uint
Definition qtypes.h:29
bool operator<=(const QUuid &lhs, const QUuid &rhs) noexcept
Definition quuid.h:272
#define XKB_MOD_NAME_ALT
#define XKB_MOD_NAME_SHIFT
#define XKB_MOD_NAME_LOGO
#define XKB_MOD_NAME_CTRL
static constexpr const auto KeyTbl
static QT_BEGIN_NAMESPACE int keysymToQtKey_internal(xkb_keysym_t keysym, Qt::KeyboardModifiers modifiers, xkb_state *state, xkb_keycode_t code, bool superAsMeta, bool hyperAsMeta)
struct xkb2qt xkb2qt_t
static const Qt::KeyboardModifiers ModsTbl[]
QVBoxLayout * layout
static constexpr Type data() noexcept
unsigned int xkb
unsigned int qt