com.arsdigita.bebop
Class BlockStylable

java.lang.Object
  extended bycom.arsdigita.bebop.Completable
      extended bycom.arsdigita.bebop.SimpleComponent
          extended bycom.arsdigita.bebop.TextStylable
              extended bycom.arsdigita.bebop.BlockStylable
All Implemented Interfaces:
Cloneable, Component, Lockable
Direct Known Subclasses:
Image, Label, Option, Page, SimpleContainer, Table, Widget

public abstract class BlockStylable
extends TextStylable

Abstract class that contain the CSS-like Block Stylable attributes.

Version:
$Id: //core-platform/dev/src/com/arsdigita/bebop/BlockStylable.java#11 $
Author:
Jim Parsons, Justin Ross

Field Summary
static int ABSBOTTOM
          Constant for specifying ABSBOTTOM alignment of this image input.
static int ABSMIDDLE
          Constant for specifying ABSMIDDLE alignment of this image input.
static int BASELINE
          Constant for specifying BASELINE alignment of this image input.
static int BOTTOM
          Align the bottom of a component.
static int CENTER
          Center a component.
static int FULL_WIDTH
          Lay out a component across the full width of the panel.
static int INSERT
          Insert the child component assuming it is printed in a table with the same number of columns.
static int LEFT
          Left-align a component.
static int MIDDLE
          Align the middle of a component.
static int RIGHT
          Right-align a component.
static int TEXTTOP
          Constant for specifying TEXTOP alignment of this image input.
static int TOP
          Align the top of a component.
static String versionId
           
 
Fields inherited from class com.arsdigita.bebop.SimpleComponent
m_attr
 
Fields inherited from interface com.arsdigita.bebop.Component
BEBOP_XML_NS, CLASS, ID, ON_CLICK, STYLE
 
Constructor Summary
BlockStylable()
           
 
Method Summary
 void setBorder(Size size)
          Sets this component's border.
 void setBorder(Size size, int sideEnum)
          Sets the border size for one side of this component.
 void setBorderColor(Color borderColor)
          Sets the color of this component's border.
 void setHorizontalAlignment(int alignmentEnum)
          Sets the horizontal alignment of this component.
 void setMargin(Size size)
          Sets this component's margin.
 void setMargin(Size size, int sideEnum)
          Sets the margin of one of this component's sides.
 void setPadding(Size size)
          Sets this component's padding.
 void setPadding(Size size, int sideEnum)
          Sets the padding of one of this component's sides.
 void setVerticalAlignment(int alignmentEnum)
          Sets the vertical alignment of this component.
 
Methods inherited from class com.arsdigita.bebop.TextStylable
setBackgroundColor, setColor
 
Methods inherited from class com.arsdigita.bebop.SimpleComponent
children, clone, exportAttributes, generateXML, getAttribute, getClassAttr, getIdAttr, getKey, getMetaDataAttribute, getStyleAttr, hasAttributes, isLocked, isVisible, lock, register, register, respond, setAttribute, setClassAttr, setIdAttr, setKey, setMetaDataAttribute, setStyleAttr, setVisible
 
Methods inherited from class com.arsdigita.bebop.Completable
addCompletionListener, fireCompletionEvent
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

versionId

public static final String versionId
See Also:
Constant Field Values

LEFT

public static final int LEFT
Left-align a component.

See Also:
Constant Field Values

CENTER

public static final int CENTER
Center a component.

See Also:
Constant Field Values

RIGHT

public static final int RIGHT
Right-align a component.

See Also:
Constant Field Values

TOP

public static final int TOP
Align the top of a component.

See Also:
Constant Field Values

MIDDLE

public static final int MIDDLE
Align the middle of a component.

See Also:
Constant Field Values

BOTTOM

public static final int BOTTOM
Align the bottom of a component.

See Also:
Constant Field Values

FULL_WIDTH

public static final int FULL_WIDTH
Lay out a component across the full width of the panel.

See Also:
Constant Field Values

INSERT

public static final int INSERT
Insert the child component assuming it is printed in a table with the same number of columns.

See Also:
Constant Field Values

ABSMIDDLE

public static final int ABSMIDDLE
Constant for specifying ABSMIDDLE alignment of this image input. See the W3C HTML 4.01 Specification for a description of this attribute.

See Also:
Constant Field Values

ABSBOTTOM

public static final int ABSBOTTOM
Constant for specifying ABSBOTTOM alignment of this image input. See the W3C HTML 4.01 Specification for a description of this attribute.

See Also:
Constant Field Values

TEXTTOP

public static final int TEXTTOP
Constant for specifying TEXTOP alignment of this image input. (See the W3C HTML 4.01 Specification for a description of this attribute.)

See Also:
Constant Field Values

BASELINE

public static final int BASELINE
Constant for specifying BASELINE alignment of this image input. (See the W3C HTML 4.01 Specification for a description of this attribute.)

See Also:
Constant Field Values
Constructor Detail

BlockStylable

public BlockStylable()
Method Detail

setPadding

public void setPadding(Size size)
Sets this component's padding.

Parameters:
size - the size for this component's padding
See Also:
setPadding(Size, int)

setPadding

public void setPadding(Size size,
                       int sideEnum)
Sets the padding of one of this component's sides.

Parameters:
sideEnum - the side to set
size - the size to set the padding to
See Also:
setPadding(Size)

setBorder

public void setBorder(Size size)
Sets this component's border.

Parameters:
size - the size to set for this component's border
See Also:
setBorder(Size, int)

setBorder

public void setBorder(Size size,
                      int sideEnum)
Sets the border size for one side of this component.

Parameters:
size - the size to set for the border
sideEnum - the side to set
See Also:
setBorder(Size)

setBorderColor

public void setBorderColor(Color borderColor)
Sets the color of this component's border.

Parameters:
borderColor - the color for the border

setMargin

public void setMargin(Size size)
Sets this component's margin.

Parameters:
size - the size to set this component's margin to
See Also:
setMargin(Size, int)

setMargin

public void setMargin(Size size,
                      int sideEnum)
Sets the margin of one of this component's sides.

Parameters:
size - the size to set the margin to
sideEnum - the side to set
See Also:
setMargin(Size)

setHorizontalAlignment

public void setHorizontalAlignment(int alignmentEnum)
Sets the horizontal alignment of this component.

Parameters:
alignmentEnum - the horizontal alignment (LEFT, RIGHT, or CENTER)

setVerticalAlignment

public void setVerticalAlignment(int alignmentEnum)
Sets the vertical alignment of this component.

Parameters:
alignmentEnum - the vertical alignment (TOP, BOTTOM, or MIDDLE)


Copyright (c) 2004 Red Hat, Inc. Corporation. All Rights Reserved. Generated at July 21 2004:2337 UTC