简体   繁体   English

VSC 与 PyCharm 自动完成选项卡:它可以填充函数、括号并退出该行吗?

[英]VSC vs PyCharm auto-completion tab : can it fill function, parenthesis and exit the line?

I've been using so far PyCharm to code Python.到目前为止,我一直在使用 PyCharm 来编写 Python 代码。 I've recently been introduced to Visual Studio Code, as it seems lighter and faster and that my computer is old, I'm thinking to move to VSC for all my coding.我最近接触了 Visual Studio Code,因为它看起来更轻、更快,而且我的电脑很旧,我正在考虑将我的所有编码转移到 VSC。

There is something however that I found very convenient with PyCharm with auto-completion : when you start to write a function/class/method... it offers really quickly some suggestion (auto-completion), and by pressing tab it completes the let's say function, adding the brackets/parenthesis.然而,我发现 PyCharm 的自动完成功能非常方便:当您开始编写函数/类/方法时...说函数,添加括号/圆括号。 Then it sets the cursor in the parenthesis.然后它将光标设置在括号中。 Another press on the TAB then it will take you out of the parenthesis.再按一下 TAB,它就会带你离开括号。

I've found how to auto-complete functions with VSC, but after the first TAB press, bringing me inside functions parenthesis, another hit on TAB will instead bring me another suggestion.我已经找到了如何使用 VSC 自动完成功能,但是在第一次按下 TAB 之后,将我带到函数括号内,再次点击 TAB 会给我带来另一个建议。

Is there a way to get VSC using auto-tab-completion same to PyCharm?有没有办法使用与 PyCharm 相同的自动制表符完成来获取 VSC? (and BTW, how about in Sublime?) (顺便说一句,在 Sublime 中怎么样?)

Sorry, it's impossible for now.抱歉,暂时不可能。

What you have taken in the PyCharm was Jump Outside Current Bracket/Quote command, but it's not available in the VSCode.您在 PyCharm 中采用的是Jump Outside Current Bracket/Quote命令,但它在 VSCode 中不可用。

VSCode only provides the command of editor.action.jumpToBracket and editor.action.selectToBracket , both of them were not what you are looking for. VSCode 只提供了editor.action.jumpToBracketeditor.action.selectToBracket的命令,这两个都不是你要找的。

But if you don't like it jump to next suggestion, you can move the keybinding of it like this:但是如果你不喜欢它跳到下一个建议,你可以像这样移动它的键绑定:

在此处输入图片说明

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

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