Editing Python/Harmattan/Getting started with Harmattan Python

Warning: You are not logged in. Your IP address will be recorded in this page's edit history.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 62: Line 62:
== Tasting PySide/QML ==
== Tasting PySide/QML ==
-
If you have skipped any of the previous sections and have PySide installed you can see here an [https://web.archive.org/web/20120929010040/http://developer.qt.nokia.com/wiki/Hello_World_in_PySide_and_QtQuick example] taken from PySide documentation website.  
+
If you have skipped any of the previous sections and have PySide installed you can see here an [http://developer.qt.nokia.com/wiki/Hello_World_in_PySide_and_QtQuick example] taken from PySide documentation website.  
-
[https://web.archive.org/web/20120929010040/http://doc.qt.nokia.com/4.7/qdeclarativeintroduction.html QML] is a declarative language designed to describe the user interface of a program: both what it looks like, and how it behaves. In QML, a user interface is specified as a tree of objects with properties. In this tutorial we will show how you can make a simple Hello World application with PySide and QML.
+
[http://doc.qt.nokia.com/4.7/qdeclarativeintroduction.html QML] is a declarative language designed to describe the user interface of a program: both what it looks like, and how it behaves. In QML, a user interface is specified as a tree of objects with properties. In this tutorial we will show how you can make a simple Hello World application with PySide and QML.
A PySide/QML application consists, at least, of two different files – a file with the QML description of the user interface, and a python file which loads the qml file. To avoid problems for now, don’t forget to save both files in the same folder.
A PySide/QML application consists, at least, of two different files – a file with the QML description of the user interface, and a python file which loads the qml file. To avoid problems for now, don’t forget to save both files in the same folder.
Line 122: Line 122:
If you are already familiar with PySide and have followed our tutorials, much of this code is already familiar. The only novelties is that you must import QDeclarativeView and set the source of the QDeclarativeView object to the URL of your QML file. Then, as any Qt widget, you call ''QDeclarativeView.show()''.
If you are already familiar with PySide and have followed our tutorials, much of this code is already familiar. The only novelties is that you must import QDeclarativeView and set the source of the QDeclarativeView object to the URL of your QML file. Then, as any Qt widget, you call ''QDeclarativeView.show()''.
-
Take your time exploring this example. You can try to do basic things as changing the colors, the text, or set other properties to each element, setting a radius on the rectangle color. Check the elements and their properties in [https://web.archive.org/web/20120929010040/http://doc.qt.nokia.com/4.7/qdeclarativeelements.html QML Elements].
+
Take your time exploring this example. You can try to do basic things as changing the colors, the text, or set other properties to each element, setting a radius on the rectangle color. Check the elements and their properties in [http://doc.qt.nokia.com/4.7/qdeclarativeelements.html QML Elements].
== Security framework for Python scripts ==
== Security framework for Python scripts ==

Learn more about Contributing to the wiki.


Please note that all contributions to maemo.org wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see maemo.org wiki:Copyrights for details). Do not submit copyrighted work without permission!


Cancel | Editing help (opens in new window)