[SOLVED] Can't find Qt Controls in Qt Quick Designer/Qt Creator 3.0.1
-
I'm new to using Qt Quick, so I apologize if this is a horribly newbie question...
I was referring to the document "Using Qt Quick Designer":http://qt-project.org/doc/qtcreator-3.0/creator-using-qt-quick-designer.html and I knew I was in trouble when I couldn't find the <code>Qt Controls</code> in the Library pane. What I see is this:
!http://feigenson.net/ForumUploads/ScreenShot2014-02-08at7.17.30PM.jpg(No Qt Controls)!
I'm running Qt Creator 3.0.1, which I built myself:
!http://feigenson.net/ForumUploads/ScreenShot2014-02-08at7.19.39PM.jpg(About Qt Creator)!
The doc says To view the components and controls in the Library pane, import the component sets in the Imports pane. The Imports pane looks like this, and the <code><add import></code> button doesn't do anything:
!http://feigenson.net/ForumUploads/ScreenShot2014-02-08at7.17.20PM.jpg(Can't import anything else)!
So, being new, I don't know how to proceed. Can anyone help?Thanks!
-
Hi,
can you check the Qt that is configured for your project?
If controls are available is determined by the Qt version. -
[quote author="ThomasHartmann" date="1391964623"]Hi,
can you check the Qt that is configured for your project?
If controls are available is determined by the Qt version.[/quote]Good point! I had been using a slightly old 5.2.1 build, so I created a new kit with my latest build (which shows as 5.2.2), but no difference. Is there some setting/preference I need to set to make the controls appear?
Thanks!
-Eric
-
My guess would be that your latest build is missing Qt Quick Controls.
The code model does check the qml directory of Qt for the Controls plugin. -
Well, the answer is, of course, simple-stupid...
When I configured the project, I chose "Qt Quick 2.0" (or maybe 2.1), which was the default. Little did I know that there was another option "Qt Quick Controls 1.0". I found selecting that added <code>import QtQuick.Controls 1.0</code> into the QML file. I added that line, and now, lo and behold the controls are visible!
Is this documented anywhere? If not, it should be :)