MCPcopy Index your code
hub / github.com/python/cpython / edit

Method edit

Lib/curses/textpad.py:180–191  ·  view source on GitHub ↗

Edit in the widget window and collect the results.

(self, validate=None)

Source from the content-addressed store, hash-verified

178 return result
179
180 def edit(self, validate=None):
181 "Edit in the widget window and collect the results."
182 while 1:
183 ch = self.win.getch()
184 if validate:
185 ch = validate(ch)
186 if not ch:
187 continue
188 if not self.do_command(ch):
189 break
190 self.win.refresh()
191 return self.gather()
192
193if __name__ == '__main__':
194 def test_editbox(stdscr):

Callers 2

test_textpadFunction · 0.95
test_editboxFunction · 0.45

Calls 3

do_commandMethod · 0.95
gatherMethod · 0.95
refreshMethod · 0.45

Tested by 2

test_textpadFunction · 0.76
test_editboxFunction · 0.36