Skip to content

Qualify the Color singleton as Commons.Color for Qt 6.12 - #38

Open
bahoerres wants to merge 1 commit into
paulpitchford:mainfrom
bahoerres:qt612-commons-color
Open

bahoerres wants to merge 1 commit into
paulpitchford:mainfrom
bahoerres:qt612-commons-color

Conversation

@bahoerres

Copy link
Copy Markdown

What changed

Qt 6.12 adds a Color type to QtQuick. In a file that imports both QtQuick and qs.Commons, a bare Color now resolves to Qt's type, not Omarchy's theme singleton, so references like Color.accent come back undefined and the panel loses its theme colours.

This imports qs.Commons under an alias in the nine QML files that use the singleton and references it as Commons.Color. It is the same change Omarchy made to its own shell in omacom/omarchy#14553. Nothing else changes.

Security and privacy

No change.

Verification

  • uv run ruff format --check .
  • uv run ruff check .
  • uv run mypy src tests
  • uv run pytest
  • uv run pyscn check --max-complexity 12 --max-cycles 0 src
  • Applicable Omarchy and QML checks
  • Complete diff reviewed for secrets and personal data

The Python checks were not run: the diff touches QML only. The patched plugin has been running on Omarchy 4.5.0 with Qt 6.12.0.

Code review

Reviewer type: separate author self-review

Findings

No findings. The diff adds import qs.Commons as Commons to nine QML files and qualifies their existing Color. references; no logic changes.

Accepted warnings

None.

🤖 Generated with Claude Code

Qt 6.12 adds a QtQuick `Color` type. A file that imports both QtQuick
and qs.Commons then resolves a bare `Color` to Qt's type, which has none
of the Omarchy theme properties, so those colours come back undefined.
Import qs.Commons under an alias and reference the singleton through it,
the same fix Omarchy applied to its own shell.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
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.

1 participant