Re: Tkinter or Python issue?

2005-10-19 Thread Russell E. Owen
In article <[EMAIL PROTECTED]>, "Eric Brunel" <[EMAIL PROTECTED]> wrote: >You should now see why it works here: your first tkFont.Font is remembered at >Python level in a variable. So it is not discarded once the tag_config is >over. So the second tkFont.Font is not allocated at the same locati

Re: Tkinter or Python issue?

2005-10-19 Thread Fredrik Lundh
Eugene Druker wrote: > tkFont.Font(...) is a class instance, while you need font description. Font instances are font descriptors. >>> f = tkFont.Font(family="ariel", size=24, weight=tkFont.BOLD) >>> f >>> print f font10726496 > t.tag.config( 'TBU', font=('times', 12, 'bold

Re: Tkinter or Python issue?

2005-10-19 Thread Eric Brunel
On Tue, 18 Oct 2005 22:30:33 -0400, Ron Provost <[EMAIL PROTECTED]> wrote: > Hello, > > I'm using python 2.4.2 on Win XP Pro. I'm trying to understand a behavior > I'm seeing in some Tkinter code I have. I've reduced my question to a small > piece of code: > > > #BEGIN CODE > ###

Re: Tkinter or Python issue?

2005-10-18 Thread Eugene Druker
"Ron Provost" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > [snip] > t.insert( Tk.END, sampleText ) > > t.tag_config( 'AB', font=tkFont.Font( family='ariel', size=24, > weight=tkFont.BOLD ) ) > t.tag_config( 'TBU', font=tkFont.Font( family='times', size=10, > weight=tkFont.BOLD, un

Tkinter or Python issue?

2005-10-18 Thread Ron Provost
Hello, I'm using python 2.4.2 on Win XP Pro. I'm trying to understand a behavior I'm seeing in some Tkinter code I have. I've reduced my question to a small piece of code: #BEGIN CODE # import Tkinter as Tk import tkFont sampleText = """Here is a test string. This is mo