Primer commit
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
from __future__ import absolute_import
|
||||
from future.utils import PY3
|
||||
__future_module__ = True
|
||||
|
||||
if not PY3:
|
||||
from Tkinter import *
|
||||
from Tkinter import (_cnfmerge, _default_root, _flatten,
|
||||
_support_default_root, _test,
|
||||
_tkinter, _setit)
|
||||
|
||||
try: # >= 2.7.4
|
||||
from Tkinter import (_join)
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
try: # >= 2.7.4
|
||||
from Tkinter import (_stringify)
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
try: # >= 2.7.9
|
||||
from Tkinter import (_splitdict)
|
||||
except ImportError:
|
||||
pass
|
||||
|
||||
else:
|
||||
from tkinter import *
|
||||
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.colorchooser import *
|
||||
else:
|
||||
try:
|
||||
from tkColorChooser import *
|
||||
except ImportError:
|
||||
raise ImportError('The tkColorChooser module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.commondialog import *
|
||||
else:
|
||||
try:
|
||||
from tkCommonDialog import *
|
||||
except ImportError:
|
||||
raise ImportError('The tkCommonDialog module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.constants import *
|
||||
else:
|
||||
try:
|
||||
from Tkconstants import *
|
||||
except ImportError:
|
||||
raise ImportError('The Tkconstants module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.dialog import *
|
||||
else:
|
||||
try:
|
||||
from Dialog import *
|
||||
except ImportError:
|
||||
raise ImportError('The Dialog module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.dnd import *
|
||||
else:
|
||||
try:
|
||||
from Tkdnd import *
|
||||
except ImportError:
|
||||
raise ImportError('The Tkdnd module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,18 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.filedialog import *
|
||||
else:
|
||||
try:
|
||||
from FileDialog import *
|
||||
except ImportError:
|
||||
raise ImportError('The FileDialog module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
|
||||
try:
|
||||
from tkFileDialog import *
|
||||
except ImportError:
|
||||
raise ImportError('The tkFileDialog module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.font import *
|
||||
else:
|
||||
try:
|
||||
from tkFont import *
|
||||
except ImportError:
|
||||
raise ImportError('The tkFont module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.messagebox import *
|
||||
else:
|
||||
try:
|
||||
from tkMessageBox import *
|
||||
except ImportError:
|
||||
raise ImportError('The tkMessageBox module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.scrolledtext import *
|
||||
else:
|
||||
try:
|
||||
from ScrolledText import *
|
||||
except ImportError:
|
||||
raise ImportError('The ScrolledText module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.simpledialog import *
|
||||
else:
|
||||
try:
|
||||
from SimpleDialog import *
|
||||
except ImportError:
|
||||
raise ImportError('The SimpleDialog module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.tix import *
|
||||
else:
|
||||
try:
|
||||
from Tix import *
|
||||
except ImportError:
|
||||
raise ImportError('The Tix module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
@@ -0,0 +1,12 @@
|
||||
from __future__ import absolute_import
|
||||
|
||||
from future.utils import PY3
|
||||
|
||||
if PY3:
|
||||
from tkinter.ttk import *
|
||||
else:
|
||||
try:
|
||||
from ttk import *
|
||||
except ImportError:
|
||||
raise ImportError('The ttk module is missing. Does your Py2 '
|
||||
'installation include tkinter?')
|
||||
Reference in New Issue
Block a user