2

I want to switch the { key with [, so I don't have to use the Shift anymore to make { and I do have to use Shift key to make [...

same question for switching , to < and vice versa.

I know only how to make the first part work:

[::{

However, switching { with [ doesn't work when I try the following:

{::[

How do I insert the Shift key?

  • @Mihai You might want to clarify exactly what you mean by shift to make [ and other... – user197261 Mar 7 '13 at 15:34
  • @Armin maybe but I think it would be better suited for something like Super User – Hugo Dozois Mar 7 '13 at 15:36
  • @HugoDozois Well, stackoverflow has a decent autohotkey base (at least one question per day), and this is a code problem. [::{ ahk code example – user197261 Mar 7 '13 at 15:38
3

Let me know if this is what you want?
[ -> { and { -> ]

#SingleInstance Force
#installKeybdHook
#Persistent

; Prefix the hotkeys with $ to prevent one hotkey from launching the other hotkey in a loop!

; + is the shift key, so +[ is {

;==== Switch [ AND { ====
$[::Send, {{}
$+[::Send, {[}

;====Switch ] AND } ====
$]::Send, {}}
$+]::Send, {]}

;====Switch , AND < ====
$,::Send, <
$+,::Send, {,}

;====Switch . AND > ====
$.::Send, >
$+.::Send, .
| improve this answer | |
  • Thanks very much Robert Ilbrink, master of AHK! Work great. – Mihai Mar 7 '13 at 17:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy