1
votes

I would like to enable the Romanian Programmers keyboard layout with AutoHotKey because I need to use some applications which have certain shortcuts that overlap with "unusual" layouts and having Right Alt transformed into AltGr is not acceptable.

Please see my answer for a working solution, and feel free to suggest improvements.

1

1 Answers

0
votes

Here is the script that I ended up using:

;Disable the Right Alt key (the keydown event will still be fired, but that's OK)
RAlt::Return

RAlt & a::
    if GetKeyState("Shift", "P") {
        Send Ă
    } else {
        Send ă
    }
    Return

RAlt & q::
    if GetKeyState("Shift", "P") {
        Send Â
    } else {
        Send â
    }
    Return

RAlt & i::
    if GetKeyState("Shift", "P") {
        Send Î
    } else {
        Send î
    }
    Return

RAlt & s::
    if GetKeyState("Shift", "P") {
        Send Ș
    } else {
        Send ș
    }
    Return

RAlt & t::
    if GetKeyState("Shift", "P") {
        Send Ț
    } else {
        Send ț
    }
    Return

RAlt & e::Send €

RAlt & c::Send ©

Please note that I have only mapped the keys that I needed from the Romanian Programmers layout, which has a few more shortcuts for uncommon symbols.