简体   繁体   English

如何在 Windows 上为 WebStorm 或 IntelliJ IDEA 使用 Mac OSX Keymap?

[英]How to use Mac OSX Keymap on Windows for WebStorm or IntelliJ IDEA?

I use WebStorm on both my Mac and Windows for work purposes.我在 Mac 和 Windows 上都使用 WebStorm 进行工作。 I would like to know if it is possible to use the MAC OSX keymap on Windows.我想知道是否可以在 Windows 上使用 MAC OSX 键盘映射。

On windows if you load the MAC OSX keymap the mappings don't seem to line up correctly.在 Windows 上,如果您加载 MAC OSX 键盘映射,映射似乎没有正确排列。 For instance I see the character Meta being used, however Windows doesn't seem to properly map that character.例如,我看到正在使用的字符Meta ,但是 Windows 似乎没有正确映射该字符。

I also would like to note I am using a Mac keyboard on the Windows PC.我还要注意我在 Windows PC 上使用 Mac 键盘。

How does Cmd ( Meta ) key map to your Windows keys? Cmd ( Meta ) 键如何映射到您的 Windows 键?

You can get the full Mac keymap XML file and replace meta with whatever key it is on Windows.您可以获得完整的 Mac 键盘映射 XML文件并用它在 Windows 上的任何键替换meta Some keys may not work or you may get conflicting mappings.某些键可能不起作用,或者您可能会得到冲突的映射。

There is no easy and straightforward way that will work out of the box.没有任何简单直接的方法可以开箱即用。

On Mac keymap is using Alt , Ctrl , Meta and Shift modifiers. Mac 键盘映射使用AltCtrlMetaShift修饰符。 This cannot be directly mapped to only 3 modifiers you have on Windows ( Alt , Ctrl , Shift ).这不能直接映射到 Windows 上只有 3 个修饰符( AltCtrlShift )。 You can't use Win as the modifier by default.默认情况下,您不能使用Win作为修饰符

Also, a lot of the combinations with Win would be already taken by the OS (and the only way to disable these default mappings is via registry modification ).此外,操作系统已经采用了许多与Win的组合(禁用这些默认映射的唯一方法是通过注册表修改)。

You are welcome to give it a try as there is a workaround to make Win work as a modifier in IntelliJ IDEA.欢迎您尝试一下,因为有一种解决方法可以让Win作为 IntelliJ IDEA 中的修饰符工作。

在 Windows 上,转到file > settings > keymap然后在keymaps下拉列表中选择defaultmeta (又名cmd )键将被ctrl替换。

There is a third party plugin by samvtrran that solve that: macOS For All samvtrran有一个第三方插件可以解决这个问题: macOS For All

Here is the plugin description:这是插件说明:

A keymap for Windows and Linux (and macOS if you really want!) that rebinds common macOS 10.5+ shortcuts to non-Command keys.适用于 Windows 和 Linux(如果您真的需要,还有 macOS!)的键盘映射,它将常见的 macOS 10.5+ 快捷方式重新绑定到非 Command 键。 Some shortcuts aren't 1:1 replacements of modifier keys, so please check the key updates table.某些快捷方式不是修饰键的 1:1 替换,因此请检查键更新表。

If you notice any conflicting shortcuts or have a suggestion for a new keybinding, please open an issue on GitHub.如果您发现任何冲突的快捷方式或对新的键绑定有建议,请在 GitHub 上打开一个问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM