File Manager in Tkinter
Jeff Hobbs
jeff.hobbs at gmail.com
Tue Aug 10 12:20:31 EDT 2010
On Aug 9, 9:53 pm, John wrote:
> As a learning exercise in Tkinter I htought about making a very simple
> and basic file manager for my own use. I tried searching google for
> any sample project and could not find anything. Not exactly sure how
> to start I tought I could ask here?
>
> I thought about making two listboxes one to list folders only the
> other files inside. I tried to make one listbox first but did not know
> how to list folders only.
Filter with os.path.isdir()
> Is there a way to list folders with images?
> Any suggestions or help how to proced would be appreciated.
If you are using a Tkinter with Ttk (Tk 8.5), then use the treeview
widget:
http://docs.activestate.com/activepython/3.1/python/library/tkinter.ttk.html
For more advanced needs, there is a Tk extension called tktreectrl
that does some very cool views and has lots of controls:
http://tktreectrl.sourceforge.net/
Jeff
More information about the Python-list
mailing list