[PySide] Questions about Pyside Assistant
th.perl at gmail.com
Sun May 27 22:01:14 CEST 2012
2012/5/27 Andy Frances <af.stackless at gmail.com>:
> I am new to N9 development. I am using Pyside Assistant to run the Pyside
> Mobility sample application showcoordinates.py. This is a simple console
> Python application. However I need aegis to give it permission. I have a few
> conceptual problems.
> 1) When I generate a showcoordinates direction with psa init, I get a
> showcoordinate template. Do I replace it with my copy of
Yes, you can overwrite the "showcoordinates" file in the generated
directory with your showcoordinates.py file (make sure to remove the
".py" at the end, otherwise you would have to update the path to it in
at least setup.py and the .desktop file).
> 2) What does my setup.py file look like? I am also new to setup.py.
For some general information on what setup.py does in the Python
world, see this document:
The generated setup.py file should be okay - you can edit the
description there if you want and make sure that the maintainer name
and e-mail is okay. The "scripts=" tells which script is used as
"main" application script.
> 3) Does the application get a default application icon (the generated
> imply this)?
In the generated folder there should be a showcoordinates.png file
that you can replace with your own (80x80 PNG) icon. To create an
icon, you can go to this URL and download the "Nokia Icon Toolkit"
.zip file which includes an SVG template for the squircle with the
right colors and guide lines, etc..:
> 4) Should the application be placed in /opt? (right now it is going in the
> same directory as where it resides on my host machine!)
If you are targetting just your own device or apps.formeego.org, the
default setup is okay. If you want to publish your app in Nokia Store
(via Ovi Publish), you have to make sure that most files (except for
the .desktop file, which has to go into /usr/share/applications) are
installed into /opt. There are some blogs that talk about this, e.g.:
More information about the PySide