objectivehtml.htmlwidget
Class HtmlTableRow

java.lang.Object
  |
  +--objectivehtml.oms.OMSObject
        |
        +--objectivehtml.htmlwidget.HtmlElement
              |
              +--objectivehtml.htmlwidget.HtmlWidget
                    |
                    +--objectivehtml.htmlwidget.HtmlContainerWidget
                          |
                          +--objectivehtml.htmlwidget.HtmlTableRow

public class HtmlTableRow
extends HtmlContainerWidget

This class represents a html table row. i.e.

<tr ...>

This object can only exist inside a HtmlTable object.

See Also:
HtmlTable

Fields inherited from class objectivehtml.htmlwidget.HtmlContainerWidget
m_alChildrenWidgets, m_bAutoEscape, m_sText
 
Fields inherited from class objectivehtml.htmlwidget.HtmlWidget
m_bDestroyed, m_bVisible, m_objHtmlForm, m_objParentWidget
 
Fields inherited from class objectivehtml.htmlwidget.HtmlElement
m_hmAttributes, m_sEndTag, m_sQuoteType, m_sStartTag
 
Constructor Summary
protected HtmlTableRow(HtmlTable objParent, int nColumns)
          Constructs an instance of HtmlTableRow with the nColumns columns.
 
Method Summary
protected  void appendTableCell()
          Adds a new table cell to this table row.
 java.lang.String getAlign()
          Returns the alignment style of this object.
 java.lang.String getBgColor()
          Returns the background color of this object.
 HtmlTableCell getTableCell(int nCol)
          Returns the HtmlTableCell object for the specified table cell.
 java.lang.String getVAlign()
          Returns the vertical alignment style of this object.
protected  void isValidChildWidget(HtmlWidget objHtmlWidget)
          Overrides the default version, so that only HtmlTableCell objects can be added to this object.
 void setAlign(java.lang.String sAlign)
          Sets the alignment style of this object.
 void setBgColor(java.lang.String sBgColor)
          Sets the background color of this object.
 void setVAlign(java.lang.String sVAlign)
          Sets the vertical alignment style of this object.
 
Methods inherited from class objectivehtml.htmlwidget.HtmlContainerWidget
addHtmlWidget, appendChild, destroy, generateUpdateOrder, getChildrenCount, getChildrenWidgets, getChildWidget, getText, indexOfChildWidget, insertChild, insertHtmlWidget, isAutoEscape, isChildWidget, printHtml, printHtml, removeHtmlWidget, setAttribute, setAutoEscape, setBooleanAttribute, setText, setVisible, swapHtmlWidgets
 
Methods inherited from class objectivehtml.htmlwidget.HtmlWidget
changeParent, changeParent, getClassAttribute, getHtmlForm, getID, getOnClick, getOnDblClick, getOnKeyDown, getOnKeyPress, getOnKeyUp, getOnMouseDown, getOnMouseMove, getOnMouseOut, getOnMouseOver, getOnMouseUp, getParent, getStyle, isDestroyed, isVisible, setClassAttribute, setID, setOnClick, setOnDblClick, setOnKeyDown, setOnKeyPress, setOnKeyUp, setOnMouseDown, setOnMouseMove, setOnMouseOut, setOnMouseOver, setOnMouseUp, setStyle
 
Methods inherited from class objectivehtml.htmlwidget.HtmlElement
genEndTag, genStartTag, genStartTag, getAttribute, getAttributes, getBooleanAttribute, getQuoteType, printHtml, printHtml, printHtml, printHtml, printHtml, printHtml, setAttribute, setBooleanAttribute, setQuoteType, toString, toString
 
Methods inherited from class objectivehtml.oms.OMSObject
compareClasses, connect, disconnect, emit, isAlive, setAlive, signal, slot, slot
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

HtmlTableRow

protected HtmlTableRow(HtmlTable objParent,
                       int nColumns)
                throws InvalidParentWidgetException,
                       InvalidChildWidgetException
Constructs an instance of HtmlTableRow with the nColumns columns. The only valid parent is a HtmlTableRow.
Parameters:
objParent - the parent for this widget
nColumns - the columns to table row is initially created with
Throws:
InvalidParentWidgetException - if the specified parent widget is not valid
InvalidChildWidgetException - if the parent widget does not accept this widget as a child
Method Detail

appendTableCell

protected void appendTableCell()
Adds a new table cell to this table row.

getTableCell

public HtmlTableCell getTableCell(int nCol)
Returns the HtmlTableCell object for the specified table cell.
Parameters:
nCol - the col index
Returns:
the HtmlTableCell object at the specified col index nCol

getAlign

public java.lang.String getAlign()
Returns the alignment style of this object.
Returns:
the alignment style of this object
See Also:
setAlign(String)

setAlign

public void setAlign(java.lang.String sAlign)

Sets the alignment style of this object. Suitable values are "left", "center", "right", "justify" and "char".

The html attribute it sets is "align".

If null is specified the attribute is cleared.

Parameters:
sAlign - the alignment style for this widget, if null is specified then this attribute will be cleared
See Also:
getAlign()

getVAlign

public java.lang.String getVAlign()
Returns the vertical alignment style of this object.
Returns:
the vertical alignment style of this object
See Also:
setVAlign(String)

setVAlign

public void setVAlign(java.lang.String sVAlign)

Sets the vertical alignment style of this object. Suitable values are "top", "middle", "bottom" and "baseline".

The html attribute it sets is "valign".

If null is specified the attribute is cleared.

Parameters:
sVAlign - the vertical alignment style for this widget, if null is specified then this attribute will be cleared
See Also:
getVAlign()

getBgColor

public java.lang.String getBgColor()
Returns the background color of this object.
Returns:
the background color of this object
See Also:
setBgColor(String)

setBgColor

public void setBgColor(java.lang.String sBgColor)

Sets the background color of this object. There 16 preset values "black", "silver", "gray", "white", "maroon", "red", "purple", "fushcia", "green", "lime", "olive", "yellow", "navy", "blue", "teal" and "navy". For all other colors you can specify the color in the format SRGB, i.e. #RRGGBB.

The html attribute it sets is "bgcolor".

If null is specified the attribute is cleared.

Parameters:
sBgColor - the background color for this widget, if null is specified then this attribute will be cleared
See Also:
getBgColor()

isValidChildWidget

protected void isValidChildWidget(HtmlWidget objHtmlWidget)
                           throws InvalidChildWidgetException
Overrides the default version, so that only HtmlTableCell objects can be added to this object.
Overrides:
isValidChildWidget in class HtmlContainerWidget
Parameters:
objHtmlWidget - the widget to test
Throws:
InvalidChildWidgetException - if the widget is not a HtmlTableCell object