PATH: //proc/self/root/opt/alt/python36/lib64/python3.6/idlelib
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 CREDITS.txt
↓
X
📄 ChangeLog
↓
X
📄 HISTORY.txt
↓
X
📁 Icons/
X
📄 NEWS.txt
↓
X
📄 NEWS2x.txt
↓
X
📄 README.txt
↓
X
📄 TODO.txt
↓
X
📄 __init__.py
↓
X
📄 __main__.py
↓
X
📁 __pycache__/
X
📄 _pyclbr.py
↓
X
📄 autocomplete.py
↓
X
📄 autocomplete_w.py
↓
X
📄 autoexpand.py
↓
X
📄 browser.py
↓
X
📄 calltip.py
↓
X
📄 calltip_w.py
↓
X
📄 codecontext.py
↓
X
📄 colorizer.py
↓
X
📄 config-extensions.def
↓
X
📄 config-highlight.def
↓
X
📄 config-keys.def
↓
X
📄 config-main.def
↓
X
📄 config.py
↓
X
📄 config_key.py
↓
X
📄 configdialog.py
↓
X
📄 debugger.py
↓
X
📄 debugger_r.py
↓
X
📄 debugobj.py
↓
X
📄 debugobj_r.py
↓
X
📄 delegator.py
↓
X
📄 dynoption.py
↓
X
📄 editor.py
↓
X
📄 extend.txt
↓
X
📄 filelist.py
↓
X
📄 grep.py
↓
X
📄 help.html
↓
X
📄 help.py
↓
X
📄 help_about.py
↓
X
📄 history.py
↓
X
📄 hyperparser.py
↓
X
📄 idle.py
↓
X
📄 idle.pyw
↓
X
📁 idle_test/
X
📄 iomenu.py
↓
X
📄 macosx.py
↓
X
📄 mainmenu.py
↓
X
📄 multicall.py
↓
X
📄 outwin.py
↓
X
📄 paragraph.py
↓
X
📄 parenmatch.py
↓
X
📄 pathbrowser.py
↓
X
📄 percolator.py
↓
X
📄 pyparse.py
↓
X
📄 pyshell.py
↓
X
📄 query.py
↓
X
📄 redirector.py
↓
X
📄 replace.py
↓
X
📄 rpc.py
↓
X
📄 rstrip.py
↓
X
📄 run.py
↓
X
📄 runscript.py
↓
X
📄 scrolledlist.py
↓
X
📄 search.py
↓
X
📄 searchbase.py
↓
X
📄 searchengine.py
↓
X
📄 squeezer.py
↓
X
📄 stackviewer.py
↓
X
📄 statusbar.py
↓
X
📄 textview.py
↓
X
📄 tooltip.py
↓
X
📄 tree.py
↓
X
📄 undo.py
↓
X
📄 window.py
↓
X
📄 zoomheight.py
↓
X
📄 zzdummy.py
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: filelist.py
"idlelib.filelist" import os from tkinter import messagebox as tkMessageBox class FileList: # N.B. this import overridden in PyShellFileList. from idlelib.editor import EditorWindow def __init__(self, root): self.root = root self.dict = {} self.inversedict = {} self.vars = {} # For EditorWindow.getrawvar (shared Tcl variables) def open(self, filename, action=None): assert filename filename = self.canonize(filename) if os.path.isdir(filename): # This can happen when bad filename is passed on command line: tkMessageBox.showerror( "File Error", "%r is a directory." % (filename,), master=self.root) return None key = os.path.normcase(filename) if key in self.dict: edit = self.dict[key] edit.top.wakeup() return edit if action: # Don't create window, perform 'action', e.g. open in same window return action(filename) else: edit = self.EditorWindow(self, filename, key) if edit.good_load: return edit else: edit._close() return None def gotofileline(self, filename, lineno=None): edit = self.open(filename) if edit is not None and lineno is not None: edit.gotoline(lineno) def new(self, filename=None): return self.EditorWindow(self, filename) def close_all_callback(self, *args, **kwds): for edit in list(self.inversedict): reply = edit.close() if reply == "cancel": break return "break" def unregister_maybe_terminate(self, edit): try: key = self.inversedict[edit] except KeyError: print("Don't know this EditorWindow object. (close)") return if key: del self.dict[key] del self.inversedict[edit] if not self.inversedict: self.root.quit() def filename_changed_edit(self, edit): edit.saved_change_hook() try: key = self.inversedict[edit] except KeyError: print("Don't know this EditorWindow object. (rename)") return filename = edit.io.filename if not filename: if key: del self.dict[key] self.inversedict[edit] = None return filename = self.canonize(filename) newkey = os.path.normcase(filename) if newkey == key: return if newkey in self.dict: conflict = self.dict[newkey] self.inversedict[conflict] = None tkMessageBox.showerror( "Name Conflict", "You now have multiple edit windows open for %r" % (filename,), master=self.root) self.dict[newkey] = edit self.inversedict[edit] = newkey if key: try: del self.dict[key] except KeyError: pass def canonize(self, filename): if not os.path.isabs(filename): try: pwd = os.getcwd() except OSError: pass else: filename = os.path.join(pwd, filename) return os.path.normpath(filename) def _test(): # TODO check and convert to htest from tkinter import Tk from idlelib.editor import fixwordbreaks from idlelib.run import fix_scaling root = Tk() fix_scaling(root) fixwordbreaks(root) root.withdraw() flist = FileList(root) flist.new() if flist.inversedict: root.mainloop() if __name__ == '__main__': from unittest import main main('idlelib.idle_test.test_filelist', verbosity=2) # _test()
SIMPAN PERUBAHAN