gpt4 book ai didi

sublimetext3 - 粘贴代码时,Sublime Text 3会误解缩进

转载 作者:行者123 更新时间:2023-12-03 13:34:32 24 4
gpt4 key购买 nike

喜欢Sublime文字,尽管我遇到了一个问题,在复制代码时这似乎是一个不一致的问题。我使用tab进行缩进,当我需要复制代码时,它似乎试图将制表符解释为空格,但导致发送缩进变得很奇怪。

我知道您可以进入设置,就这样了,并更改了诸如tab_sizetranslate_tabs_to_spaces之类的属性的值,但似乎没有什么可以阻止它的发生。这些行不是缩进4个空格,而是仅一个空格,当我按下tab时,它会将空格移动了一个空格。

问题

我如何强制Sublime每次创建新文档时仅使用tab进行缩进,当前缩进当前设置为4空间?

最佳答案

您没有告诉我们如何粘贴代码,所以我假设您正在执行简单的粘贴操作,而不是使用Shift的Sublime Text方法:

Sublime’s Paste and Indent command fixes this by automatically adjusting the indentation of your pasted code to match the surrounding lines.

This command is bound to Ctrl+Shift+V on Windows and Linux or Shift+Cmd+V on Mac. Give it a try—it’s magical.

关于sublimetext3 - 粘贴代码时,Sublime Text 3会误解缩进,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47770917/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com