使用 AutoHotkey 的罗马尼亚程序员键盘布局

Romanian Programmers keyboard layout using AutoHotkey

我想使用 AutoHotKey 启用 Romanian Programmers 键盘布局,因为我需要使用一些应用程序,这些应用程序具有与 "unusual" 布局重叠的某些快捷方式,并且将 Right Alt 转换为 AltGr 是不可接受的.

请查看我的答案以获得可行的解决方案,并随时提出改进建议。

这是我最终使用的脚本:

;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 ©

请注意,我只映射了罗马尼亚程序员布局中我需要的键,其中有一些不常用符号的快捷方式。