Never been to DZone Snippets before?

Snippets is a public source code repository. Easily build up your personal collection of code snippets, categorize them with tags / keywords, and share them with the world

About this user

Korakot Chaovavanich http://korakot.stumbleupon.com

« Newer Snippets
Older Snippets »
Showing 1-1 of 1 total  RSS 

Using icons in Listbox

pys60 1.1.3 provide some graphics capabilitis.
One of them is using icons in Listbox
(code taken from pys60 API reference)
   1  
   2  icon1 = appuifw.Icon(u"z:\\system\\data\\avkon.mbm", 28, 29)
   3  icon2 = appuifw.Icon(u"z:\\system\\data\\avkon.mbm ", 40, 41)
   4  entries = [(u"Signal", icon1),
   5             (u"Battery", icon2)]
   6  lb = appuifw.Listbox(entries, lbox_observe)

Listbox is one of the 3 types that can be assigned to app.body
(i.e. Text, Listbox, Canvas)
So, to make code above able to run, you must add
   1  appuifw.app.body = lb

and the function lbox_observe that will handle the selection
need to be defined.
« Newer Snippets
Older Snippets »
Showing 1-1 of 1 total  RSS