[PR #343] feat: show modifier-only keypresses in visualizer #342

Open
opened 2026-05-05 05:13:41 -06:00 by gitea-mirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/keycastr/keycastr/pull/343
Author: @quiet-node
Created: 4/10/2026
Status: 🔄 Open

Base: mainHead: main


📝 Commits (1)

  • 196459f feat: show modifier-only keypresses in visualizer

📊 Changes

2 files changed (+26 additions, -1 deletions)

View changed files

📝 keycastr/KCDefaultVisualizer.h (+2 -0)
📝 keycastr/KCDefaultVisualizer.m (+24 -1)

📄 Description

Problem

Pressing a modifier key alone (⌘, ⇧, ⌥, ⌃) showed nothing. Only combos like ⌘E worked.

This is because macOS fires kCGEventFlagsChanged for modifier-only presses instead of kCGEventKeyDown. KeyCastr already captured these events but noteFlagsChanged: was a no-op.

Fix

Implement noteFlagsChanged: to detect newly pressed modifiers and display their glyphs. Respects the existing "Command Keys Only" display mode.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/keycastr/keycastr/pull/343 **Author:** [@quiet-node](https://github.com/quiet-node) **Created:** 4/10/2026 **Status:** 🔄 Open **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (1) - [`196459f`](https://github.com/keycastr/keycastr/commit/196459f772d8ad3cbb6ebfb7dbce5c79d83991ed) feat: show modifier-only keypresses in visualizer ### 📊 Changes **2 files changed** (+26 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `keycastr/KCDefaultVisualizer.h` (+2 -0) 📝 `keycastr/KCDefaultVisualizer.m` (+24 -1) </details> ### 📄 Description ## Problem Pressing a modifier key alone (⌘, ⇧, ⌥, ⌃) showed nothing. Only combos like ⌘E worked. This is because macOS fires `kCGEventFlagsChanged` for modifier-only presses instead of `kCGEventKeyDown`. KeyCastr already captured these events but `noteFlagsChanged:` was a no-op. ## Fix Implement `noteFlagsChanged:` to detect newly pressed modifiers and display their glyphs. Respects the existing "Command Keys Only" display mode. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
gitea-mirror added the
pull-request
label 2026-05-05 05:13:41 -06:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: github-starred/keycastr#342
No description provided.