问题描述:

How can I get formatting/autoindent working for Facelets pages? I have added JSF to my project facet in the project properties and that brings up the autocomplete for JSF tags, etc but I can't find the option to format/autoindent the code.

网友答案:

Just the same shortcut as you'd use on Java source files Ctrl+Shift+F works fine for me on Facelets files on Eclipse Indigo SR2. They'll be formatted according the XML syntax rules which you can configure in Window > Preferences > XML > XML Files > Editor. An alternative way to trigger this is rightclick the Facelets file and then choose Source > Format.

I'm also using the JBoss Tools plugin, but this feature isn't specific to the JBoss Tools plugin.

相关阅读:
Top