[Tkinter-discuss] OptionMenu text justification

Michael Lange klappnase at web.de
Fri May 28 12:56:50 CEST 2010

Hi Gary,

On Thu, 27 May 2010 15:33:59 -0700
Gary Scorby <Gary.Scorby at harlandfs.com> wrote:

> I'm new to Tkinter.  I need a drop down box to display a selection
> list to an end user.  It appears the best option for this is
> "OptionMenu" (If not, please suggest other options).  I have it
> working like we want except for one thing, after selecting something
> from the list and closing the list, the text is centered in the
> window.  We have some very long lines of text to choose from.  When
> the choice is made we would like the chosen text to be left justified
> in the window.  I've tried ever option I can find, but the text
> remains centered.  Any assistance will be appreciated.

I admit, I am not sure what exactly you want to achieve. Does

    your_option_menu.configure(wraplength=150, justify='left')

do what you want?

I hope this helps


More information about the Tkinter-discuss mailing list