Skip to content

feat: v0.6 — accessible keys, panel scanning, themed chips, tabbed settings - #7

Merged
secondtruth merged 8 commits into
mainfrom
feat/v0.6-polish
Sep 17, 2026
Merged

secondtruth merged 8 commits into
mainfrom
feat/v0.6-polish

Conversation

@secondtruth

@secondtruth secondtruth commented Sep 17, 2026 •

Copy link
Copy Markdown
Owner

Summary

v0.6 across core, app and docs. Six commits, meant to be read in order; the first two are core-only and keep the app building on their own.

Core

  • Word prediction search (fix(core)): the trie walk stopped after 500 nodes of an unordered dictionary traversal, so short prefixes missed frequent words and results differed between runs. Nodes now carry the best rank of their subtree and the search follows it. Learned counts live beside the trie and can be cleared.
  • Preferences (feat(core)): keys are a public Preferences.Key enum; the change notification carries the key and is only posted for real changes. Adds per-panel origin storage (reads the v0.5 keyboard position as fallback).

App

  • KeyboardView.swift split into KeyView, SuggestionBarView, DwellTimer, KeyPresentation.
  • Suggestions are theme-drawn chips with dwell progress instead of NSButtons.
  • Keys and chips are accessibility buttons with spoken names (en/de) and a press action.
  • Scanning covers open panels; hidden keyboards are not scanned.
  • Panels remember their position and keep it across rebuilds.
  • KeyboardController reacts to the changed preference instead of rebuilding everything per change.
  • Themes: border, panelText, scanHighlight, usesVibrancy; System theme blurs the desktop; High Contrast current-text bar was unreadable (key-cap color on black) and latched modifiers turned muddy.
  • Settings: toolbar tabs, slider value labels, dependent controls disabled with their switch, confirmation before clearing learned words.
  • --snapshot DIR renders every theme and settings pane to PNGs off-screen.

Test plan

  • make test — 76 tests pass (5 new: predictor search, clearLearned, keyed/no-op preference notifications, panel origins)
  • swift build and swift build -c release without warnings
  • openosk --smoke-test prints SMOKE_TEST_OK
  • --snapshot output reviewed for all four themes and all settings panes
  • Not verified on screen: System theme blur, dragging the panel by its background over the blur view, scanning across panels, settings tab resize animation
  • Linux CI green. The first run failed in the new preference tests, not in the code: NotificationCenter's object: filter on Linux never matches a non-NSObject sender. Reproduced in swift:6.1, fixed in the test(core) commit by matching the sender by identity.

🤖 Generated with Claude Code

secondtruth and others added 5 commits September 17, 2026 23:01
The prediction search stopped after 500 nodes of an unordered dictionary
walk, so one- and two-letter prefixes missed frequent words and returned
different results between runs. Nodes now carry the best rank of their
subtree and the search follows it.

Learned counts move out of the trie into a dictionary and get a
clearLearned(), which "Clear learned words" needs to take effect before
the next launch.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Preference keys become the public Preferences.Key enum; the change
notification carries the key and is skipped when the value did not
change, so observers can react to one setting instead of rebuilding for
all of them. Adds per-panel origin storage, reading the v0.5 keyboard
position as a fallback.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
A .build symlinked off a File Provider mount is a file to git; the
trailing slash only matched the directory.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…d settings

Keyboard
- Split KeyboardView.swift into KeyView, SuggestionBarView, DwellTimer
  and KeyPresentation.
- Replace the NSButton suggestions with theme-drawn chips that show
  dwell progress and drop suggestions that do not fit.
- Expose keys and chips as accessibility buttons with spoken names and
  a press action (VoiceOver, Voice Control).
- Themes gain border, panelText, scanHighlight and usesVibrancy; the
  System theme blurs the desktop behind the panel. The High Contrast
  current-text bar used a key-cap color that was unreadable on black.
- Key and panel corner radii scale with the key size; media keys and
  the System panel use SF Symbols instead of emoji; the variant popup
  follows the theme.

Behaviour
- KeyboardController reacts to the changed preference key instead of
  rebuilding the keyboard and all panels on every change.
- ScanController scans the groups of a provider: the visible keyboard
  plus open panels.
- Panels remember their position and keep it across rebuilds.
- "Clear learned words" also clears the in-memory counts and asks for
  confirmation.

Settings
- Replace the single 25-row grid with toolbar tabs (General, Typing,
  Access, Panels), value labels on sliders, and dependent controls that
  disable with their switch. Key size applies on release.
