ttk Listbox

Kevin Walzer kw at codebykevin.com
Mon Oct 31 20:00:13 EDT 2011


On 10/31/11 4:03 PM, Ric at rdo wrote:
> On 2011年10月31日 10:00:22 -0400, Kevin Walzer<kw at codebykevin.com>
> wrote:
>>> On 10/31/11 12:37 AM, Ric at rdo wrote:
>>>>>> What would be an equivalent widget in ttk like a Listbox and if
>>> possible a small example? I tried to look here
>>> http://docs.python.org/library/ttk.html but did not see anything.
>>>>>> Maybe I did not look in the right place?
>>>>>> tia
>>>> The listbox isn't part of the themed ttk widgets. The ttk::treview is,
>> and that can be set up as a single-column list display. There may be an
>> example of how to do this in the docs or source code tree (I don't use
>> the widget myself so I don't have any sample code to share).
>>>> --Kevin
>> Quick question:
>> Then why is it mentioned here
> http://www.tkdocs.com/tutorial/morewidgets.html?
>> Listboxes are created using the Listbox function:
>> l = Listbox(parent, height=10)

The listbox is a Tk widget, not a ttk widget. It's one of the original 
Tk/Tkinter widgets, and has no themed equivalent.
-- 
Kevin Walzer
Code by Kevin
http://www.codebykevin.com


More information about the Python-list mailing list

AltStyle によって変換されたページ (->オリジナル) /