I have code using tkinter which I can run from IDLE just fine, but which throws the exception AttributeError: 'module' object has no attribute 'font'
when it is run from the command line. Other tkinter programs work fine, but anything using the tkinter package's font.py gives me this error.
I've checked my python files and c:/Python34/Lib/tkinter/font.py is there. I am not sure why, from the command line, it thinks font is an attribute and not a module of the tkinter package.
Example code:
import tkinter as tk
from tkinter import ttk
root = tk.Tk()
test_font = tk.font.Font(size=12,weight='bold')
root.mainloop()