简体   繁体   English

我可以在 pycharm 中使用另一个快捷方式进行自动导入吗?

[英]Can I use another shortcut for auto import in pycharm?

The shortcut Alt+Enter is intercepted by my window manager(i3) to create a new terminal, so the default shortcut of auto import (which is also Alt + Enter ) doesn't work in pycharm.快捷键Alt+Enter被我的窗口管理器(i3)拦截来创建一个新的终端,所以auto import的默认快捷键(也是Alt + Enter )在pycharm中不起作用。 Can I use another shortcut to do the auto import ?我可以使用其他快捷方式进行auto import吗? It's really a pain to import the required package manually every time.每次都手动导入需要的包,真的很痛苦。

Go to

File > Settings > Keymap 

And remap your auto-import to a different key or combination of keys.并将您的自动导入重新映射到不同的键或键组合。 The keymap should be labeled under键盘映射应标记为

Other > Show Intention Actions

You can search for it in the search bar.您可以在搜索栏中搜索它。 Google is your friend and can come in handy when asking simple questions like these, so please abstain from asking questions that can be easily found online. Google 是您的朋友,在提出此类简单问题时可以派上用场,因此请避免提出在网上很容易找到的问题。

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

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