Home
Reading
Searching
Subscribe
Sponsors
Statistics
Posting
Contact
Spam
Lists
Links
About
Hosting
Filtering
Features Download
Marketing
Archives
FAQ
Blog
 
Gmane
From: <Sergiy.Dubovik-xNZwKgViW5gAvxtiuMwx3w <at> public.gmane.org>
Subject: Re: QML support in Meego touch Framework
Newsgroups: gmane.comp.handhelds.meego.touch.devel
Date: Monday 10th January 2011 12:24:33 UTC (over 5 years ago)
With such approach you can do very little with meegotouch.
It's better to do it like this:

    MApplication a(argc, argv);
    QDeclarativeEngine engine;

    MApplicationWindow window;
    window.show();
    MApplicationPage *page = new MApplicationPage();
    page->setPannable(false);
    page->appear();

    QGraphicsObject *content = loadQmlComponent(engine,
"myqmlfile.qml");
    MWidget * centralWidget = new MWidget;
    content->setParentItem(centralWidget);
    centralWidget->setMinimumSize(864, 400);
    page->setCentralWidget(centralWidget);

    return a.exec();


To use meegotouch components from qml you would need to register them like
this:
QML_DECLARE_TYPE(MButton)
..
qmlRegisterType("com.nokia.meegotouch.native", 0, 20, "MButton");


Then in qml you could write like this:
import com.nokia.meegotouch.native 0.20

Item {
 id: rootItem
 MButton {
 }
}
...

:sergiy

On Jan 10, 2011, at 1:27 PM, ext Apte Abhijit (Nokia-MS/Bangalore) wrote:

> Hi,
> 
> Yes, you can verify the UI using qmlviewer, but inorder to integrate your
QML into Qt C++ try something like,
> 
>    mView = new QDeclarativeView();
>    mContext = mView->rootContext();
>    mContext->setContextProperty( "controller", this );
>    mView->setSource( QUrl( "qrc:/qml/myfirstqmlapp.qml" ) );
>    mView->setGeometry( QRect( 0, 0, 800, 480 ) );
> 
> Also you've got to write a qrc file (resource file).
> 
> Rgds
> -Abhi
> 
> On 01/10/2011 04:40 PM, ext
[email protected] wrote:
>> Hello,
>> 
>> Just a little comments: Applications are not run with qmlviewer!
>> Qmlviewer is a debugging app and not actual application framework!
>> 
>> Br,
>> Karoliina
>> 
>> ---
>> Karoliina Salminen
>> Technical Product Owner, MeeGo Computers
>> Startup Wizard, Cherry, Settings, Settings Applets, User Guide
>> Ruoholahti B5 open space      Tel. +358 50 5686514
>> ----
>> Twitter: @karoliinasalmin
>> Blog: http://karoliinasalminen.wordpress.com
>> 
>> 
>> From: ext
yfengying>
>> Date: Mon, 10 Jan 2011 18:30:14 +0800
>>
To:<[email protected]>
>>
Cc:>
>> Subject: Re: [MeeGo-touch-dev] QML support in Meego touch Framework
>> 
>> Hi John:
>> 
>>     It was supported by Meegotouch framework,
>> 
>> after #zypper install qt-qmlviewer , you can launch the qml project as
following:
>> 
>> #qmlviewer *.qml
>> 
>> BRs
>> 
>> sophia
>> 
>> From: john
pratss
>> Sent: Monday, January 10, 2011 6:15 PM
>> To:
[email protected]
>> Subject: [MeeGo-touch-dev] QML support in Meego touch Framework
>> 
>> Hi,
>> 
>> Is there a support of QML in Meegotouch framework.
>> 
>> Thanks,
>> John.
>> 
>> ________________________________
>> 
>> _______________________________________________
>> MeeGo-touch-dev mailing list
>>
[email protected]
>> http://lists.meego.com/listinfo/meego-touch-dev
>> _______________________________________________ MeeGo-touch-dev mailing
list
[email protected]
 http://lists.meego.com/listinfo/meego-touch-dev
>> 
>> 
>> 
>> _______________________________________________
>> MeeGo-touch-dev mailing list
>> [email protected]
>> http://lists.meego.com/listinfo/meego-touch-dev
> _______________________________________________
> MeeGo-touch-dev mailing list
> [email protected]
> http://lists.meego.com/listinfo/meego-touch-dev
 
CD: 5ms