mirror of
https://github.com/yusufipk/dikte.git
synced 2026-09-11 10:56:10 +00:00
Stop telling every desktop that it is KDE
Only GNOME was recognised, and everything else was handed to KWin. On i3, XFCE, Cinnamon, MATE, sway and the rest, Dikte wrote an entry into kglobalshortcutsrc that nothing reads, called the session KDE, and promised that the keys would work after the next login. They never did. There is no backend to write for any of them. The /dev/input listener is already desktop-agnostic, so those sessions are the case macOS has always been: no registry, nothing to install, nothing to remove, and the combination held by the running process. One backend() function decides which of the four this session has, and the name shown, the status read back, what Install writes, what Settings explains and what the installer promises are all taken from it, so they cannot disagree. A desktop now only counts when the program that writes its registry is there too. A GNOME session without gsettings and a Plasma one without kwriteconfig6 fall to the listener rather than to a file, which is also how Plasma 5 stops erroring on a kwriteconfig6 it never had. What Settings shows on those desktops is the truth: no Install button, no KWin, no listener checkbox (it is the mechanism, not a choice), what reading /dev/input costs, that the focused application sees the keys too, and the command to bind if you would rather your desktop owned them. The evdev listener records what it is listening for the way the Carbon one does, so the status line has something to say there at all. Closes #28
This commit is contained in:
@@ -5,7 +5,8 @@ machine by default, a model cleans it up (dropping the *uh*s, the restarts, the
|
||||
missing punctuation), and the result lands in your clipboard and is pasted into
|
||||
whatever window you were typing in.
|
||||
|
||||
Built for KDE Plasma 6 on Wayland, and runs on GNOME X11 and macOS too. No
|
||||
Built for KDE Plasma 6 on Wayland, and runs on GNOME X11, macOS and any other
|
||||
Linux desktop that will let it read the keyboard. No
|
||||
dependencies beyond system packages: just the Python standard library, 3.11 or
|
||||
newer, and PyQt6.
|
||||
|
||||
@@ -184,14 +185,19 @@ running.
|
||||
right-click to delete.
|
||||
- **Turkish and English interface**, following the system locale by default.
|
||||
|
||||
## The global shortcuts need one logout
|
||||
## The global shortcuts, and the logout KDE needs
|
||||
|
||||
KWin only reads `kglobalshortcutsrc` at startup, so the shortcuts `install.sh`
|
||||
writes will not fire until you log out and back in. Until then, Settings →
|
||||
Shortcuts → **built-in listener** reads `/dev/input` and catches the combination
|
||||
itself. The difference: it does not swallow the key, so `Ctrl+Space` also reaches
|
||||
the focused application (some editors will pop up autocomplete). The listener
|
||||
needs your user in the `input` group: `sudo usermod -aG input $USER`.
|
||||
needs your user in the `input` group: `sudo usermod -aG input $USER`. On GNOME
|
||||
the shortcut works the moment it is installed, and on a desktop that keeps no
|
||||
registry at all (i3, XFCE, sway and most others) the listener is the whole
|
||||
mechanism: nothing is installed, nothing waits for a logout, and Settings →
|
||||
Shortcuts shows the command to bind if you would rather your desktop owned the
|
||||
keys.
|
||||
|
||||
## Layout
|
||||
|
||||
@@ -211,7 +217,7 @@ vad.py deciding whether a recording holds speech at all
|
||||
filetranscribe.py file transcription: ffmpeg, chunking, timestamps
|
||||
overlay.py the corner indicator
|
||||
settings_ui.py settings window
|
||||
hotkey.py KDE shortcut installation, the evdev listener, Carbon on a Mac
|
||||
hotkey.py the desktop's shortcut registry, the evdev listener, Carbon on a Mac
|
||||
paste.py wl-clipboard and ydotool wrappers, pbcopy and CoreGraphics
|
||||
trayicon.py the tray icons, drawn where there is no icon theme
|
||||
i18n.py the string table
|
||||
|
||||
Reference in New Issue
Block a user