Skip to content

Preserve dead-key keyboard labels - #1457

Merged
Valkirie merged 1 commit into
Valkirie:mainfrom
gsxdsm:agent/fix-dead-key-labels
Aug 6, 2026
Merged

Valkirie merged 1 commit into
Valkirie:mainfrom
gsxdsm:agent/fix-dead-key-labels

Conversation

@gsxdsm

@gsxdsm gsxdsm commented Aug 4, 2026 •

Copy link
Copy Markdown
Contributor

What changed

Accept negative ToUnicodeEx results when generating quick-keyboard labels, provided the output buffer contains the spacing character.

Root cause

Windows returns a negative count for dead keys while still writing a valid spacing character. Treating only positive results as valid leaves dead-key buttons with stale or incorrect labels.

Impact

Quick Keyboard displays valid labels for dead keys across applicable keyboard layouts.

Validation

  • Zero remains the no-translation case.
  • The buffer-length guard prevents indexing an empty result.
  • Change is isolated to keyboard label generation.

Summary by CodeRabbit

  • Bug Fixes
    • Improved keyboard label updates for dead-key inputs.
    • Spacing characters now display correctly when available.

@coderabbitai

coderabbitai Bot commented Aug 4, 2026 •

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 00a86f92-1a75-4033-b7da-5dba77f23d89

📥 Commits

Reviewing files that changed from the base of the PR and between 694d27e and b34459c.

📒 Files selected for processing (1)
  • HandheldCompanion/Views/QuickPages/QuickKeyboardPage.xaml.cs

📝 Walkthrough

Walkthrough

RelabelAll now displays buffered characters when ToUnicodeEx returns negative results, including dead-key spacing characters. The namespace closing line remains unchanged.

Changes

Quick keyboard relabeling

Layer / File(s) Summary
Handle dead-key output during relabeling
HandheldCompanion/Views/QuickPages/QuickKeyboardPage.xaml.cs
RelabelAll now accepts negative ToUnicodeEx results when the output buffer contains a character. The namespace closing line remains equivalent.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Suggested reviewers: valkirie

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Valkirie
Valkirie marked this pull request as ready for review August 6, 2026 06:55
@Valkirie
Valkirie merged commit 70b391e into Valkirie:main Aug 6, 2026
1 check passed
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants