| Reply | « Previous Thread | Next Thread » |
|
“py2sis” does not currently offer the possibility to add icons to the SIS-files it generates. Nevertheless, you can achieve this at least in two different ways:
Option 1: 1. Generate a stand alone installation “.sis” from your script (e.g. "foobar.py") with “py2sis” tool and install this application to your device 2. See e.g. the instructions at http://www.newlc.com/article.php3?id_article=197 and generate an “.aif” file for your stand-alone installation. Notice especially that the UID given as a command line parameter to “py2sis” and in the “.rss” file need to match. Also the “.aif” filename needs to match with your application. 3. Move the “.aif” file to the device and to the folder where you have installed the application in Step 1. (e.g. in “C:\”-drive the folder is “C:\System\Apps\foobar”). In order to achieve this you probably need a file browser in your device. Option 2: 1. Generate a stand-alone installation “.sis” from your script with “py2sis” tool with the undocumented switch “--leavetemp”. This leaves the temporary files added to the generated “.sis” in your “py2sis” tool folder in a new subfolder “temp”, e.g. “C:\Nokia\Tools\Python_for_Series_60\py2sis\temp”. 2. Create the “.aif” file for your application and add this file to the created “temp” folder (see the link in Step 2. in the Option 1). 3. Add a line to the end of “.pkg” file under the "temp" folder specifying the “.aif” file, e.g.: "foobar.aif" -"!:\system\apps\foobar\foobar.aif" 4. Run “makesis” with the modified “.pkg” file: makesis foobar.pkg 5. Install the created “.sis” file to your device. |
|
Just to confirm that option 2 works really well for making icons applying to standalone Python applications. It's a bit of a workaround and fiddly, but it gets there in the end.
Steve |
| slitchfield |
| View Public Profile |
| Find all posts by slitchfield |
|
There's an easier way for this in UNIX-like systems. Python-to-SIS, the next generation has a support for application icons. It takes the icon in Symbian MBM format and generates the AIF file automatically.
http://www.nbl.fi/jussi.ylanen/py2sisng.html |
|
Is there an easy way to convert bitmaps to .mbm files on UNIX-based systems.
I had a look on the Gimp, but it doesn't seem to directly support .mbm files. |
|
Quote:
I had to modify it a little, as it sometimes generated invalid MBMs. Patch included: Code:
diff -rC3 bmconv-1.1.0-2_orig/src/pbmcomp.cpp bmconv-1.1.0-2/src/pbmcomp.cpp *** bmconv-1.1.0-2_orig/src/pbmcomp.cpp Mon Jan 5 02:23:39 2004 --- bmconv-1.1.0-2/src/pbmcomp.cpp Thu Sep 29 17:05:45 2005 *************** *** 376,382 **** --- 376,387 ---- int dataSize = aPbm->iBitmapSize - sizeof(SEpocBitmapHeader); WriteBuf32((char*)(aPbm),sizeof(SEpocBitmapHeader)); + #if 0 WriteBuf16(((char*)(aPbm)) + sizeof(SEpocBitmapHeader),dataSize); + #else + // WriteBuf16() cannot handle odd number of bytes (2005-09-28 by JY) + iDestFile.write(((char*)(aPbm)) + sizeof(SEpocBitmapHeader),dataSize); + #endif return NoError; } |
| Reply | « Previous Thread | Next Thread » |
| Thread Tools | Search this Thread |
|---|---|
| Rate This Thread | |