KWin
Loading...
Searching...
No Matches
Public Slots | Signals | Public Member Functions | List of all members
KWin::Xkb Class Reference

#include <xkb.h>

Inheritance diagram for KWin::Xkb:

Public Slots

void reconfigure ()
 

Signals

void ledsChanged (const LEDs &leds)
 
void modifierStateChanged ()
 

Public Member Functions

 Xkb (bool followLocale1=false)
 
 ~Xkb () override
 
void setConfig (const KSharedConfigPtr &config)
 
void setNumLockConfig (const KSharedConfigPtr &config)
 
void updateModifiers (uint32_t modsDepressed, uint32_t modsLatched, uint32_t modsLocked, uint32_t group)
 
void updateKey (uint32_t key, InputRedirection::KeyboardKeyState state)
 
xkb_keysym_t toKeysym (uint32_t key)
 
xkb_keysym_t currentKeysym () const
 
QString toString (xkb_keysym_t keysym)
 
Qt::Key toQtKey (xkb_keysym_t keysym, uint32_t scanCode=0, Qt::KeyboardModifiers modifiers=Qt::KeyboardModifiers(), bool superAsMeta=false) const
 
Qt::KeyboardModifiers modifiers () const
 
Qt::KeyboardModifiers modifiersRelevantForGlobalShortcuts (uint32_t scanCode=0) const
 
bool shouldKeyRepeat (quint32 key) const
 
void switchToNextLayout ()
 
void switchToPreviousLayout ()
 
bool switchToLayout (xkb_layout_index_t layout)
 
void setModifierLatched (Qt::KeyboardModifier mod, bool latched)
 
void setModifierLocked (Qt::KeyboardModifier mod, bool locked)
 
LEDs leds () const
 
xkb_keymap * keymap () const
 
xkb_state * state () const
 
quint32 currentLayout () const
 
const auto & modifierState () const
 
QString layoutName (xkb_layout_index_t index) const
 
QString layoutName () const
 
QString layoutShortName (int index) const
 
quint32 numberOfLayouts () const
 
void forwardModifiers ()
 
void setSeat (SeatInterface *seat)
 
QByteArray keymapContents () const
 
std::optional< int > keycodeFromKeysym (xkb_keysym_t keysym)
 
void setFollowLocale1 (bool follow)
 

Detailed Description

Definition at line 38 of file xkb.h.

Constructor & Destructor Documentation

◆ Xkb()

KWin::Xkb::Xkb ( bool followLocale1 = false)

Definition at line 77 of file xkb.cpp.

◆ ~Xkb()

KWin::Xkb::~Xkb ( )
override

Definition at line 133 of file xkb.cpp.

Member Function Documentation

◆ currentKeysym()

xkb_keysym_t KWin::Xkb::currentKeysym ( ) const
inline

Definition at line 50 of file xkb.h.

◆ currentLayout()

quint32 KWin::Xkb::currentLayout ( ) const
inline

Definition at line 85 of file xkb.h.

◆ forwardModifiers()

void KWin::Xkb::forwardModifiers ( )

Forwards the current modifier state to the Wayland seat

Definition at line 472 of file xkb.cpp.

◆ keycodeFromKeysym()

std::optional< int > KWin::Xkb::keycodeFromKeysym ( xkb_keysym_t keysym)

Definition at line 750 of file xkb.cpp.

◆ keymap()

xkb_keymap * KWin::Xkb::keymap ( ) const
inline

Definition at line 75 of file xkb.h.

◆ keymapContents()

QByteArray KWin::Xkb::keymapContents ( ) const

Definition at line 363 of file xkb.cpp.

◆ layoutName() [1/2]

QString KWin::Xkb::layoutName ( ) const

Definition at line 491 of file xkb.cpp.

◆ layoutName() [2/2]

QString KWin::Xkb::layoutName ( xkb_layout_index_t index) const

Definition at line 483 of file xkb.cpp.

◆ layoutShortName()

QString KWin::Xkb::layoutShortName ( int index) const

Definition at line 496 of file xkb.cpp.

◆ leds()

LEDs KWin::Xkb::leds ( ) const
inline

Definition at line 70 of file xkb.h.

◆ ledsChanged

void KWin::Xkb::ledsChanged ( const LEDs & leds)
signal

