How to draw a dash line in the Tkinter?

Shi Mu samrobertsmith at gmail.com
Sun Nov 20 18:36:41 EST 2005


On 11/20/05, Fredrik Lundh <fredrik at pythonware.com> wrote:
> Ben Bush wrote:
>
> > How to draw a dash line in the Tkinter?
>
> use the dash option.  e.g.
>
>    canvas.create_line(xy, fill="red", dash=(2, 4))
>    canvas.create_line(xy, fill="red", dash=(6, 5, 2, 4))
>
> (the tuple contains a number of line lengths; lengths at odd positions
> are drawn, lengths at even positions are gaps.  note that not all com-
> binations are supported on all platforms; if Tkinter cannot find an exact
> match, it will pick a the "closest possible").
>
> </F>
where can I find the option settings for dash line?



More information about the Python-list mailing list