mirror of https://github.com/python/cpython
Bug fixes in index&icursor suggested by Nils Fischbeck.
This commit is contained in:
parent
ee09fc1c30
commit
6b7a7e9fe0
|
@ -56,10 +56,10 @@ class CanvasItem:
|
||||||
self.canvas.focus(self.id)
|
self.canvas.focus(self.id)
|
||||||
def gettags(self):
|
def gettags(self):
|
||||||
return self.canvas.gettags(self.id)
|
return self.canvas.gettags(self.id)
|
||||||
def icursor(self):
|
def icursor(self, index):
|
||||||
self.canvas.icursor(self.id)
|
self.canvas.icursor(self.id, index)
|
||||||
def index(self):
|
def index(self, index):
|
||||||
return self.canvas.index(self.id)
|
return self.canvas.index(self.id, index)
|
||||||
def insert(self, beforethis, string):
|
def insert(self, beforethis, string):
|
||||||
self.canvas.insert(self.id, beforethis, string)
|
self.canvas.insert(self.id, beforethis, string)
|
||||||
def lower(self, belowthis=None):
|
def lower(self, belowthis=None):
|
||||||
|
@ -154,7 +154,7 @@ class Group:
|
||||||
def gettags(self):
|
def gettags(self):
|
||||||
return self.canvas.tk.splitlist(self._do('gettags', self.tag))
|
return self.canvas.tk.splitlist(self._do('gettags', self.tag))
|
||||||
def icursor(self, index):
|
def icursor(self, index):
|
||||||
return self._do('icursor')
|
return self._do('icursor', index)
|
||||||
def index(self, index):
|
def index(self, index):
|
||||||
return self.canvas.tk.getint(self._do('index', index))
|
return self.canvas.tk.getint(self._do('index', index))
|
||||||
def insert(self, beforeThis, string):
|
def insert(self, beforeThis, string):
|
||||||
|
|
|
@ -56,10 +56,10 @@ class CanvasItem:
|
||||||
self.canvas.focus(self.id)
|
self.canvas.focus(self.id)
|
||||||
def gettags(self):
|
def gettags(self):
|
||||||
return self.canvas.gettags(self.id)
|
return self.canvas.gettags(self.id)
|
||||||
def icursor(self):
|
def icursor(self, index):
|
||||||
self.canvas.icursor(self.id)
|
self.canvas.icursor(self.id, index)
|
||||||
def index(self):
|
def index(self, index):
|
||||||
return self.canvas.index(self.id)
|
return self.canvas.index(self.id, index)
|
||||||
def insert(self, beforethis, string):
|
def insert(self, beforethis, string):
|
||||||
self.canvas.insert(self.id, beforethis, string)
|
self.canvas.insert(self.id, beforethis, string)
|
||||||
def lower(self, belowthis=None):
|
def lower(self, belowthis=None):
|
||||||
|
@ -154,7 +154,7 @@ class Group:
|
||||||
def gettags(self):
|
def gettags(self):
|
||||||
return self.canvas.tk.splitlist(self._do('gettags', self.tag))
|
return self.canvas.tk.splitlist(self._do('gettags', self.tag))
|
||||||
def icursor(self, index):
|
def icursor(self, index):
|
||||||
return self._do('icursor')
|
return self._do('icursor', index)
|
||||||
def index(self, index):
|
def index(self, index):
|
||||||
return self.canvas.tk.getint(self._do('index', index))
|
return self.canvas.tk.getint(self._do('index', index))
|
||||||
def insert(self, beforeThis, string):
|
def insert(self, beforeThis, string):
|
||||||
|
|
Loading…
Reference in New Issue