|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.acm.seguin.uml.line.ScalablePanel
org.acm.seguin.uml.line.EndPointPanel
org.acm.seguin.uml.UMLLine
public class UMLLine
Displays a single UML line
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
javax.swing.JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
javax.swing.JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
java.awt.Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected static java.awt.Font |
abstractFont
Description of the Field |
protected static java.awt.Font |
abstractTitleFont
Description of the Field |
static int |
DEFAULT
Description of the Field |
protected static java.awt.Font |
defaultFont
Description of the Field |
protected int |
high
Description of the Field |
protected UMLIcon |
icon
Stores the icon for this object |
protected static int |
iconMargin
Description of the Field |
protected SizableLabel |
label
Description of the Field |
protected static int |
labelMargin
Description of the Field |
static int |
PRIVATE
Description of the Field |
static int |
PROTECTED
Description of the Field |
static int |
PROTECTED_PRIVATE
Description of the Field |
protected static java.awt.Color[] |
protectionColors
Description of the Field |
static int |
PUBLIC
Description of the Field |
protected static java.awt.Font |
staticFont
Description of the Field |
protected static java.awt.Font |
titleFont
Description of the Field |
protected int |
wide
Description of the Field |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
UMLLine(UMLType parent,
DragPanelAdapter adapter)
Create a new instance of a UMLLine |
Method Summary | |
---|---|
void |
addMouseListener(java.awt.event.MouseListener listener)
Add a mouse listener |
void |
addMouseMotionListener(java.awt.event.MouseMotionListener listener)
Add a mouse listener |
protected void |
drawIcon(java.awt.Graphics g,
int x,
int y)
Draws the icon |
protected java.awt.Color |
getDefaultBackground()
Return the default background color |
java.awt.Dimension |
getMinimumSize()
Returns the minimum size |
UMLType |
getParentType()
Gets the ParentType attribute of the UMLLine object |
java.awt.Dimension |
getPreferredSize()
Returns the preferred size |
protected static int |
getProtectionCode(net.sourceforge.jrefactory.ast.ModifierHolder modifiers)
Add the protection information for this field or method |
protected static java.awt.Color |
getProtectionColor(int level)
Get the color associated with a level of protection |
protected static java.awt.Font |
getProtectionFont(boolean title,
net.sourceforge.jrefactory.ast.ModifierHolder modifiers)
Get the font appropriate for the level of protection |
boolean |
isSelected()
Gets the Selected attribute of the UMLLine object |
void |
paint(java.awt.Graphics g)
Paint this object |
void |
print(java.awt.Graphics g,
int x,
int y)
Print this object |
void |
removeMouseListener(java.awt.event.MouseListener listener)
Remove a mouse listener |
void |
removeMouseMotionListener(java.awt.event.MouseMotionListener listener)
Remove a mouse listener |
void |
scale(double value)
Sets the scaling factor |
void |
setLabelFont(java.awt.Font font)
Set the font |
void |
setLabelText(java.lang.String msg)
Set the text |
void |
setProtection(int code)
Set the protection code |
void |
setSelected(boolean value)
Sets the Selected attribute of the UMLLine object |
Methods inherited from class org.acm.seguin.uml.line.ScalablePanel |
---|
getScale, getUnscaledBounds, getUnscaledLocation, move, reshape, resize, resize, scaleInteger, setBounds, setBounds, setLocation, setLocation, setSize, setSize, shift, unscaleInteger |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class javax.swing.JComponent |
---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update |
Methods inherited from class java.awt.Container |
---|
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree |
Methods inherited from class java.awt.Component |
---|
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setName, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected SizableLabel label
protected int wide
protected int high
protected UMLIcon icon
public static final int PUBLIC
public static final int PROTECTED_PRIVATE
public static final int PROTECTED
public static final int DEFAULT
public static final int PRIVATE
protected static java.awt.Color[] protectionColors
protected static java.awt.Font defaultFont
protected static java.awt.Font staticFont
protected static java.awt.Font abstractFont
protected static java.awt.Font titleFont
protected static java.awt.Font abstractTitleFont
protected static final int iconMargin
protected static final int labelMargin
Constructor Detail |
---|
public UMLLine(UMLType parent, DragPanelAdapter adapter)
parent
- Description of Parameteradapter
- Description of ParameterMethod Detail |
---|
public void setProtection(int code)
code
- the codepublic void setLabelText(java.lang.String msg)
msg
- the messagepublic void setLabelFont(java.awt.Font font)
font
- the new fontpublic void setSelected(boolean value)
setSelected
in class EndPointPanel
value
- The new Selected valuepublic java.awt.Dimension getMinimumSize()
getMinimumSize
in class javax.swing.JComponent
public java.awt.Dimension getPreferredSize()
getPreferredSize
in class javax.swing.JComponent
public UMLType getParentType()
public boolean isSelected()
isSelected
in class EndPointPanel
public void paint(java.awt.Graphics g)
paint
in class javax.swing.JComponent
g
- the graphics objectpublic void print(java.awt.Graphics g, int x, int y)
g
- the graphics objectx
- the x coordinatey
- the y coordinatepublic void addMouseListener(java.awt.event.MouseListener listener)
addMouseListener
in class java.awt.Component
listener
- the new listenerpublic void removeMouseListener(java.awt.event.MouseListener listener)
removeMouseListener
in class java.awt.Component
listener
- the new listenerpublic void addMouseMotionListener(java.awt.event.MouseMotionListener listener)
addMouseMotionListener
in class java.awt.Component
listener
- the new listenerpublic void removeMouseMotionListener(java.awt.event.MouseMotionListener listener)
removeMouseMotionListener
in class java.awt.Component
listener
- the new listenerpublic void scale(double value)
scale
in class ScalablePanel
value
- scaling factorprotected java.awt.Color getDefaultBackground()
protected void drawIcon(java.awt.Graphics g, int x, int y)
g
- the graphics objectx
- Description of Parametery
- Description of Parameterprotected static int getProtectionCode(net.sourceforge.jrefactory.ast.ModifierHolder modifiers)
modifiers
- the modifier information
protected static java.awt.Font getProtectionFont(boolean title, net.sourceforge.jrefactory.ast.ModifierHolder modifiers)
title
- is this a titlemodifiers
- the modifiers
protected static java.awt.Color getProtectionColor(int level)
level
- the level that we need to know
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |