(Canvas.py): Added definition of CanvasItem.cget() as suggested by
Nils Fischbeck.
This commit is contained in:
parent
a1560cfb29
commit
e9c515adc7
|
@ -22,6 +22,7 @@ class CanvasItem:
|
|||
self.canvas._w, 'itemconfigure',
|
||||
self.id, '-' + key))
|
||||
return v[4]
|
||||
cget = __getitem__
|
||||
def __setitem__(self, key, value):
|
||||
self.canvas.itemconfig(self.id, {key: value})
|
||||
def keys(self):
|
||||
|
|
|
@ -22,6 +22,7 @@ class CanvasItem:
|
|||
self.canvas._w, 'itemconfigure',
|
||||
self.id, '-' + key))
|
||||
return v[4]
|
||||
cget = __getitem__
|
||||
def __setitem__(self, key, value):
|
||||
self.canvas.itemconfig(self.id, {key: value})
|
||||
def keys(self):
|
||||
|
|
Loading…
Reference in New Issue