; ; autohotkey version: 1.x ; language: english ; platform: win9x/nt ; author: a. kulakov ; todo: close properties ; ; script function: ; quick autocad shortcuts. ; alt-d - suspend ; g - modifier ; w - modifier 2 ; g5 - properties ; ggf - options ; wx - select previous ; === layers ; g3 - previous layer ; g4 - layers ; === create ; q - leader ; r - line ; wq - xline ; ga - rectangle ; gv - circle ; === modify ; e - erase ; t - match properties ; gq - fillet ; gw - rotate ; gf - stretch ; wr - mirror ; ge - explode ; gt - edit text ; wq - offset ; gb - scale ; c - copy ; v - move ; gz - undo ; tab - extend ; wt - trim ; wc - colors ; wwx - to mtext ; === snap ; g2 - snap near ; s - osnap ; wwa - polar ; w2 - between 2 points ; w3 - middle ; w4 - end ; w5 - center ; === zoom & move ; a - zoom extents ; d - zoom previous ; f - zoom window ; wg - zoom dynamic ; b - pan ; z - zoom out ; wz - zoom out more ; we - pan up ; wd - pan down ; ws - pan left ; wf - pan right ; === dimensions ; x - dimension ; gh - dimaligned ; h - dimangular ; gd - home dim text ; ggx - dim style ; gx - distance ; === file ; gr - print ; gs - save ; gc - save & close ; wv - close ; === document space ; wwd - model space ; wa - layout space !d::suspend settitlematchmode 2 SetKeyDelay, 0 #ifwinactive AutoCAD g:: If (wprefix != true) { If (gprefix = true) { ggprefix := true gprefix := false } Else gprefix := true } return w:: If (gprefix = true) { Send ^+{F12} ; rotate gprefix := false } else if (wprefix = true) { wwprefix := true wprefix := false } Else wprefix := true return q:: If (gprefix = true) { Send ^+{f11} ; fillet gprefix := false } else if (wwprefix = true) { SetKeyDelay, 20 Send close{Enter} ; close Send n wwprefix := false } else if (wprefix = true) { Send ^+e ; offset wprefix := false } Else Send ^+z ; qleader Return tab:: Send ^+l ; extend return 3:: if (gprefix = true) { Send ^+{f2} ; prev layer ggprefix := false } else if (wprefix = true) { Send mid{enter} ; mid of wprefix := false } else Send 3 return 4:: if (gprefix = true) { Send ^+{f3} ; layers ggprefix := false } else if (wprefix = true) { Send end{enter} ; end of wprefix := false } else Send 4 return 5:: if (gprefix = true) { Send properties{enter} ; properties gprefix := false } else if (wprefix = true) { Send cen{enter} ; center of wprefix := false } else Send 5 return e:: if (gprefix = true) { Send ^+!c ; explode gprefix := false } else if (wwprefix = true) ; temp, duplicate.. { Send per{enter} ; perpendicular to.. wwprefix := false } else if (wprefix = true) { Send ^+9 ; pan up wprefix := false } else Send ^+{f9} ; erase return r:: if (gprefix = true) { Send ^!r ; print gprefix := false } else if (wprefix = true) { Send ^+b ; mirror wprefix := false } else Send ^+{f5} ; line return t:: if (gprefix = true) { Send ^+k ; edit text gprefix := false } else if (wprefix = true) { Send ^+m ; trim wprefix := false } else Send ^+o ; match properties return 2:: if (gprefix = true) { Send ^+n ; snap near gprefix := false } else if (ggprefix = true) { Send ^!1 ; hatch ggprefix := false } else Send 2 return 1:: if (wprefix = true) { Send per ; perpendicular wprefix := false } else Send 1 return a:: if (gprefix = true) { Send ^+{f7} ; rectangle gprefix := false } else if (wprefix = true) { Send layout{Enter}{Enter}{Enter} ; layout space wprefix := false } else if (wwprefix = true) { Send {F10} ; polar wwprefix := false } else Send ^+q ; zoom extents return s:: if (gprefix = true) { Send ^s ; quick save gprefix := false } else if (wprefix = true) { Send ^+W ; pan left wprefix := false } else Send ^f ; osnap return d:: if (gprefix = true) { Send ^+x ; home dim text gprefix := false } else if (wwprefix = true) { Send model{Enter} ; model space wwprefix := false } else if (wprefix = true) { Send ^+{F10} ; pan down wprefix := false } else Send ^{f7} ; zoom previous return f:: if (gprefix = true) { Send ^+a ; stretch gprefix := false } else if (wwprefix = true) { Send ^+e ; offset wwprefix := false } else if (wprefix = true) { Send ^+T ; pan right wprefix := false } else if (ggprefix = true) { Send options{enter} ; options ggprefix := false } else Send ^{f8} ; zoom window return h:: if (gprefix = true) { Send ^+u ; dim aligned gprefix := false } else Send ^+v ; dim angular return z:: if (ggprefix = true) { Send ^+r ; zoom realtime ggprefix := false } else if (gprefix = true) { Send ^z ; undo gprefix := false } else if (wprefix = true) { Send ^+I ; zoom out more wprefix := false } else Send ^+5 ; zoom out return x:: if (ggprefix = true) { Send ^+y ; dim style ggprefix := false } else If (wprefix = true) { Send ^+7 ; select previous wprefix := false } else if (gprefix = true) { Send ^!b ; distance gprefix := false } else if (wwprefix = true) { Send ^+0 ; to mtext TODO wwprefix := false } else Send ^+j ; dimension return c:: if (gprefix = true) { SetKeyDelay, 20 Send ^s ; quick save Send close{enter} ; close gprefix := false } else if (wprefix = true) { Send color{enter} ; color picker wprefix := false } else Send ^+g ; copy return v:: if (gprefix = true) { Send ^+{f8} ; circle gprefix := false } else if (wprefix = true) { SetKeyDelay, 20 Send close{Enter} ; close wprefix := false } else Send ^+h ; move return b:: if (gprefix = true) { Send ^+f ; scale gprefix := false } else Send {f7} ; pan return