loadFromModule: What exactly is the typename?
-
I don't find any good description of the typename in functions such as QQmlComponent::loadFromModule
In examples where the QML file is in the same folder as everything else, it seems to be simply the name of the QML file without extension.
So "Main.qml" which is part of QML module "People" is loaded viaQQmlComponent component(&engine); component.loadFromModule("People", "Main");
However, in real life, it's rare that all files are in the same folder. So does the typename have to take subfolders into account? Or the resource path? Or something else?
-
I don't find any good description of the typename in functions such as QQmlComponent::loadFromModule
In examples where the QML file is in the same folder as everything else, it seems to be simply the name of the QML file without extension.
So "Main.qml" which is part of QML module "People" is loaded viaQQmlComponent component(&engine); component.loadFromModule("People", "Main");
However, in real life, it's rare that all files are in the same folder. So does the typename have to take subfolders into account? Or the resource path? Or something else?
@Asperamanca
Looks like typically, the Typename should be the QML filename without extension, regardless of folder structure. -