Notebook widget in Tkinter

前端 未结 5 1659
孤独总比滥情好
孤独总比滥情好 2020-12-13 20:56

Having played around a little with both Tkinter and wxPython, I like Tkinter much better in terms of how clean my source code looks. However, it doesn\'t seem to have as ma

5条回答
  •  独厮守ぢ
    2020-12-13 21:34

    While it may not help you at the moment, tk 8.5 comes with an extended set of widgets. This extended set is available with tk 8.4 by way of an extension known as "tile". Included in the extended set of widgets is a notebook widget. Unfortunately, at this time Tkinter by default uses a fairly old version of Tk that doesn't come with these widgets.

    There have been efforts to make tile available to Tkinter. Check out http://tkinter.unpythonic.net/wiki/TileWrapper. For another similar effort see http://pypi.python.org/pypi/pyttk. Also, for a taste of how these widgets look (in Ruby, Perl and Tcl) see http://www.tkdocs.com/.

    Tk 8.5 is a huge improvement over stock Tk. It introduces several new widgets, native widgets, and a theming engine. Hopefully it will be available by default in Tkinter some day soon. Too bad the Python world is lagging behind other languages.

    update: The latest versions of Python now include support for the themed widgets out of the box. _

提交回复
热议问题