How to pip or easy_install tkinter on Windows

前端 未结 12 783
你的背包
你的背包 2020-11-28 22:31

My Idle is throwing errors that and says tkinter can\'t be imported.

Is there a simple way to install tkinter via pip or

12条回答
  •  一向
    一向 (楼主)
    2020-11-28 23:02

    I'm posting as the top answer requotes the documentation which I didn't find useful.

    tkinter comes packaged with python install on windows IFF you select it during the install window.

    The solution is to repair the installation (via uninstall GUI is fine), and select to install tk this time. You may need to point at or redownload the binary in this process. Downloading directly from activestate did not work for me.

    This is a common problem people have on windows as it's easy to not want to install TCL/TK if you don't know what it is, but Matplotlib etc require it.

提交回复
热议问题