Tkinter - Text - bullets

eb303 eric.brunel at pragmadev.com
Tue Sep 22 14:23:49 CEST 2009


On Sep 22, 7:45 am, Thomas Lehmann <Iris-und-Thomas-Lehm... at T-
Online.de> wrote:
> > This is probably why you had all these alignment problems. But it's
> > weird, because the script I posted is copied and pasted from a really
> > script that I've run, and which doesn't cause any error. What is the
> > version of tcl/tk used by your Tkinter module? And what is your Python
> > version?
>
> Using python 2.5 (with Tcl/Tk 8.4):
>
> Traceback (most recent call last):
>   File "Text1.py", line 10, in <module>
>     txt.tag_configure('bulleted_list', font=('Times', 18),
> lmargin1='10m', lmargin2='15m', tabs=['15m'])
>   File "E:\Python25\lib\lib-tk\Tkinter.py", line 3066, in
> tag_configure
>     return self._configure(('tag', 'configure', tagName), cnf, kw)
>   File "E:\Python25\lib\lib-tk\Tkinter.py", line 1188, in _configure
>     self.tk.call(_flatten((self._w, cmd)) + self._options(cnf))
> _tkinter.TclError: bad screen distance "['15m']"

Try tabs='15m' instead. Seems the list is not handled properly.



More information about the Python-list mailing list