You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beehive.apache.org by ek...@apache.org on 2005/02/22 00:00:47 UTC

svn commit: r154736 - incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid incubator/beehive/trunk/netui/src/tags-html/org/apache/beehive/netui/tags/html

Author: ekoneil
Date: Mon Feb 21 15:00:44 2005
New Revision: 154736

URL: http://svn.apache.org/viewcvs?view=rev&rev=154736
Log:
Fix for JIRA 318:

BEEHIVE-318    	 data grid needs to support the th / td html attributes

Add the remaining <th> and <td> attributes to the <headerCell> and AbstractHtmlTableCell classes.

BB: self
DRT: NetUI / datagrid pass


Modified:
    incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/AbstractHtmlTableCell.java
    incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/HeaderCell.java
    incubator/beehive/trunk/netui/src/tags-html/org/apache/beehive/netui/tags/html/HtmlConstants.java

Modified: incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/AbstractHtmlTableCell.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/AbstractHtmlTableCell.java?view=diff&r1=154735&r2=154736
==============================================================================
--- incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/AbstractHtmlTableCell.java (original)
+++ incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/AbstractHtmlTableCell.java Mon Feb 21 15:00:44 2005
@@ -44,7 +44,7 @@
     private String _sortExpression = null;
     private String _filterExpression = null;
 
