mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-28 06:05:58 -04:00
Use six to import Tkinter modules in openmc-plot-mesh-tally
This commit is contained in:
parent
5a126d086e
commit
fdc22a3d70
1 changed files with 5 additions and 13 deletions
|
|
@ -5,6 +5,11 @@
|
|||
import os
|
||||
import sys
|
||||
|
||||
import six.moves.tkinter as tk
|
||||
import six.moves.tkinter_filedialog as filedialog
|
||||
import six.moves.tkinter_font as font
|
||||
import six.moves.tkinter_messagebox as messagebox
|
||||
import six.moves.tkinter_ttk as ttk
|
||||
from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg
|
||||
from matplotlib.backends.backend_tkagg import NavigationToolbar2TkAgg
|
||||
from matplotlib.figure import Figure
|
||||
|
|
@ -13,19 +18,6 @@ import numpy as np
|
|||
|
||||
from openmc.statepoint import StatePoint
|
||||
|
||||
if sys.version_info[0] < 3:
|
||||
import Tkinter as tk
|
||||
import tkFileDialog as filedialog
|
||||
import tkFont as font
|
||||
import tkMessageBox as messagebox
|
||||
import ttk as ttk
|
||||
else:
|
||||
import tkinter as tk
|
||||
import tkinter.filedialog as filedialog
|
||||
import tkinter.font as font
|
||||
import tkinter.messagebox as messagebox
|
||||
import tkinter.ttk as ttk
|
||||
|
||||
|
||||
class MeshPlotter(tk.Frame):
|
||||
def __init__(self, parent, filename):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue