mirror of
https://github.com/lalbornoz/roar.git
synced 2024-11-22 15:26:37 +00:00
libtools/Tool{,Circle,Fill,Line,Rect,Select,Text}.py: sync function signature comments.
This commit is contained in:
parent
8485ab568d
commit
9de3372a80
@ -5,7 +5,7 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
class Tool():
|
class Tool():
|
||||||
# {{{ onKeyboardEvent(self, brushColours, brushSize, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect)
|
# {{{ onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect)
|
||||||
def onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect):
|
def onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect):
|
||||||
return False, False
|
return False, False
|
||||||
# }}}
|
# }}}
|
||||||
|
@ -10,7 +10,7 @@ class ToolCircle(Tool):
|
|||||||
name = "Circle"
|
name = "Circle"
|
||||||
|
|
||||||
#
|
#
|
||||||
# onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
# onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
||||||
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
||||||
brushColours, dirty = brushColours.copy(), False
|
brushColours, dirty = brushColours.copy(), False
|
||||||
if mouseLeftDown:
|
if mouseLeftDown:
|
||||||
|
@ -10,7 +10,7 @@ class ToolFill(Tool):
|
|||||||
name = "Fill"
|
name = "Fill"
|
||||||
|
|
||||||
#
|
#
|
||||||
# onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
# onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
||||||
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
||||||
dirty, pointsDone, pointStack, testColour, = False, [], [list(mapPoint)], canvas.map[mapPoint[1]][mapPoint[0]][0:2]
|
dirty, pointsDone, pointStack, testColour, = False, [], [list(mapPoint)], canvas.map[mapPoint[1]][mapPoint[0]][0:2]
|
||||||
if mouseLeftDown or mouseRightDown:
|
if mouseLeftDown or mouseRightDown:
|
||||||
|
@ -51,7 +51,7 @@ class ToolLine(Tool):
|
|||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
#
|
#
|
||||||
# onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
# onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
||||||
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
||||||
brushColours, dirty = brushColours.copy(), False
|
brushColours, dirty = brushColours.copy(), False
|
||||||
if mouseLeftDown:
|
if mouseLeftDown:
|
||||||
|
@ -10,7 +10,7 @@ class ToolRect(Tool):
|
|||||||
name = "Rectangle"
|
name = "Rectangle"
|
||||||
|
|
||||||
#
|
#
|
||||||
# onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
# onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
||||||
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
||||||
brushColours, dirty = brushColours.copy(), False
|
brushColours, dirty = brushColours.copy(), False
|
||||||
if mouseLeftDown:
|
if mouseLeftDown:
|
||||||
|
@ -105,7 +105,7 @@ class ToolSelect(Tool):
|
|||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
#
|
#
|
||||||
# onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
# onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
||||||
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
||||||
dirty = False
|
dirty = False
|
||||||
if self.toolState == self.TS_NONE:
|
if self.toolState == self.TS_NONE:
|
||||||
|
@ -11,7 +11,7 @@ class ToolText(Tool):
|
|||||||
name = "Text"
|
name = "Text"
|
||||||
|
|
||||||
#
|
#
|
||||||
# onKeyboardEvent(self, brushColours, brushSize, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect)
|
# onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect)
|
||||||
def onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect):
|
def onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect):
|
||||||
if keyModifiers in (wx.MOD_NONE, wx.MOD_SHIFT):
|
if keyModifiers in (wx.MOD_NONE, wx.MOD_SHIFT):
|
||||||
rc, dirty = True, True
|
rc, dirty = True, True
|
||||||
@ -29,7 +29,7 @@ class ToolText(Tool):
|
|||||||
return rc, dirty
|
return rc, dirty
|
||||||
|
|
||||||
#
|
#
|
||||||
# onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
# onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
|
||||||
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
|
||||||
if mouseLeftDown or mouseRightDown:
|
if mouseLeftDown or mouseRightDown:
|
||||||
self.textPos = list(mapPoint)
|
self.textPos = list(mapPoint)
|
||||||
|
Loading…
Reference in New Issue
Block a user