Skip to content

tooling: fill in missing qml type info - #1220

Open
ilyaZar wants to merge 1 commit into
quickshell-mirror:masterfrom
ilyaZar:fix-qml-type-metadata
Open

ilyaZar wants to merge 1 commit into
quickshell-mirror:masterfrom
ilyaZar:fix-qml-type-metadata

Conversation

@ilyaZar

@ilyaZar ilyaZar commented Sep 28, 2026 •

Copy link
Copy Markdown

fixes #1037

these warnings came from three missing links in the generated type info

bluetooth returns an object model from the main quickshell module so its qmldir
needs to list that module as a dependency

polkit stores authflow under its full c++ name so the flow property needs to use
the same name

panelwindow gets margins from the core module so the window target needs the
core metadata too

the anonymous margins entry then gives qmllint the left right top andbottom properties in the module where panelwindow uses them

i built the bluetooth polkit and window targets and ran example from the issue against the "generated" qml modules

Comment thread src/window/CMakeLists.txt
Comment on lines 21 to 23
target_link_libraries(quickshell-window PRIVATE
Qt::Core Qt::Gui Qt::Quick Qt6::QuickPrivate
Qt::Core Qt::Gui Qt::Quick Qt6::QuickPrivate quickshell-core
)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Would rather avoid since this slows compile. qs_add_module_deps_light is generally supposed to accomplish the same things for qml types.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

done

Comment thread src/window/panelinterface.hpp Outdated
Comment on lines +12 to +17
struct WindowMarginsForeign {
Q_GADGET;
QML_FOREIGN(Margins);
QML_ANONYMOUS;
};

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Probably shouldnt be required since we have control of the original type

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

done

@outfoxxed
outfoxxed force-pushed the master branch 2 times, most recently from 72a1ce2 to 11ca60b Compare October 6, 2026 04:21
@ilyaZar
ilyaZar force-pushed the fix-qml-type-metadata branch 2 times, most recently from 8ffc24f to 8d8659f Compare October 7, 2026 14:18
declare the bluetooth dependency and use the registered polkit type name

let the window module read margins directly without linking all of core
@ilyaZar
ilyaZar force-pushed the fix-qml-type-metadata branch from 8d8659f to 1f33342 Compare October 7, 2026 14:23
@ilyaZar

ilyaZar commented Oct 7, 2026

Copy link
Copy Markdown
Author

@outfoxxed thanks for the review

just for more context:
the margins part i moved the existing Margins declaration from core/types.hpp into its own core/margins.hpp header

i thought keeping it separate because adding all of types.hpp to the window target would also register unrelated types like Box and Edges there

otherwise this gets rid of both the hard core link and the foreign wrapper the main Quickshell module already default imports _Window so the existing warnings are gone and generating , as far as I can tell, and you were right the window type info no longer builds core is better

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.

qmllint: several Quickshell-specific types/grouped-properties are not declaratively resolvable (AuthFlow, UntypedObjectModel, PanelWindow.margins)

2 participants