-    private TdTag.State _tdState = new TdTag.State();
+    private TdTag.State _cellState = new TdTag.State();
 
     /**
      * @netui:attribute required="false" rtexprvalue="true"
@@ -80,7 +80,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnClick(String onClick) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONCLICK, onClick);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONCLICK, onClick);
     }
 
     /**
@@ -94,7 +94,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnDblClick(String onDblClick) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONDBLCLICK, onDblClick);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONDBLCLICK, onDblClick);
     }
 
     /**
@@ -108,7 +108,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnKeyDown(String onKeyDown) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYDOWN, onKeyDown);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYDOWN, onKeyDown);
     }
 
     /**
@@ -122,7 +122,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnKeyUp(String onKeyUp) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYUP, onKeyUp);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYUP, onKeyUp);
     }
 
     /**
@@ -136,7 +136,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnKeyPress(String onKeyPress) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYPRESS, onKeyPress);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYPRESS, onKeyPress);
     }
 
     /**
@@ -150,7 +150,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseDown(String onMouseDown) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseDown);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseDown);
     }
 
     /**
@@ -164,7 +164,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseUp(String onMouseUp) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseUp);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseUp);
     }
 
     /**
@@ -178,7 +178,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseMove(String onMouseMove) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEMOVE, onMouseMove);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEMOVE, onMouseMove);
     }
 
     /**
@@ -192,7 +192,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseOut(String onMouseOut) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOUT, onMouseOut);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOUT, onMouseOut);
     }
 
     /**
@@ -206,7 +206,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseOver(String onMouseOver) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOVER, onMouseOver);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOVER, onMouseOver);
     }
 
     /**
@@ -222,7 +222,7 @@
     public void setCellStyle(String style) {
         if("".equals(style)) return;
 
-        _tdState.style = style;
+        _cellState.style = style;
     }
 
     /**
@@ -238,7 +238,7 @@
     public void setCellStyleClass(String styleClass) {
         if("".equals(styleClass)) return;
 
-        _tdState.styleClass = styleClass;
+        _cellState.styleClass = styleClass;
     }
 
     /**
@@ -252,7 +252,177 @@
      * @netui.tldx:attribute category="misc"
      */
     public void setCellTitle(String title) {
-        _tdState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.TITLE, title);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.TITLE, title);
+    }
+
+    /**
+     * Sets the value of the cell's rowspan attribute.
+     *
+     * @param rowSpan
+     * @jsptagref.attributedescription The row span
+     * @jsptagref.databindable false
+     * @jsptagref.attributesyntaxvalue <i>string_rowspan</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The rowspan."
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellRowspan(int rowSpan) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.ROWSPAN, "" + rowSpan);
+    }
+
+    /**
+     * Sets the value of the cell's colspan attribute.
+     *
+     * @param colSpan
+     * @jsptagref.attributedescription The colspan
+     * @jsptagref.databindable false
+     * @jsptagref.attributesyntaxvalue <i>string_colspan</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The colspan."
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellColspan(int colSpan) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.COLSPAN, "" + colSpan);
+    }
+
+    /**
+     * Sets the value of the horizontal align attribute.
+     *
+     * @param align
+     * @jsptagref.attributedescription The horizontal alignment.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_align</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's horizontal alignment"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellAlign(String align) {
+        /* todo: should this enforce left|center|right|justify|char as in the spec */
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.ALIGN, align);
+    }
+
+    /**
+     * Sets the value of the horizontal alignment character attribute.
+     *
+     * @param alignChar
+     * @jsptagref.attributedescription The horizontal alignment character.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_alignChar</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's horizontal alignment character"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellChar(String alignChar) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.CHAR, alignChar);
+    }
+
+    /**
+     * Sets the value of the horizontal alignment character offset attribute.
+     *
+     * @param alignCharOff
+     * @jsptagref.attributedescription The horizontal alignment character offset
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_alignCharOff</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's horizontal alignment character offset"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellCharoff(String alignCharOff) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.CHAROFF, alignCharOff);
+    }
+
+    /**
+     * Sets the value of the vertical alignment attribute.
+     *
+     * @param align
+     * @jsptagref.attributedescription The vertical alignment.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_align</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's vertical alignment"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellValign(String align) {
+        /* todo: should this enforce top|middle|bottom|baseline as in the spec */
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.VALIGN, align);
+    }
+
+    /**
+     * Sets the value of the languageattribute.
+     *
+     * @param lang
+     * @jsptagref.attributedescription The language.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_lang</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's language"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellLang(String lang) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.LANG, lang);
+    }
+
+    /**
+     * Sets the value of the text direction attribute.
+     *
+     * @param dir
+     * @jsptagref.attributedescription The text direction attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_dir</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's text direction"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellDir(String dir) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.DIR, dir);
+    }
+
+    /**
+     * Sets the value of the abbreviated form of the cell's content.
+     *
+     * @param abbr
+     * @jsptagref.attributedescription The abbreviated form of the cell's content.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_dir</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The abbreviated form of the cell's content"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellAbbr(String abbr) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.ABBR, abbr);
+    }
+
+    /**
+     * Sets the value of the axis attribute.
+     *
+     * @param axis
+     * @jsptagref.attributedescription The axis attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_axis</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The axis attribute"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellAxis(String axis) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.AXIS, axis);
+    }
+
+    /**
+     * Sets the value of the headers attribute.
+     *
+     * @param headers
+     * @jsptagref.attributedescription The headers attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_headers</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The headers attribute"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellHeaders(String headers) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.HEADERS, headers);
+    }
+
+    /**
+     * Sets the value of the scope attribute.
+     *
+     * @param scope
+     * @jsptagref.attributedescription The scope attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_scope</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The scope attribute"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellScope(String scope) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.SCOPE, scope);
     }
 
     /**
@@ -293,11 +463,11 @@
         if(sortModel.isSorted(_sortExpression))
             styleClasses.add(dataGridModel.getStyleModel().getDataCellSortedClass());
 
-        if(_tdState.styleClass == null)
+        if(_cellState.styleClass == null)
             styleClasses.add(dataGridModel.getStyleModel().getDataCellClass());
-        else styleClasses.add(_tdState.styleClass);
+        else styleClasses.add(_cellState.styleClass);
 
-        _tdState.styleClass = dataGridModel.getStyleModel().buildStyleClassValue(styleClasses);
+        _cellState.styleClass = dataGridModel.getStyleModel().buildStyleClassValue(styleClasses);
 
         /* todo: this needs to run in order to cause the nested parameter / attribute / etc tags to do their work */
         JspFragment fragment = getJspBody();
@@ -305,7 +475,7 @@
         if(fragment != null)
             fragment.invoke(sw);
 
-        tableRenderer.openTableCell(_tdState, appender);
+        tableRenderer.openTableCell(_cellState, appender);
         renderDataCellContents(appender, sw.toString());
         tableRenderer.closeTableCell(appender);
     }

