roar/libtools/Tool.py
Lucio Andrés Illanes Albornoz fb274c0d66 libroar/RoarCanvas{CommandsTools,Window}.py: explicitly pass canvas.
libtools/Tool{,Circle,Fill,Line,Rect,Select,Text}.py: explicitly receive canvas.
2019-09-10 12:12:12 +02:00

18 lines
800 B
Python

#!/usr/bin/env python3
#
# Tool.py
# Copyright (c) 2018, 2019 Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de>
#
class Tool():
# {{{ onKeyboardEvent(self, brushColours, brushSize, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect)
def onKeyboardEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, keyChar, keyModifiers, mapPoint, viewRect):
return False, False
# }}}
# {{{ onMouseEvent(self, brushColours, brushSize, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect)
def onMouseEvent(self, brushColours, brushSize, canvas, dispatchFn, eventDc, mapPoint, mouseDragging, mouseLeftDown, mouseRightDown, viewRect):
return False, False
# }}}
# vim:expandtab foldmethod=marker sw=4 ts=4 tw=120