|
| 1 | +# MACROPAD Hotkeys example: Adobe Photoshop for Windows |
| 2 | + |
| 3 | +from adafruit_hid.keycode import Keycode # REQUIRED if using Keycode.* values |
| 4 | + |
| 5 | +app = { # REQUIRED dict, must be named 'app' |
| 6 | + 'name' : 'Photoshop', # Application name |
| 7 | + 'macros' : [ # List of button macros... |
| 8 | + # COLOR LABEL KEY SEQUENCE |
| 9 | + # 1st row ---------- |
| 10 | + (0x004000, 'Undo', [Keycode.CONTROL, 'z']), |
| 11 | + (0x004000, 'Redo', [Keycode.CONTROL, 'Z']), |
| 12 | + (0x000040, 'Brush', 'B'), # Cycle brush modes |
| 13 | + # 2nd row ---------- |
| 14 | + (0x101010, 'B&W', 'd'), # Default colors |
| 15 | + (0x101010, 'Marquee', 'M'), # Cycle rect/ellipse marquee (select) |
| 16 | + (0x000040, 'Eraser', 'E'), # Cycle eraser modes |
| 17 | + # 3rd row ---------- |
| 18 | + (0x101010, 'Swap', 'x'), # Swap foreground/background colors |
| 19 | + (0x101010, 'Move', 'v'), # Move layer |
| 20 | + (0x000040, 'Fill', 'G'), # Cycle fill/gradient modes |
| 21 | + # 4th row ---------- |
| 22 | + (0x101010, 'Eyedrop', 'I'), # Cycle eyedropper/measure modes |
| 23 | + (0x101010, 'Wand', 'W'), # Cycle "magic wand" (selection) modes |
| 24 | + (0x000040, 'Heal', 'J'), # Cycle "healing" modes |
| 25 | + # Encoder button --- |
| 26 | + (0x000000, '', [Keycode.CONTROL, Keycode.ALT, 'S']) # Save for web |
| 27 | + ] |
| 28 | +} |
0 commit comments