Xamarin社区工作室:恼人的自动缩进

时间:2016-10-28 12:45:38

标签: c# xamarin monodevelop xamarin-studio

如何禁用自动缩进功能/错误? (Xamarin 6.11,Mac)

  • 注意:< CURSOR HERE>指定光标的位置,而不是实际的代码。

以下是我的步骤:

  1. 我将光标放置如图所示:
  2. enter image description here

    1. 我按ENTER键:
    2. enter image description here

      1. 我输入我的声明并跳转到开始希望修复缩进:
      2. enter image description here

        1. 我按BACKSPACE:
        2. enter image description here

          此时再次按ENTER键将我带回第3步。

          请帮助,它让我疯了!

          哦,是的,改变首选项中的缩进 - >代码格式 - > C#...不会影响行为,即使重新启动也是如此。

1 个答案:

答案 0 :(得分:2)

请参阅:https://forums.xamarin.com/discussion/2509/incorrect-auto-formatting-of-c-code-for-specific-functions

向下看文字编辑器的位置 - >行为。 有一个名为“启用快速代码格式化”的选项;如果您希望格式化自己的代码,可能需要禁用此功能。

您可能希望关闭行为中的智能缩进模式。