def open(self, io=None): SearchDialogBase.open(self, None) if io: path = io.filename or "" else: path = "" dir, base = os.path.split(path) head, tail = os.path.splitext(base) if not tail: tail = ".py" self.globvar.set(os.path.join(dir, "*" + tail))
def open(self, text): SearchDialogBase.open(self, text) try: first = text.index("sel.first") except TclError: first = None try: last = text.index("sel.last") except TclError: last = None first = first or text.index("insert") last = last or first self.show_hit(first, last) self.ok = 1
from Tkinter import *
def create_command_buttons(self): SearchDialogBase.create_command_buttons(self) self.make_button("Search Files", self.default_command, 1)
import string
def __init__(self, root, engine): SearchDialogBase.__init__(self, root, engine) self.replvar = StringVar(root)
def close(self, event=None): SearchDialogBase.close(self, event) self.text.tag_remove("hit", "1.0", "end")
def create_command_buttons(self): SearchDialogBase.create_command_buttons(self)
def create_widgets(self): SearchDialogBase.create_widgets(self)
def create_entries(self): SearchDialogBase.create_entries(self) self.replent = self.make_entry("Replace with:", self.replvar)
def create_command_buttons(self): SearchDialogBase.create_command_buttons(self) self.make_button("Find", self.find_it) self.make_button("Replace", self.replace_it) self.make_button("Replace+Find", self.default_command, 1) self.make_button("Replace All", self.replace_all)
def __init__(self, root, engine, flist): SearchDialogBase.__init__(self, root, engine) self.flist = flist self.globvar = StringVar(root) self.recvar = BooleanVar(root)
def create_entries(self): SearchDialogBase.create_entries(self) self.globent = self.make_entry("In files:", self.globvar)
def create_widgets(self): SearchDialogBase.create_widgets(self) self.make_button("Find Next", self.default_command, 1)
def create_widgets(self): f = SearchDialogBase.create_widgets(self) self.make_button("Find", self.default_command, 1)