Tim Edwards | 55f4d0e | 2020-07-05 15:41:02 -0400 | [diff] [blame] | 1 | # |
| 2 | # Cadence-compatibility bindings except where marked. |
| 3 | # |
| 4 | macro f "view" ;# zoom to fit window |
| 5 | macro ^z "zoom 0.5" ;# zoom in |
| 6 | macro Z "zoom 2" ;# zoom out |
| 7 | macro B "popstack" ;# up hierarchy |
| 8 | macro X {pushstack [cellname list self]} ;# down hierarchy |
| 9 | macro x "edit" ;# down hierarchy, edit-in-place |
| 10 | macro b "select top cell ; edit" ;# up hierarchy from edit-in-place |
| 11 | macro p "tool wire; magic::trackwire %W pick" ;# path |
| 12 | macro ^r "redraw" |
| 13 | macro ^f "unexpand" |
| 14 | macro F "expand" |
| 15 | macro ^a "select area" |
| 16 | macro ^d "select clear" |
| 17 | macro k "magic::measure" |
| 18 | macro K "magic::unmeasure" |
| 19 | macro i "magic::promptload getcell" |
| 20 | macro l "magic::update_texthelper ; wm deiconify .texthelper ; raise .texthelper" |
| 21 | macro O "magic::clock" |
| 22 | macro <del> "magic::delete" |
| 23 | |
| 24 | # Toolkit parameter dialog |
| 25 | macro q "magic::gencell {} ; raise .params" |
| 26 | # |
| 27 | # The following should be already implemented as existing Magic bindings |
| 28 | # |
| 29 | macro u "undo" |
| 30 | macro U "redo" |
| 31 | macro m "move" |
| 32 | macro c "copy" |
| 33 | # |
| 34 | # Compatibility with Electric; Cadence bindings are on function keys and |
| 35 | # do not work through the VNC. |
| 36 | macro ^s "magic::promptsave magic" ;# save dialog menu |
| 37 | |
| 38 | # |
| 39 | # Bertrand's bindings follow except where marked. |
| 40 | # |
| 41 | macro < sideways |
| 42 | macro ^ upsidedown |
| 43 | # |
| 44 | # Set grid at 1 micron |
| 45 | # |
| 46 | macro 0 "grid on ; grid 1l" ;# Grid at 0.5um (1 lambda) |
| 47 | # macro ^f "feedback clear" ;# conflicts with Cadence binding |
| 48 | # |
| 49 | # Paint/Erase macros |
| 50 | # |
| 51 | macro 1 "paint m1" |
| 52 | macro ! "erase m1" |
| 53 | macro 2 "paint m2" |
| 54 | macro @ "erase m2" |
| 55 | macro 3 "paint m3" |
| 56 | macro # "erase m3" |
| 57 | #ifdef METAL4 |
| 58 | macro 4 "paint mtp" |
| 59 | macro $ "erase mtp" |
| 60 | #endif |
| 61 | #ifdef METAL5 |
| 62 | macro 4 "paint m4" |
| 63 | macro $ "erase m4" |
| 64 | macro 5 "paint mtp" |
| 65 | macro % "erase mtp" |
| 66 | #endif |
| 67 | #ifdef METAL6 |
| 68 | macro 4 "paint m4" |
| 69 | macro $ "erase m4" |
| 70 | macro 5 "paint m5" |
| 71 | macro % "erase m5" |
| 72 | macro 6 "paint mtp" |
| 73 | macro ^ "erase mtp" |
| 74 | #endif |
| 75 | |
| 76 | macro 7 "paint poly" |
| 77 | # macro & "erase poly" |
| 78 | # macro p "paint pdiff" |
| 79 | macro n "paint ndiff" |
| 80 | # macro l "erase labels" |
| 81 | macro P "erase pdiff" |
| 82 | macro N "erase ndiff" |
| 83 | macro y "drc check; drc why" |
| 84 | macro ? "select area; what" |
| 85 | |
| 86 | macro / "expand toggle" |
| 87 | macro ^w "writeall force" |
| 88 | macro ^e "edit" |
| 89 | # macro ^x "quit" |
| 90 | |
| 91 | macro z "findbox zoom" |
| 92 | # "f" conflicts with Cadence "full view", so use control-i to select cells. |
| 93 | # macro f "select cell" |
| 94 | macro ^i "select cell" |
| 95 | |
| 96 | # Leave keypad bindings as-is, further down. However, keypad |
| 97 | # keys generally don't translate through the VNC session, so |
| 98 | # use the following arrow key bindings: |
| 99 | # |
| 100 | # no shift shift |
| 101 | # arrows only -> Pan 10% 100% |
| 102 | # with alt -> Move 1 lambda 1 grid |
| 103 | # with ctrl -> Stretch 1 lambda 1 grid |
| 104 | # |
| 105 | # Pan 10 percent of the window size with arrows |
| 106 | # macro XK_Left "scroll l .1 w" |
| 107 | # macro XK_Up "scroll u .1 w" |
| 108 | # macro XK_Right "scroll r .1 w" |
| 109 | # macro XK_Down "scroll d .1 w" |
| 110 | |
| 111 | # Pan 100 percent of the window size with arrows |
| 112 | # macro Shift_XK_Left "scroll l 1 w" |
| 113 | # macro Shift_XK_Up "scroll u 1 w" |
| 114 | # macro Shift_XK_Right "scroll r 1 w" |
| 115 | # macro Shift_XK_Down "scroll d 1 w" |
| 116 | |
| 117 | # move 0.05um with arrows |
| 118 | # macro Alt_XK_Left "move l 1l" |
| 119 | # macro Alt_XK_Right "move r 1l" |
| 120 | # macro Alt_XK_Up "move u 1l" |
| 121 | # macro Alt_XK_Down "move d 1l" |
| 122 | |
| 123 | # move 1 grid unit with arrows |
| 124 | # macro Alt_Shift_XK_Left "move l 1g" |
| 125 | # macro Alt_Shift_XK_Right "move r 1g" |
| 126 | # macro Alt_Shift_XK_Up "move u 1g" |
| 127 | # macro Alt_Shift_XK_Down "move d 1g" |
| 128 | |
| 129 | # stretch 0.05um with arrows |
| 130 | # macro Control_XK_Left "stretch l 1l" |
| 131 | # macro Control_XK_Right "stretch r 1l" |
| 132 | # macro Control_XK_Up "stretch u 1l" |
| 133 | # macro Control_XK_Down "stretch d 1l" |
| 134 | |
| 135 | # stretch 1 grid unit with arrows |
| 136 | # macro Control_Shift_XK_Left "stretch l 1g" |
| 137 | # macro Control_Shift_XK_Right "stretch r 1g" |
| 138 | # macro Control_Shift_XK_Up "stretch u 1g" |
| 139 | # macro Control_Shift_XK_Down "stretch d 1g" |
| 140 | |
| 141 | # shift mouse wheel bindings for right-left shift |
| 142 | macro Shift_XK_Pointer_Button4 "scroll r .05 w" |
| 143 | macro Shift_XK_Pointer_Button5 "scroll l .05 w" |
| 144 | |
| 145 | # control mouse wheel bindings for zoom in/out |
| 146 | macro Control_XK_Pointer_Button4 "zoom 0.70711" |
| 147 | macro Control_XK_Pointer_Button5 "zoom 1.41421" |
| 148 | |
| 149 | # Bertrand's original arrow macros |
| 150 | # move 1 grid unit with arrows |
| 151 | macro XK_Left "move l 1g" |
| 152 | macro XK_Right "move r 1g" |
| 153 | macro XK_Up "move u 1g" |
| 154 | macro XK_Down "move d 1g" |
| 155 | |
| 156 | # move 0.05um with arrows |
| 157 | macro Control_XK_Left "move l 1l" |
| 158 | macro Control_XK_Right "move r 1l" |
| 159 | macro Control_XK_Up "move u 1l" |
| 160 | macro Control_XK_Down "move d 1l" |
| 161 | |
| 162 | # stretch 1 grid unit with arrows |
| 163 | macro Shift_XK_Left "stretch l 1g" |
| 164 | macro Shift_XK_Right "stretch r 1g" |
| 165 | macro Shift_XK_Up "stretch u 1g" |
| 166 | macro Shift_XK_Down "stretch d 1g" |
| 167 | |
| 168 | # stretch 0.05um with arrows |
| 169 | macro Control_Shift_XK_Left "stretch l 1l" |
| 170 | macro Control_Shift_XK_Right "stretch r 1l" |
| 171 | macro Control_Shift_XK_Up "stretch u 1l" |
| 172 | macro Control_Shift_XK_Down "stretch d 1l" |
| 173 | |
| 174 | # Restore pan function on Alt-key |
| 175 | # Pan 10 percent of the window size with arrows |
| 176 | macro Alt_XK_Left "scroll l .1 w" |
| 177 | macro Alt_XK_Up "scroll u .1 w" |
| 178 | macro Alt_XK_Right "scroll r .1 w" |
| 179 | macro Alt_XK_Down "scroll d .1 w" |
| 180 | |
| 181 | # Pan 100 percent of the window size with arrows |
| 182 | macro Alt_Shift_XK_Left "scroll l 1 w" |
| 183 | macro Alt_Shift_XK_Up "scroll u 1 w" |
| 184 | macro Alt_Shift_XK_Right "scroll r 1 w" |
| 185 | macro Alt_Shift_XK_Down "scroll d 1 w" |
| 186 | |