mirror of
https://github.com/lalbornoz/roar.git
synced 2024-11-02 13:56:39 +00:00
0c66f94797
1) {About,Melp?} window: switch to green on black. 2) Assets window: scroll assets list on selected item update w/ <Cursor> or on deletion. 3) Canvas window: change default brush colours to [3, -1]. 4) Canvas window: copy canvas cells given transparent cells from tools. 5) Canvas window: don't disable {re,un}do during object tool usage. 6) Canvas window: don't hide cursor during {re,un}do. 7) Canvas window: draw new cells using current brush background colour on resize. 8) Canvas window: fix memory leak on cell size updating. 9) Text tool: process [\r\n] in text pasted from clipboard. assets/audio/roar{vap0r[1-8],viking[1-5]}.wav: added. assets/text/README.txt: updated. assets/tools/AnsiToMiRCART.py: added (for spoke.) assets/tools/deploy-python.sh: updated.
33 lines
1.5 KiB
Python
33 lines
1.5 KiB
Python
#!/usr/bin/env python3
|
|
#
|
|
# RoarCanvasCommandsOperators.py
|
|
# Copyright (c) 2018, 2019 Lucio Andrés Illanes Albornoz <lucio@lucioillanes.de>
|
|
#
|
|
|
|
from GuiFrame import GuiCommandListDecorator
|
|
from OperatorFlipHorizontal import OperatorFlipHorizontal
|
|
from OperatorFlipVertical import OperatorFlipVertical
|
|
from OperatorInvert import OperatorInvert
|
|
from OperatorRotate import OperatorRotate
|
|
from OperatorTile import OperatorTile
|
|
from ToolObject import ToolObject
|
|
|
|
class RoarCanvasCommandsOperators():
|
|
@GuiCommandListDecorator(0, "Flip", "&Flip", None, None, None)
|
|
@GuiCommandListDecorator(1, "Flip horizontally", "Flip &horizontally", None, None, None)
|
|
@GuiCommandListDecorator(2, "Invert colours", "&Invert colours", None, None, None)
|
|
@GuiCommandListDecorator(3, "Rotate", "&Rotate", None, None, None)
|
|
@GuiCommandListDecorator(4, "Tile", "&Tile", None, None, False)
|
|
def canvasOperator(self, f, idx):
|
|
def canvasOperator_(event):
|
|
self.currentOperator = [OperatorFlipVertical, OperatorFlipHorizontal, OperatorInvert, OperatorRotate, OperatorTile][idx]()
|
|
self.operatorState = None
|
|
self.parentCanvas.applyOperator(self.currentTool, self.parentCanvas.brushPos, None, False, self.currentOperator, self.parentCanvas.GetViewStart())
|
|
setattr(canvasOperator_, "attrDict", f.attrList[idx])
|
|
return canvasOperator_
|
|
|
|
def __init__(self):
|
|
self.currentOperator, self.operatorState = None, None
|
|
|
|
# vim:expandtab foldmethod=marker sw=4 ts=4 tw=0
|