0

I just installed Eclipse Indigo Java EE in order to play around with HTML5 (normally, I'm still using Galileo and doing Java stuff). Anyhow, when I open an .html file with the HTML editor and do CTRL + SHIFT + F to reformat the file, the results are really disappointing - no indentation for the head or body tags and weird indentation for a script tag (opening tag indented 1 tab, function call indented 3 tabs, closing tag indented 2 tabs).

I've checked all project and global preferences and can't see why this would be happening.

People (in this forum and elsewhere) recommend the Aptana plug-in, but then also seem to have lots of problems with it (crashes Indigo, compatability only with Helios, etc.).

What would you recommend?

4

1 回答 1

0

我硬着头皮安装了 Aptana。不好玩,就像许多其他人报道的那样。我仍然不认为事情是他们应该的那样,因为当我在 html 文件上“打开”时,我得到了一个 Django (Aptana) 编辑器,而不仅仅是一个普通的 Aptana 编辑器。

无论如何,Django (Aptana) 编辑器在格式化/语法着色方面做得非常好。

对于那些在安装软件时遇到问题的人,我找到了两个建议:

  • 增加 jvm 的最大堆大小(我将我的从 256MB 增加到 512)

  • 将系统属性 java.util.Arrays.useLegacyMergeSort 设置为 true

乐于助人。

您可以通过将以下内容添加到 eclipse.ini 来完成这两项工作:

--launcher.XXMaxPermSize 512m

-vmargs -Djava.util.Arrays.useLegacyMergeSort=true

于 2012-02-27T15:17:41.630 回答