Better formatting of xhtml files

Asked

Viewed 94 times

4

Given the excerpt from my archive .xhtml:

<h:panelGrid id="camposPesquisa" columns="2">
    <h:outputLabel value="#{msg['nome']}: " />
    <p:inputText value="#{naturemb.arg}" />
</h:panelGrid>
<h:panelGrid id="botoes" columns="2" styleClass="botoesCrud">
    <p:commandButton actionListener="#{naturemb.pesquisar}"
        value="#{msg['pesquisar']}" ajax="false"
        update="cadastro,pesquisa" />
    <p:commandButton actionListener="#{naturemb.novo}"
        value="#{msg['novo']}" ajax="false" update="cadastro"
        styleClass="separadorBotoes" />
</h:panelGrid>

Note that when indenting Eclipse, there are many line breaks in the attributes. It has how to set up so that it does not break as much of line?

Ex: 5 attributes in the same row, etc ?

1 answer

1


Yes there are options for this.

1 - First check if the indentation is breaking each attribute per line on:

Window>Preferences>Web>HTML files>Editor

Uncheck the multiple split option ...

inserir a descrição da imagem aqui

2 - Increase the size of characters per line change the number of line width that is 100 (in the image) for a value suitable for your needs.

  • Show, thank you.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.