Controllist entries
#1
does anyone know where any documentation is for the controllist that would describe the nx entries.

the python docs in cvs stop short.

self.controlmenu = xbmcgui.controllist(self.offscreenx + self.menux, self.menuy, self.menuw, self.menuh, "font13", "", "list-nofocus.png","list-focus.png","", 1x, 2x, 3x, 4x, self.listspacing)

i thought i read someone posting about the documentation being wrong, but i can't find it. may not have been related.

edit: i think they correspond to the onleft, onright.... options, if anybodies interested.
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#2
afaik the controllist documentation is still accurate.
Quote:controllist(
x, y, width, height, font, textcolor,
buttontexture, buttonfocustexture,
selectedcolor, imagewidth, imageheight,
itemtextxoffset, itemtextyoffset,
itemheight, space, alignmenty )

x : integer x coordinate of control
y : integer y coordinate of control
width : integer width of control
height : integer height of control
font : font used for label text e.g. 'font13' (opt)
textcolor : color of item text e.g. '0xffffffff' (opt)
buttontexture : texture filename for item (opt)
buttonfocustexture : texture filename for focused item (opt)
selectedcolor : color of selected item text e.g. '0xffffffff' (opt)
imagewidth : integer width of item icon or thumbnail (opt)
imageheight : integer height of item icon or thumbnail (opt)
itemtextxoffset : integer x offset of item label (opt)
itemtextyoffset : integer y offset of item label (opt)
itemheight : integer height item (opt)
space : integer space between items (opt)
alignmenty : integer y-axis alignment - see xbfont.h (opt)
Reply
#3
thank you.  

where did you find this. i was looking in the html file in python_docs.rar and i didn't find it in the online manual.

edit: i found the link by you in another thread. same filename, just more information. thanks again.
For python coding questions first see http://mirrors.xbmc.org/docs/python-docs/
Reply
#4
hi !
i would like to know a bit more about alignmenty of controllist or is the way to control y offset of item label2 ?
and
why this xoffset makes nothing
Quote:self.list = xbmcgui.controllist(int(260*self.scalex), int(195*self.scaley), int(200*self.scalex), int(90*self.scaley),buttonfocustexture='button-focus.png',itemtextxoffset=10)
can anybody help me ?



Reply
#5
found the defaults at http://cvs.sourceforge.net/viewcvs....ew=auto

Quote:#define control_text_offset_x 10
#define control_text_offset_y 2

so i wouldnt expect an offset of 10 to be any different. i went into the guilistcontrol which passes the offset to a buttoncontrol which uses it in as an offset in drawtext function and it looks honored. try experimenting with different values.
Reply
#6
buttoncontrol works for me too

here example
Quote:import xbmcgui

def debug( str ):
   xbmc.output( str )

class window( xbmcgui.window ):
   def ( self ):
       xbmcgui.window.( self )
       self.checkmark = none

   def create( self ):
       self.ctl = xbmcgui.controllist( 160, 100, 400, 400,itemtextxoffset=50,itemtextyoffset=0,itemheight=110,space=10,alignmenty=1 )
       self.addcontrol( self.ctl )
       self.setfocus( self.ctl )
       labels = { 0: 'zero', 1: 'one', 2: 'two' }
       for k,v in labels.items():
           self.ctl.additem(
               xbmcgui.listitem(
                   label=str(k), label2=v,
                   thumbnailimage="q:\\scripts\\test.png" ) )

   def onaction( self, action ):
       debug( "> window.onaction( action=[%s] )"%action )
       if action in (9,10):
           self.close()
       debug( "< window.onaction( action=[%s] )"%action )

win = window()
win.create()
win.domodal()
del win

i try to make

label1 in top left with offset
label 2 in bottom right

is it possible?



Reply
#7
I need help. I have same Issue creating list of title with image description .
I want to list Title with respective image and description.
Can anyone suggest me how to implemented same feature ?
I am trying for this but problem is getting.

I want to create list as following image (Left side listing)

Image
Reply
#8
really, 9 year old thread?
Reply
#9
HFS!
Reply

Logout Mark Read Team Forum Stats Members Help
Controllist entries0