Qt controls in QML
Can I use the Qt controls in QML? Something like the Windows Forms controls in WPF ( "http://msdn.microsoft.com/en-us/library/ms742875.aspx":http://msdn.microsoft.com/en-us/library/ms742875.aspx )?
Which Qt controls?
like DateTime picker? Slider ? or some custom control. Basically, I want to re-use my investment done for those control in QML as well.
Qt Components does not provide this today and should not be recommended yet to be used in applications, as it's still under heavy development and there is no guarantee of either API and features.
Alternatives (not ideal, I know):
- Encapsulate those controls in QGraphicsProxyWidgets then export them as Components to be used in QML
- Create a QML based control, with a QOBject as model (this one could be the basis for a future Qt-Components part)
Yes, if you want to contribute with Qt-Components, you're welcome! In the second link posted by Alexander you'll find information about the project and how to be part of it. :-)
Thank you very much Alexander and Anselmo. Do you recommend to use the current Qt controls in QML or just create those again in QML from scratch?
[quote author="Sreejumon" date="1289409061"]Thank you very much Alexander and Anselmo.
[quote author="Sreejumon" date="1289409061"]
Do you recommend to use the current Qt controls in QML or just create those again in QML from scratch?[/quote]
Well, if you have enough time and resources, I would recommend creating them in QML (of course with parts in C++).
But this is my opinion based on the experience I had mixing QWidgets with QML - you'll face some issues, e.g. input focus stuff, etc.
Stupid question: What is a control? Is that how widgets are called on windows?
Tobias, yeah, something like that. Came from MFC or something near it.
Vincent Vega: "And you know what they call a ... a ... a Quarter Pounder with cheese in Paris?"
Jules: "They don't call it a Quarter Pounder with cheese?"
Vincent Vega: "No man, they got the metric system. They wouldn't know what a Quarter Pounder is."
Jules: "Then what do they call it?"
Vincent Vega: "They call it a "Royale" with cheese."