All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.sgi.sysadm.ui.LabelComponentPanel

java.lang.Object
   |
   +----java.awt.Component
           |
           +----java.awt.Container
                   |
                   +----javax.swing.JComponent
                           |
                           +----javax.swing.JPanel
                                   |
                                   +----com.sgi.sysadm.ui.RPanel
                                           |
                                           +----com.sgi.sysadm.ui.LabelComponentPanel

public class LabelComponentPanel
extends RPanel
A Panel for laying out labels and Components is one and two columns. The layout of the Components is controlled with resources. All of the resources have three forms. The prefix is one of:
  1. component name - This is the name of the Component, as passed to the addComponent method.
  2. component's class name - The package qualified name of the Component that was passed tothe addComponent method.
  3. "LabelComponentPanel" - The liternal string "LabelComponentPanel".
The resources are looked up, in order, until one is found. The defaults for the third case ("LabelComponentPanel") are in SysadmUIP.properties.


Variable Index

 o BOTTOM
A resource <component name | component's class name | "LabelComponentPanel">.attachBottom determines whether the bottom-most component in the layout is stretched to touch the bottom of the panel.
 o BOTTOM_GAP
A resource <component name | component's class name | "LabelComponentPanel">.bottomGap determines the vertical gap (in points) between one component and the next.
 o GROUP
A resource <component name | component's class name | "LabelComponentPanel">.group determines the group of horizontally laid out components that this component belongs to.
 o HGAP
A resource <component name | component's class name | "LabelComponentPanel">.hgap determines the horizontal gap (in points) between the label and the component when the LAYOUT_TYPE is "horizontal"
 o LABEL_JUSTIFICATION
A resource <component name | component's class name | "LabelComponentPanel">.labelJustification determines the justification for the label.
 o LAYOUT_TYPE
A resource <component name | component's class name | "LabelComponentPanel">.layoutType determines what type of layout the component will have.
 o RIGHT_ATTACHMENT
A resource <component name | component's class name | "LabelComponentPanel">.rightAttachment determines the type of attachment to give a component.
 o VGAP
A resource <component name | component's class name | "LabelComponentPanel">.vgap determines the vertical gap (in points) between the label and the component when the LAYOUT_TYPE is "vertical"

Constructor Index

 o LabelComponentPanel(ResourceStack)
Create a LabelComponentPanel

Method Index

 o addComponent(Component, String)
Adds a component and a LinkLabel to a page.
 o addComponent(Component, String, Component)
Adds a component and a label to the page.
 o removeComponent(Component)
Removes a component and any label associated with it.

Variables

 o LAYOUT_TYPE
 public static final String LAYOUT_TYPE
A resource <component name | component's class name | "LabelComponentPanel">.layoutType determines what type of layout the component will have. The choices are "horizontal" or "vertical"

See Also:
layoutType
 o VGAP
 public static final String VGAP
A resource <component name | component's class name | "LabelComponentPanel">.vgap determines the vertical gap (in points) between the label and the component when the LAYOUT_TYPE is "vertical"

See Also:
vgap
 o HGAP
 public static final String HGAP
A resource <component name | component's class name | "LabelComponentPanel">.hgap determines the horizontal gap (in points) between the label and the component when the LAYOUT_TYPE is "horizontal"

See Also:
hgap
 o BOTTOM_GAP
 public static final String BOTTOM_GAP
A resource <component name | component's class name | "LabelComponentPanel">.bottomGap determines the vertical gap (in points) between one component and the next. It is ignored for the bottom most component.

See Also:
bottomGap
 o RIGHT_ATTACHMENT
 public static final String RIGHT_ATTACHMENT
A resource <component name | component's class name | "LabelComponentPanel">.rightAttachment determines the type of attachment to give a component. The choices are "default", "always" or "never"

See Also:
rightAttachment
 o GROUP
 public static final String GROUP
A resource <component name | component's class name | "LabelComponentPanel">.group determines the group of horizontally laid out components that this component belongs to. The members of a group will have the left edges of their components aligned.

See Also:
group
 o LABEL_JUSTIFICATION
 public static final String LABEL_JUSTIFICATION
A resource <component name | component's class name | "LabelComponentPanel">.labelJustification determines the justification for the label. The choices are "left" and "right"

See Also:
labelJustification
 o BOTTOM
 public static final String BOTTOM
A resource <component name | component's class name | "LabelComponentPanel">.attachBottom determines whether the bottom-most component in the layout is stretched to touch the bottom of the panel.

See Also:
attachBottom

Constructors

 o LabelComponentPanel
 public LabelComponentPanel(ResourceStack rs)
Create a LabelComponentPanel

Parameters:
rs - The ResourceStack to use to lookup resources.

Methods

 o addComponent
 public void addComponent(Component component,
                          String name)
Adds a component and a LinkLabel to a page. The LinkLabel and the component will share name as their name. The new component and label will appear beneath any previously added components.

Parameters:
component - The component to add
label - The label that describes this component
 o addComponent
 public void addComponent(Component component,
                          String name,
                          Component label)
Adds a component and a label to the page. The component and label will appear beneath any previously added components.

Parameters:
component - The component to add
name - The name of the component. Will be used in resource lookups.
label - The label that describes this component
 o removeComponent
 public void removeComponent(Component component)
Removes a component and any label associated with it.

Parameters:
component - The component to remove

All Packages  Class Hierarchy  This Package  Previous  Next  Index