mirror of
https://github.com/python/cpython.git
synced 2025-08-22 09:45:06 +00:00
bpo-37903: IDLE: Shell sidebar with prompts (GH-22682)
The first followup will change shell indents to spaces. More are expected. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
This commit is contained in:
parent
103d5e420d
commit
15d3861856
14 changed files with 888 additions and 132 deletions
|
@ -38,6 +38,21 @@ class Percolator:
|
|||
filter.setdelegate(self.top)
|
||||
self.top = filter
|
||||
|
||||
def insertfilterafter(self, filter, after):
|
||||
assert isinstance(filter, Delegator)
|
||||
assert isinstance(after, Delegator)
|
||||
assert filter.delegate is None
|
||||
|
||||
f = self.top
|
||||
f.resetcache()
|
||||
while f is not after:
|
||||
assert f is not self.bottom
|
||||
f = f.delegate
|
||||
f.resetcache()
|
||||
|
||||
filter.setdelegate(f.delegate)
|
||||
f.setdelegate(filter)
|
||||
|
||||
def removefilter(self, filter):
|
||||
# XXX Perhaps should only support popfilter()?
|
||||
assert isinstance(filter, Delegator)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue