Re: Retrieve Tkinter listbox item by string, not by index

2006-12-23 Thread Godson
On 12/23/06, Kevin Walzer <[EMAIL PROTECTED]> wrote: I'm trying to set the active item in a Tkinter listbox to my application's currently-defined default font. Here's how I get the fonts loaded into the listbox: self.fonts=list(tkFont.families()) self.fonts.sort() for item in self.font

Re: Retrieve Tkinter listbox item by string, not by index

2006-12-22 Thread Hendrik van Rooyen
"Kevin Walzer" <[EMAIL PROTECTED]> wrote: > I'm trying to set the active item in a Tkinter listbox to my > application's currently-defined default font. not sure if you can mix fonts in a listbox - the font option when you create the listbox instance seems to apply globally to all the lines in

Re: Retrieve Tkinter listbox item by string, not by index

2006-12-22 Thread James Stroud
James Stroud wrote: > Kevin Walzer wrote: > >> I'm trying to set the active item in a Tkinter listbox to my >> application's currently-defined default font. >> >> Here's how I get the fonts loaded into the listbox: >> >> self.fonts=list(tkFont.families()) >> self.fonts.sort() >> >> for item i

Re: Retrieve Tkinter listbox item by string, not by index

2006-12-22 Thread James Stroud
Kevin Walzer wrote: > I'm trying to set the active item in a Tkinter listbox to my > application's currently-defined default font. > > Here's how I get the fonts loaded into the listbox: > > self.fonts=list(tkFont.families()) > self.fonts.sort() > > for item in self.fonts: > sel

Retrieve Tkinter listbox item by string, not by index

2006-12-22 Thread Kevin Walzer
I'm trying to set the active item in a Tkinter listbox to my application's currently-defined default font. Here's how I get the fonts loaded into the listbox: self.fonts=list(tkFont.families()) self.fonts.sort() for item in self.fonts: self.fontlist.insert(END, item) #self