Skip to content
This repository has been archived by the owner on Sep 5, 2023. It is now read-only.

h:dataTable headerClass --> headerClasses #4

Closed
glassfishrobot opened this issue Aug 19, 2004 · 14 comments
Closed

h:dataTable headerClass --> headerClasses #4

glassfishrobot opened this issue Aug 19, 2004 · 14 comments

Comments

@glassfishrobot
Copy link

Reporter: mplaine (mplaine)

Could you change the JSF specification so that h:dataTable header attribute
would be changed to headerClasses. In other words it would be possible to
assign different Classes to header columns. Basically it should work as
columnClasses attribute.

For more details... see the thread:
http://forum.java.sun.com/thread.jsp?forum=427&thread=514955

Environment

Operating System: All
Platform: All
URL: http://forum.java.sun.com/thread.jsp?forum=427&thread=514955

Affected Versions

[1.1]

@glassfishrobot
Copy link
Author

Reported by @edburns

@glassfishrobot
Copy link
Author

Was assigned to rogerk

@glassfishrobot
Copy link
Author

@edburns said:
move to p4

@glassfishrobot
Copy link
Author

@edburns said:
Give to Roger.

@glassfishrobot
Copy link
Author

rogerk said:
Adam Winer wrote:

Roger Kitain wrote:

Adam Winer wrote:

-1; I'd suggest instead adding "headerClass" and "footerClass" to
<h:column>.

I don't have a problem with this except for this question..
Did you intend "headerClass"/"footerClass" to be properties on the
UIColumn component? "headerClass"/"footerClass" are today are renderer
dependent attributes. And, we don't have a renderer for UIColumn.

These would definitely be renderer-specific properties, and imply
the existence of an HtmlColumn subclass. TableRenderer could still
render the UIColumns on their behalf (including getting these
properties, or you could move the rendering of , etc.) down
to the ColumnRenderer. Which way you do it is at least partly
an implementation decision, but the latter's a bit better since
it would let someone write an alternative column renderer.

– Adam

I've taken the approach of generating an HtmlColumn subclass.
TableRenderer renders the UIColumns (as it does today), and it gets
the "headerClass"/"footerClass" properties from each column.

example:

<h:dataTable......
<h:column headerClass="column-header" footerClass="column-footer".....

By default, the "headerClass"/"footerClass" at the "dataTable" level would
also be used at the column level (as it is done today), but specifying
"headerClass"/footerClass" at the column level overrides it.

-roger

SECTION: Modified Files

M jsf-api/doc/standard-html-renderkit-base.xml
M jsf-api/doc/standard-html-renderkit.xml
— added entry for HtmlColumn
— included column-props.xml
M jsf-ri/src/com/sun/faces/renderkit/html_basic/TableRenderer.java
— for each child column, render the headerClass/footerClass column
attributes (if present); Otherwise default to the table level
headerClass/footerClass (if present)
M jsf-ri/src/com/sun/faces/taglib/html_basic/ColumnTag.java
— add headerClass/footerClass properties; include in setProperties method.
M jsf-ri/web/test/RenderResponse_correct
— new golden file for test
M jsf-ri/web/test/TestRenderResponsePhase.jsp
— include h:dataTable with two nested columns
M jsf-tools/conf/TAG-DEF-12.txt
M jsf-tools/conf/TAG-DEF-21.txt
— include headerClass/footerClass attributes

A jsf-api/doc/column-props.xml
— new properties for "column" (headerClass/footerClass)

@glassfishrobot
Copy link
Author

rogerk said:
Created an attachment (id=13)
Change bundle for this issue.

@glassfishrobot
Copy link
Author

File: issue-4.zip.gz
Attached By: rogerk

@glassfishrobot
Copy link
Author

@edburns said:
RK> SECTION: Modified Files
RK> ----------------------------
RK> M jsf-api/doc/standard-html-renderkit-base.xml
RK> M jsf-api/doc/standard-html-renderkit.xml
RK> — added entry for HtmlColumn
RK> — included column-props.xml

Ok.

RK> M jsf-ri/src/com/sun/faces/renderkit/html_basic/TableRenderer.java
RK> — for each child column, render the headerClass/footerClass column
RK> attributes (if present); Otherwise default to the table level
RK> headerClass/footerClass (if present)

Ok.

RK> M jsf-ri/src/com/sun/faces/taglib/html_basic/ColumnTag.java
RK> — add headerClass/footerClass properties; include in setProperties method.
RK>

OK. We have to remember to convert these to the new setter type of
a javax.el.Expression subclass.

RK> M jsf-ri/web/test/RenderResponse_correct
RK> — new golden file for test
RK> M jsf-ri/web/test/TestRenderResponsePhase.jsp
RK> — include h:dataTable with two nested columns
RK> M jsf-tools/conf/TAG-DEF-12.txt
RK> M jsf-tools/conf/TAG-DEF-21.txt
RK> — include headerClass/footerClass attributes
RK>

RK> A jsf-api/doc/column-props.xml
RK> — new properties for "column" (headerClass/footerClass)

Are we sure that it's space separated, and not comma delimited? If so,
r=edburns.

Ed

@glassfishrobot
Copy link
Author

rogerk said:
checked in.

@glassfishrobot
Copy link
Author

@edburns said:
Prepare to delete "spec" subcomponent.

@glassfishrobot
Copy link
Author

@edburns said:
Move all to 1.2

@glassfishrobot
Copy link
Author

Marked as fixed on Thursday, March 4th 2010, 6:09:29 am

@glassfishrobot
Copy link
Author

@manfredriem said:
Closing resolved issue out

@glassfishrobot
Copy link
Author

This issue was imported from java.net JIRA JAVASERVERFACES_SPEC_PUBLIC-4

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant