Sublime text 3 丑陋的语法高亮显示

Sublime text 3 ugly syntax highlighting

我正在学习 Ruby 并且我正在使用 Sublime Text 3,但我发现语法突出显示非常奇怪。

例如:

Ugly syntax

即使将语法设置为 ruby。

Ruby syntax set

我想知道这是否正常,或者我是否需要对用户进行一些更改 设置或类似的东西。

Ruby (Ruby.sublime-syntax) 的语法文件包含未解决问题的列表。其中有:

      text:
      "p << end
      print me!
      end"
      symptoms:
      not recognized as a heredoc
      solution:
      there is no way to distinguish perfectly between the << operator and the start
      of a heredoc. Currently, we require assignment to recognize a heredoc. More
      refinement is possible.
      • Heredocs with indented terminators (<<-) are always distinguishable, however.
      • Nested heredocs are not really supportable at present

所以是的,这很正常。

您可以访问 https://packagecontrol.io/ 并使用 Railscast 配色方案

sublime 附带的基本语法突出显示非常稀少 - 这些包通常做得更好。这也只是一个例子。有很多主题和配色方案。

根据本页中的 sublime 版本安装包控件 ctrl+ 并在代码段中过去 https://packagecontrol.io/installation#st3