Skip to content

Qualify the palette as Commons.Color for Qt 6.12 - #1

Open
Harlock123 wants to merge 1 commit into
dbohry:mainfrom
Harlock123:qt612-commons-color
Open

Harlock123 wants to merge 1 commit into
dbohry:mainfrom
Harlock123:qt612-commons-color

Conversation

@Harlock123

Copy link
Copy Markdown

Qt 6.12 added a QtQuick Color type that shadows the shell's qs.Commons Color singleton. With the unqualified import, every Color.foreground, Color.popups.text and so on resolves to undefined on Qt 6.12, so the plugin draws without theme colours, and the shell log fills with TypeError: Cannot read property ... of undefined.

This imports qs.Commons as Commons alongside the existing import and qualifies palette references as Commons.Color.x, as Omarchy itself does since omacom/omarchy#14553. Style, Util and Border keep their unqualified names. On older Qt this changes nothing, since Commons.Color is the same singleton.

Tested on Omarchy with Qt 6.12.0 and Quickshell 0.3.2 (aarch64): after the change, the plugin renders with theme colours and logs no undefined-property errors.

🤖 Generated with Claude Code

Qt 6.12's QtQuick exports its own Color type, which shadows the shell's
qs.Commons Color singleton, so bare Color.x resolves to undefined and the
plugin loses its theme colours. Import qs.Commons as Commons and use
Commons.Color, as Omarchy does since omacom/omarchy#14553.

Co-Authored-By: Claude Opus 5.5 <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