Using Tix and Tkinter

Discussion in 'Python' started by Harlin Seritt, Dec 31, 2004.

  1. I am trying to create a simple window using the following code:

    --code---

    import Tix
    from Tkconstants import *
    from Tkinter import *

    root = Tix.Tk()

    Label(root, text="Hello!").pack()
    Tix.tixControl().pack()

    root.mainloop()

    ---code---

    When I run this, I get the following error:

    Traceback (most recent call last):
    File "TixTest.py", line 8, in ?
    Tix.tixControl().pack()
    AttributeError: 'module' object has no attribute 'tixControl'

    Any reason why I am not able to pull up this widget to work with it?

    Thanks,

    Harlin Seritt
    Harlin Seritt, Dec 31, 2004
    #1
    1. Advertising

  2. On 31.12.2004, at 16:50, Harlin Seritt wrote:
    > import Tix
    > from Tkconstants import *
    > from Tkinter import *
    >
    > root = Tix.Tk()
    >
    > Label(root, text="Hello!").pack()
    > Tix.tixControl().pack()
    >
    > root.mainloop()


    > When I run this, I get the following error:
    >
    > Traceback (most recent call last):
    > File "TixTest.py", line 8, in ?
    > Tix.tixControl().pack()
    > AttributeError: 'module' object has no attribute 'tixControl'


    in the Tix module this widget is called Control. writing
    Tix.Control().pack()
    should work.

    - harold -

    --
    Man will occasionally stumble over the truth,
    but most of the time he will pick himself up and continue on.
    -- Winston Churchill
    harold fellermann, Jan 13, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Arne

    Documentation for Tkinter/Tix

    Arne, Apr 8, 2006, in forum: Python
    Replies:
    1
    Views:
    472
  2. CT
    Replies:
    1
    Views:
    294
    Christos Georgiou
    Apr 12, 2006
  3. Replies:
    0
    Views:
    283
  4. Replies:
    0
    Views:
    380
  5. excord80
    Replies:
    8
    Views:
    2,899
    Дамјан ГеоргиевÑки
    Jan 11, 2009
Loading...

Share This Page