◆ modifiers()

Qt::KeyboardModifiers KWin::Xkb::modifiers ( ) const
inline

Definition at line 165 of file xkb.h.

◆ modifiersRelevantForGlobalShortcuts()

Qt::KeyboardModifiers KWin::Xkb::modifiersRelevantForGlobalShortcuts ( uint32_t scanCode = 0) const

Definition at line 519 of file xkb.cpp.

◆ modifierState()

const auto & KWin::Xkb::modifierState ( ) const
inline

Definition at line 90 of file xkb.h.

◆ modifierStateChanged

void KWin::Xkb::modifierStateChanged ( )
signal

◆ numberOfLayouts()

quint32 KWin::Xkb::numberOfLayouts ( ) const

Definition at line 737 of file xkb.cpp.

◆ reconfigure

void KWin::Xkb::reconfigure ( )
slot

Definition at line 152 of file xkb.cpp.

◆ setConfig()

void KWin::Xkb::setConfig ( const KSharedConfigPtr & config)

Definition at line 142 of file xkb.cpp.

◆ setFollowLocale1()

void KWin::Xkb::setFollowLocale1 ( bool follow)

◆ setModifierLatched()

void KWin::Xkb::setModifierLatched ( Qt::KeyboardModifier mod,
bool latched )

Definition at line 643 of file xkb.cpp.

◆ setModifierLocked()

void KWin::Xkb::setModifierLocked ( Qt::KeyboardModifier mod,
bool locked )

Definition at line 690 of file xkb.cpp.

◆ setNumLockConfig()

void KWin::Xkb::setNumLockConfig ( const KSharedConfigPtr & config)

Definition at line 147 of file xkb.cpp.

◆ setSeat()

void KWin::Xkb::setSeat ( SeatInterface * seat)

Definition at line 745 of file xkb.cpp.

◆ shouldKeyRepeat()

bool KWin::Xkb::shouldKeyRepeat ( quint32 key) const

Definition at line 602 of file xkb.cpp.

◆ state()

xkb_state * KWin::Xkb::state ( ) const
inline

Definition at line 80 of file xkb.h.

◆ switchToLayout()

bool KWin::Xkb::switchToLayout ( xkb_layout_index_t layout)

Definition at line 629 of file xkb.cpp.

◆ switchToNextLayout()

void KWin::Xkb::switchToNextLayout ( )

Definition at line 610 of file xkb.cpp.

◆ switchToPreviousLayout()

void KWin::Xkb::switchToPreviousLayout ( )

Definition at line 620 of file xkb.cpp.

◆ toKeysym()

xkb_keysym_t KWin::Xkb::toKeysym ( uint32_t key)

Definition at line 555 of file xkb.cpp.

◆ toQtKey()

Qt::Key KWin::Xkb::toQtKey ( xkb_keysym_t keysym,
uint32_t scanCode = 0,
Qt::KeyboardModifiers modifiers = Qt::KeyboardModifiers(),
bool superAsMeta = false ) const

Definition at line 583 of file xkb.cpp.

◆ toString()

QString KWin::Xkb::toString ( xkb_keysym_t keysym)

Definition at line 570 of file xkb.cpp.

◆ updateKey()

void KWin::Xkb::updateKey ( uint32_t key,
InputRedirection::KeyboardKeyState state )

Definition at line 393 of file xkb.cpp.

◆ updateModifiers()

void KWin::Xkb::updateModifiers ( uint32_t modsDepressed,
uint32_t modsLatched,
uint32_t modsLocked,
uint32_t group )

Definition at line 380 of file xkb.cpp.

Member Data Documentation

◆ depressed

xkb_mod_index_t KWin::Xkb::depressed = 0

Definition at line 156 of file xkb.h.

◆ latched

xkb_mod_index_t KWin::Xkb::latched = 0

Definition at line 157 of file xkb.h.

◆ locked

xkb_mod_index_t KWin::Xkb::locked = 0

Definition at line 158 of file xkb.h.

◆ state

xkb_compose_state* KWin::Xkb::state = nullptr

Definition at line 148 of file xkb.h.

◆ table

xkb_compose_table* KWin::Xkb::table = nullptr

Definition at line 147 of file xkb.h.


The documentation for this class was generated from the following files: