1717import idlever
1818import WindowList
1919from IdleConf import idleconf
20- import aboutDialog
20+ import aboutDialog , textView
2121
2222# The default tab setting for a Text widget, in average-width characters.
2323TK_TABWIDTH_DEFAULT = 8
7878#$ event <<do-nothing>>
7979#$ unix <Control-x>
8080
81-
82- about_title = "About IDLEfork"
83- about_text = """\
84- IDLEfork %s
85-
86- IDLE is an Integrated DeveLopment Environment for Python \
87- by Guido van Rossum.
88-
89- IDLEfork is an official experimental development version of IDLE. \
90- Succesful new features in IDLEfork will be mereged back in to stable IDLE.
91-
92- This version of IDLEfork is based on the work in stable IDLE version 0.8, \
93- IDLE fork 0.7.1 released by David Scherer, and the VPython idle fork.
94-
95- See README.txt and NEWS.txt for more details on this verion of IDLEfork.
96-
97- WARNING: IDLEfork is at this stage alpha quality software, expect things \
98- to be broken.
99-
100- """ % (idlever .IDLE_VERSION )
101-
10281class EditorWindow :
10382
10483 from Percolator import Percolator
@@ -109,9 +88,6 @@ class EditorWindow:
10988 from Tkinter import Toplevel
11089 from MultiStatusBar import MultiStatusBar
11190
112- about_title = about_title
113- about_text = about_text
114-
11591 vars = {}
11692
11793 def __init__ (self , flist = None , filename = None , key = None , root = None ):
@@ -297,25 +273,15 @@ def command(text=self.text, eventname=eventname):
297273 self .rmenu = rmenu
298274
299275 def about_dialog (self , event = None ):
300- #tkMessageBox.showinfo(self.about_title, self.about_text,
301- # master=self.text)
302276 aboutDialog .AboutDialog (self .top ,'About IDLEfork' )
303277
304- helpfile = "help.txt"
305-
306278 def good_advice (self , event = None ):
307279 tkMessageBox .showinfo ('Advice' , "Don't Panic!" , master = self .text )
308280
309281 def help_dialog (self , event = None ):
310- try :
311- helpfile = os .path .join (os .path .dirname (__file__ ), self .helpfile )
312- except NameError :
313- helpfile = self .helpfile
314- if self .flist :
315- self .flist .open (helpfile )
316- else :
317- self .io .loadfile (helpfile )
318-
282+ fn = os .path .join (os .path .abspath (os .path .dirname (__file__ )),'help.txt' )
283+ textView .TextViewer (self .top ,'Help' ,fn )
284+
319285 help_url = "http://www.python.org/doc/current/"
320286 if sys .platform [:3 ] == "win" :
321287 fn = os .path .dirname (__file__ )
0 commit comments