Here is an simplified code sample, for what I'm trying to do. A text entered above in an inputTextArea is correctly displayed (with Line Breaks).
Below, in the dataTable, the same text is displayed without Line breaks.
<h:form id=myInputText#{id}>
<h:inputTextarea id="myInputText" value="#{form.textWithLinebreaks}"/>
</h:form>
<h:form id=myOutput>
<rich:dataTable
id="myTable"
value="#{form.model}"
var="f"
style="table-layout: fixed;"
styleClass="wordWrap"
rows="5">
<a4j:support event="onRowClick"
action="#{action.selectText(f)}"
immediate="true" reRender="myInputText#{id}" />
<rich:column>
<f:facet name="header">
TextShouldHaveLineBreaks
</f:facet>
<h:outputText value="#{f.text}"/>
</rich:column>
</rich:dataTable>
</h:form>
Things I tried to fix this:
<h:outputText value="#{f.text}" style="white-space: pre-wrap"/>
doesn't Change anything.
I also tried using a readonly inputTextArea as a workaound:
<rich:column>
<f:facet name="header">
TextShouldHaveLineBreaks
</f:facet>
<h:inputTextarea value="#{f.text}" style="white-space: pre-wrap" readonly="true"/>
</rich:column>
This doesn't help either, and will require lots of css to look just like all other columns.
Just in case this is relevant: My application runs on Seam with Richfaces 3.3.