Modified: incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/HeaderCell.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/HeaderCell.java?view=diff&r1=154735&r2=154736
==============================================================================
--- incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/HeaderCell.java (original)
+++ incubator/beehive/trunk/netui/src/tags-databinding/org/apache/beehive/netui/tags/databinding/datagrid/HeaderCell.java Mon Feb 21 15:00:44 2005
@@ -23,7 +23,6 @@
 import javax.servlet.jsp.JspException;
 import javax.servlet.jsp.tagext.JspFragment;
 
-import org.apache.beehive.netui.tags.IAttributeConsumer;
 import org.apache.beehive.netui.tags.IBehaviorConsumer;
 import org.apache.beehive.netui.tags.html.HtmlConstants;
 import org.apache.beehive.netui.tags.html.IFormattable;
@@ -39,7 +38,6 @@
 import org.apache.beehive.netui.databinding.datagrid.runtime.rendering.table.TableRenderer;
 import org.apache.beehive.netui.databinding.datagrid.runtime.util.JspUtil;
 import org.apache.beehive.netui.databinding.datagrid.api.sort.SortModel;
-import org.apache.beehive.netui.util.Bundle;
 
 /**
  * @netui:tag name="headerCell" description="Render an HTML table head cell tag" body-content="scriptless"
@@ -66,7 +64,7 @@
     }
 
     private String _headerText = null;
-    private ThTag.State _thState = new ThTag.State();
+    private ThTag.State _cellState = new ThTag.State();
     private HeaderCellModel _headerCellModel = new HeaderCellModel();
     private CellDecorator _cellDecorator = null;
 
@@ -75,6 +73,16 @@
     }
 
     /**
+     * Sets the text to render for this table header cell.
+     *
+     * @param headerText The text to render.
+     * @netui:attribute required="false" rtexprvalue="true"
+     */
+    public void setHeaderText(String headerText) {
+        _headerText = headerText;
+    }
+
+    /**
      * Sets the scopeId for any anchors rendered by this header cell.
      *
      * @netui:attribute required="false" rtexprvalue="true" description="Optional String scopeId that qualifies URL parameters into a particular scope"
@@ -157,7 +165,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnClick(String onClick) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONCLICK, onClick);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONCLICK, onClick);
     }
 
     /**
@@ -171,7 +179,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnDblClick(String onDblClick) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONDBLCLICK, onDblClick);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONDBLCLICK, onDblClick);
     }
 
     /**
@@ -185,7 +193,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnKeyDown(String onKeyDown) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYDOWN, onKeyDown);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYDOWN, onKeyDown);
     }
 
     /**
@@ -199,7 +207,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnKeyUp(String onKeyUp) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYUP, onKeyUp);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYUP, onKeyUp);
     }
 
     /**
@@ -213,7 +221,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnKeyPress(String onKeyPress) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYPRESS, onKeyPress);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONKEYPRESS, onKeyPress);
     }
 
     /**
@@ -227,7 +235,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseDown(String onMouseDown) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseDown);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseDown);
     }
 
     /**
@@ -241,7 +249,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseUp(String onMouseUp) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseUp);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEDOWN, onMouseUp);
     }
 
     /**
@@ -255,7 +263,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseMove(String onMouseMove) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEMOVE, onMouseMove);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEMOVE, onMouseMove);
     }
 
     /**
@@ -269,7 +277,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseOut(String onMouseOut) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOUT, onMouseOut);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOUT, onMouseOut);
     }
 
     /**
@@ -283,7 +291,7 @@
      * @netui.tldx:attribute propertyclass="workshop.jspdesigner.properties.EventPropertyClass" category="event"
      */
     public void setCellOnMouseOver(String onMouseOver) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOVER, onMouseOver);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_JAVASCRIPT, HtmlConstants.ONMOUSEOVER, onMouseOver);
     }
 
     /**
@@ -299,7 +307,7 @@
     public void setCellStyle(String style) {
         if("".equals(style)) return;
 
-        _thState.style = style;
+        _cellState.style = style;
     }
 
     /**
@@ -315,7 +323,7 @@
     public void setCellStyleClass(String styleClass) {
         if("".equals(styleClass)) return;
 
-        _thState.styleClass = styleClass;
+        _cellState.styleClass = styleClass;
     }
 
     /**
@@ -329,22 +337,182 @@
      * @netui.tldx:attribute category="misc"
      */
     public void setCellTitle(String title) {
-        _thState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.TITLE, title);
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.TITLE, title);
     }
 
     /**
-     * Sets the text to render for this table header cell.
+     * Sets the value of the cell's rowspan attribute.
      *
-     * @param headerText The text to render.
-     * @netui:attribute required="false" rtexprvalue="true"
+     * @param rowSpan
+     * @jsptagref.attributedescription The row span
+     * @jsptagref.databindable false
+     * @jsptagref.attributesyntaxvalue <i>string_rowspan</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The rowspan."
+     * @netui.tldx:attribute category="misc"
      */
