Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix rejected key release resets candidate window #44

Merged
merged 1 commit into from
Sep 12, 2024
Merged

fix rejected key release resets candidate window #44

merged 1 commit into from
Sep 12, 2024

Conversation

eagleoflqj
Copy link
Member

fcitx-contrib/fcitx5-macos#188 only works for single key.

Test:

  • Map CapsLock to Hyper (Ctrl+Option+Command+Shift) and then Hyper+HJKL to Left, Down, Up, Right by writing .config/karabiner/karabiner.json:
{
    "profiles": [
        {
            "complex_modifications": {
                "rules": [
                    {
                        "description": "Caps Lock → Hyper Key (⌃⌥⇧⌘) (Caps Lock if alone)",
                        "manipulators": [
                            {
                                "from": { "key_code": "caps_lock" },
                                "to": [
                                    {
                                        "key_code": "left_shift",
                                        "modifiers": ["left_command", "left_control", "left_option"]
                                    }
                                ],
                                "to_if_alone": [{ "key_code": "caps_lock" }],
                                "type": "basic"
                            }
                        ]
                    },
                    {
                        "description": "Hyper + h/j/k/l == vim directional Keys",
                        "manipulators": [
                            {
                                "from": {
                                    "key_code": "k",
                                    "modifiers": { "mandatory": ["left_shift", "left_command", "left_control", "left_option"] }
                                },
                                "to": [{ "key_code": "up_arrow" }],
                                "type": "basic"
                            },
                            {
                                "from": {
                                    "key_code": "h",
                                    "modifiers": { "mandatory": ["left_shift", "left_command", "left_control", "left_option"] }
                                },
                                "to": [{ "key_code": "left_arrow" }],
                                "type": "basic"
                            },
                            {
                                "from": {
                                    "key_code": "j",
                                    "modifiers": { "mandatory": ["left_shift", "left_command", "left_control", "left_option"] }
                                },
                                "to": [{ "key_code": "down_arrow" }],
                                "type": "basic"
                            },
                            {
                                "from": {
                                    "key_code": "l",
                                    "modifiers": { "mandatory": ["left_shift", "left_command", "left_control", "left_option"] }
                                },
                                "to": [{ "key_code": "right_arrow" }],
                                "type": "basic"
                            },
                            {
                                "from": {
                                    "key_code": "semicolon",
                                    "modifiers": { "mandatory": ["left_shift", "left_command", "left_control", "left_option"] }
                                },
                                "to": [
                                    {
                                        "key_code": "right_arrow",
                                        "modifiers": ["left_command"]
                                    }
                                ],
                                "type": "basic"
                            }
                        ]
                    }
                ]
            }
        }
    ]
}
  • Expand scroll for any rime schema, then Hyper+J should move highlight down, and no reset on release.

Copy link

Arch comparison

- x86_64 arm64 any
anthy
array
bamboo
boshiamy
cangjie
cantonese
chewing
chinese-addons
hallelujah
hangul
lua
quick
rime
sayura
skk
stroke
thai
unikey
wu
wubi86
wubi98
zhengma

22 plugins in total.

@ksqsf ksqsf merged commit a59b76b into master Sep 12, 2024
4 checks passed
@ksqsf ksqsf deleted the keyup branch September 12, 2024 18:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants