zoukankan      html  css  js  c++  java
  • macos下用karabiner实现preview翻半页

    其实我没找到翻半页的方式,只是搞了个方法多翻几行,来达到效果。
    配置文件目录:

    /Users/xxx/.config/karabiner/assets/complex_modifications
    

    新增一个my.json

    {
      "title": "my_key_map",
      "rules": [
        {
          "description": "my_key_map",
          "manipulators": [
            {
              "type": "basic",
              "conditions": [
                {
                  "bundle_identifiers": [
                    "^com\.apple\.Preview$"
                  ],
                  "type": "frontmost_application_if"
                }
              ],
              "from": {
                "key_code": "d"
              },
              "to": [
                {
                  "key_code": "up_arrow"
                },
                {
                  "key_code": "up_arrow"
                },
                {
                  "key_code": "up_arrow"
                },
                {
                  "key_code": "up_arrow"
                },
                {
                  "key_code": "up_arrow"
                }
              ]
            },
            {
              "type": "basic",
              "conditions": [
                {
                  "bundle_identifiers": [
                    "^com\.apple\.Preview$"
                  ],
                  "type": "frontmost_application_if"
                }
              ],
              "from": {
                "key_code": "f"
              },
              "to": [
                {
                  "key_code": "down_arrow"
                },
                {
                  "key_code": "down_arrow"
                },
                {
                  "key_code": "down_arrow"
                },
                {
                  "key_code": "down_arrow"
                },
                {
                  "key_code": "down_arrow"
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "u",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "left_arrow",
                  "modifiers": [
                    "command"
                  ]
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "y",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "left_arrow",
                  "modifiers": [
                    "command",
                    "shift"
                  ]
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "i",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "right_arrow",
                  "modifiers": [
                    "command"
                  ]
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "o",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "right_arrow",
                  "modifiers": [
                    "command",
                    "shift"
                  ]
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "comma",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "left_arrow",
                  "modifiers": [
                    "shift"
                  ]
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "period",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "right_arrow",
                  "modifiers": [
                    "shift"
                  ]
                }
              ]
            },
            {
              "type": "basic",
              "from": {
                "key_code": "d",
                "modifiers": {
                  "mandatory": [
                    "command"
                  ],
                  "optional": [
                    "any"
                  ]
                }
              },
              "to": [
                {
                  "key_code": "delete_or_backspace"
                }
              ]
            }
          ]
        }
      ]
    }
    

    然后在karabiner的设置中重新加载一下rule,remove再enable。

  • 相关阅读:
    use tomcat to access the file cross the environment
    data audit on hadoop fs
    Good practice release jar to Nexus
    套路!从Ruby 到 Cocoapods的发布
    单元测试之NSNull 检测
    UIwebView 和 H5交互详情
    IT 需要知道的一些专业名词和解释 (长期更新)
    Git 操作 学习资源 网址
    GCD
    软件工程——个人总结
  • 原文地址:https://www.cnblogs.com/shanchuan/p/15315165.html
Copyright © 2011-2022 走看看