Loading Tkinter in Python for Rhino 8

Is tkinter not supported in Rhino’s script editor? I’ve tried installing with # r: tkinter as well as with pip but neither are working. I have been able to install matplotlib just fine.

I tested this on the newest Rhino 8.6:

#! python3

import rhinoscriptsyntax as rs
import scriptcontext as sc
import math

import System
import System.Collections.Generic
import Rhino

import tkinter


Worked fine.


What error is happening on the computer?

Go to the Tools pulldown > Open Logger and send the results may help.

Also, Rhino does come with ETO built in that can also be used:

1 Like

I just get a traceback error to line 36 saying No module named ‘tkinter’ (see image below)

I was able to get it installed in my default python library so I can run the test dialog fine from the terminal, but it isn’t wanting to install in rhinocode. when I try installing via pip in the rhinocode directory, I get this error:

ERROR: Could not find a version that satisfies the requirement tkinter (from versions: none)
ERROR: No matching distribution found for tkinter

I’m on 8.5, but it says it’s up to date when I run a check.

I was hoping to get tkinter working instead of Eto because I wanted to explore tkintermapview (which incidentally installed fine)


Yes, please send us the full Log. We will take a look.

Also, we have made a lot of updates in 8.6, here is a downloader for windows that will update Rhino 8:

1 Like

There’s a youtrack issue by @eirannejad re implementing tkinter: https://mcneel.myjetbrains.com/youtrack/issue/RH-67505

Looks like it worked on Windows, but not on Mac.

1 Like

Yes the update worked for me. Thanks!

1 Like