- SettingsController takes a closure instead of the KeyboardController.

Tooling
- Add --snapshot DIR, which renders every theme and settings pane to
  PNGs off-screen. Bump the version to 0.6.0.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Copilot AI lite review requested due to automatic review settings September 17, 2026 21:02
@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.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.

NotificationCenter's object: filter on Linux never matches a sender that
is not an NSObject, so the keyed-change test saw no notifications there
and the no-op test passed without observing anything. The tests now
observe unfiltered and compare the sender themselves; the no-op test
also asserts that a real change is logged.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Opacity changes no longer update the main keyboard, and the settings window title was dropped during the refactor.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

This PR delivers v0.6 across prediction, preferences, accessibility, scanning, theming, settings, and documentation.

Changes:

  • Reworked trie prediction and learned-word clearing.
  • Added accessible themed keys/chips, panel scanning, position persistence, and vibrancy themes.
  • Added tabbed settings, snapshots, tests, and updated documentation.
File summaries
File Description
TODO.md Marks v0.6 work complete.
Tests/OpenOSKCoreTests/WordPredictorTests.swift Adds predictor regression tests.
Tests/OpenOSKCoreTests/PreferencesTests.swift Adds preference notification and position tests.
Sources/OpenOSKCore/WordPredictor.swift Implements ranked trie search and clearing.
Sources/OpenOSKCore/Resources/Panels/system.json Adds themed macro icons.
Sources/OpenOSKCore/Preferences.swift Adds keyed notifications and panel origins.
Sources/OpenOSK/VariantPopup.swift Applies themes to variant popups.
Sources/OpenOSK/Theme.swift Adds borders, panel text, highlights, and vibrancy.
Sources/OpenOSK/SuggestionBarView.swift Adds themed accessible suggestion chips.
Sources/OpenOSK/Snapshot.swift Adds off-screen keyboard/settings rendering.
Sources/OpenOSK/SettingsController.swift Adds tabbed settings and confirmation UI.
Sources/OpenOSK/ScanController.swift Scans dynamic keyboard and panel groups.
Sources/OpenOSK/Resources/en.lproj/Localizable.strings Adds English v0.6 strings.
Sources/OpenOSK/Resources/de.lproj/Localizable.strings Adds German v0.6 strings.
Sources/OpenOSK/PanelsController.swift Persists panels and exposes scan groups.
Sources/OpenOSK/main.swift Updates version and adds --snapshot.
Sources/OpenOSK/KeyView.swift Adds accessible, themed key rendering and input behavior.
Sources/OpenOSK/KeyPresentation.swift Adds spoken names and media symbols.
Sources/OpenOSK/KeyboardView.swift Refactors the keyboard container and themed backdrop.
Sources/OpenOSK/KeyboardPanel.swift Adds per-panel origin restoration.
Sources/OpenOSK/KeyboardController.swift Integrates scanning, keyed preferences, and learned-word clearing.
Sources/OpenOSK/DwellTimer.swift Centralizes dwell timing.
Sources/OpenOSK/AppDelegate.swift Wires learned-word clearing into settings.
README.md Documents v0.6 capabilities and snapshot support.
CLAUDE.md Documents snapshot usage.
AGENTS.md Updates architecture and preference guidance.
.gitignore Ignores .build directories and symlinks.
Review details
  • Files reviewed: 26/27 changed files
  • Comments generated: 2
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread Sources/OpenOSK/KeyboardController.swift
Comment thread Sources/OpenOSK/SettingsController.swift
secondtruth and others added 2 commits September 17, 2026 23:16
Every make target and scripts/bundle.sh pass SCRATCH_PATH (default
.build) to SwiftPM as --scratch-path; the bundle script resolves the
product directory with --show-bin-path instead of assuming
.build/release. On a synced or network volume codesign rejects the
volume's extended attributes and `make test` fails; building into a
local directory avoids that.

AGENTS.md drops the .build symlink advice: Synology Drive restores the
server's directory and renames the symlink away.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
The toolbar-style tab controller titles the settings window after the
selected tab, so the string lost its only use. Comments now say so, and
say that noteActivity() is what applies a new opacity to the keyboard.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
@secondtruth
secondtruth merged commit 67db9b1 into main Sep 17, 2026
2 checks passed
@secondtruth
secondtruth deleted the feat/v0.6-polish branch September 17, 2026 21:19
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