-    public void setHeaderText(String headerText) {
-        _headerText = headerText;
+    public void setCellRowspan(int rowSpan) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.ROWSPAN, "" + rowSpan);
+    }
+
+    /**
+     * Sets the value of the cell's colspan attribute.
+     *
+     * @param colSpan
+     * @jsptagref.attributedescription The colspan
+     * @jsptagref.databindable false
+     * @jsptagref.attributesyntaxvalue <i>string_colspan</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The colspan."
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellColspan(int colSpan) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.COLSPAN, "" + colSpan);
+    }
+
+    /**
+     * Sets the value of the horizontal align attribute.
+     *
+     * @param align
+     * @jsptagref.attributedescription The horizontal alignment.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_align</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's horizontal alignment"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellAlign(String align) {
+        /* todo: should this enforce left|center|right|justify|char as in the spec */
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.ALIGN, align);
+    }
+
+    /**
+     * Sets the value of the horizontal alignment character attribute.
+     *
+     * @param alignChar
+     * @jsptagref.attributedescription The horizontal alignment character.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_alignChar</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's horizontal alignment character"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellChar(String alignChar) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.CHAR, alignChar);
+    }
+
+    /**
+     * Sets the value of the horizontal alignment character offset attribute.
+     *
+     * @param alignCharOff
+     * @jsptagref.attributedescription The horizontal alignment character offset
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_alignCharOff</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's horizontal alignment character offset"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellCharoff(String alignCharOff) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.CHAROFF, alignCharOff);
+    }
+
+    /**
+     * Sets the value of the vertical alignment attribute.
+     *
+     * @param align
+     * @jsptagref.attributedescription The vertical alignment.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_align</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's vertical alignment"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellValign(String align) {
+        /* todo: should this enforce top|middle|bottom|baseline as in the spec */
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.VALIGN, align);
+    }
+
+    /**
+     * Sets the value of the languageattribute.
+     *
+     * @param lang
+     * @jsptagref.attributedescription The language.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_lang</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's language"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellLang(String lang) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.LANG, lang);
+    }
+
+    /**
+     * Sets the value of the text direction attribute.
+     *
+     * @param dir
+     * @jsptagref.attributedescription The text direction attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_dir</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The cell's text direction"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellDir(String dir) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.DIR, dir);
+    }
+
+    /**
+     * Sets the value of the abbreviated form of the cell's content.
+     *
+     * @param abbr
+     * @jsptagref.attributedescription The abbreviated form of the cell's content.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_dir</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The abbreviated form of the cell's content"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellAbbr(String abbr) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.ABBR, abbr);
+    }
+
+    /**
+     * Sets the value of the axis attribute.
+     *
+     * @param axis
+     * @jsptagref.attributedescription The axis attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_axis</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The axis attribute"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellAxis(String axis) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.AXIS, axis);
+    }
+
+    /**
+     * Sets the value of the headers attribute.
+     *
+     * @param headers
+     * @jsptagref.attributedescription The headers attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_headers</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The headers attribute"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellHeaders(String headers) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.HEADERS, headers);
+    }
+
+    /**
+     * Sets the value of the scope attribute.
+     *
+     * @param scope
+     * @jsptagref.attributedescription The scope attribute.
+     * @jsptagref.databindable true
+     * @jsptagref.attributesyntaxvalue <i>string_scope</i>
+     * @netui:attribute required="false" rtexprvalue="true" description="The scope attribute"
+     * @netui.tldx:attribute category="misc"
+     */
+    public void setCellScope(String scope) {
+        _cellState.registerAttribute(AbstractHtmlState.ATTR_GENERAL, HtmlConstants.SCOPE, scope);
     }
 
     public void setBehavior(String name, String value, String facet) throws JspException {
         if(facet != null && facet.equals(FACET_HEADER_NAME)) {
-            super.addStateAttribute(_thState, name, value);
+            super.addStateAttribute(_cellState, name, value);
             return;
         }
         else if(facet != null && facet.equals(FACET_RENDERER_NAME)) {
@@ -389,13 +557,13 @@
         if(_headerCellModel.isSortable())
             styleClasses.add(dataGridModel.getStyleModel().getHeaderCellSortableClass());
 
-        if(_thState.styleClass == null)
+        if(_cellState.styleClass == null)
             styleClasses.add(dataGridModel.getStyleModel().getHeaderCellClass());
-        else styleClasses.add(_thState.styleClass);
+        else styleClasses.add(_cellState.styleClass);
 
-        _thState.styleClass = dataGridModel.getStyleModel().buildStyleClassValue(styleClasses);
+        _cellState.styleClass = dataGridModel.getStyleModel().buildStyleClassValue(styleClasses);
 
-        tableRenderer.openHeaderCell(_thState, appender);
+        tableRenderer.openHeaderCell(_cellState, appender);
         renderHeaderCellContents(appender);
         tableRenderer.closeHeaderCell(appender);
     }

Modified: incubator/beehive/trunk/netui/src/tags-html/org/apache/beehive/netui/tags/html/HtmlConstants.java
URL: http://svn.apache.org/viewcvs/incubator/beehive/trunk/netui/src/tags-html/org/apache/beehive/netui/tags/html/HtmlConstants.java?view=diff&r1=154735&r2=154736
==============================================================================
--- incubator/beehive/trunk/netui/src/tags-html/org/apache/beehive/netui/tags/html/HtmlConstants.java (original)
+++ incubator/beehive/trunk/netui/src/tags-html/org/apache/beehive/netui/tags/html/HtmlConstants.java Mon Feb 21 15:00:44 2005
@@ -155,6 +155,12 @@
     static final String CHAROFF = "charoff";
 
     //****************************** Other attribute constants  *********************************
+
+    /**
+     * The name of the <code>abbr</code> attribute.
+     */
+    static final String ABBR = "abbr";
+
     /**
      * The name of the <code>accesskey</code> attribute.
      */
@@ -176,6 +182,11 @@
     static final String ALT = "alt";
 
     /**
+     * The name of the <code>axis</code> attribute.
+     */
+    static final String AXIS = "axis";
+
+    /**
      * The name of the <code>background</code> attribute.
      */
     static final String BACKGROUND = "background";
@@ -216,6 +227,11 @@
     static final String COLS = "cols";
 
     /**
+     * The name of the <code>colspan</code> attribute.
+     */
+    static final String COLSPAN = "colspan";
+
+    /**
      * The name of the <code>coords</code> attribute.
      */
     static final String COORDS = "coords";
@@ -241,6 +257,11 @@
     static final String FRAME = "frame";
 
     /**
+     * The name of the <code>headers</code> attribute.
+     */
+    static final String HEADERS = "headers";
+
+    /**
      * The name of the <code>height</code> attribute.
      */
     static final String HEIGHT = "height";
@@ -336,11 +357,21 @@
     static final String ROWS = "rows";
 
     /**
+     * The name of the <rows>rowspan</code> attribute.
+     */
+    static final String ROWSPAN = "rowspan";
+
+    /**
      * The name of the <code>rules</code> attribute.
      */
     static final String RULES = "rules";
 
     /**
+     * The name of the <code>scope</code> attribute.
+     */
+    static final String SCOPE = "scope";
+    
+    /**
      * The name of the <code>shape</code> attribute.
      */
     static final String SHAPE = "shape";
@@ -553,7 +584,7 @@
      * The name of the <code>tbody</code> element.
      */
     static final String TBODY = "tbody";
-    
+
     /**
      * The name of the <code>td</code> element.
      */