public class GHMargin extends JPanel
JComponent.AccessibleJComponentComponent.BaselineResizeBehaviorTOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWBOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH| Constructor and Description |
|---|
GHMargin(GHPanel w,
String wname)
Main class to create global margin
|
| Modifier and Type | Method and Description |
|---|---|
void |
disposeMe()
Dispose this canvas
|
Color |
getGBackground()
Get the color of background
|
Color |
getGColor()
Get the color of this panel
|
Font |
getGFont()
Get the font of the text
|
JPanel |
getJPanel()
Return JPanel of this margin
|
Color |
getMColor()
Get the text color
|
Font |
getMFont()
Get the font on this panel
|
int |
getRotation()
Get the rotation angle of the text in degrees.
|
int |
getSizeX()
Get the size of this margin panel in X
|
int |
getSizeY()
Get the size of this margin in Y
|
String |
getString()
Get the title of this panel
|
double |
getStringPositionX()
Get the text position in X relative to widths
|
double |
getStringPositionY()
Get the text position in Y relative to
the frame height.
|
boolean |
isBorder()
Is boarder shown?
|
void |
setDefault()
Set the default location
|
void |
setDefault(Object com)
Set the default location
|
void |
setGBackground(Color c)
Set the background of this panel
|
void |
setGColor(Color c)
Set the color on this panel.
|
void |
setGFont(Font f)
Set the font.
|
void |
setGRecBackground(Color c)
Set the background for rectangle with the text
|
void |
setRotation(int rotation)
Set the rotation angle of the text in degrees.
|
void |
setSizeMargin(int x,
int y)
Set size of this margin panel
|
void |
setString(String sname)
Set the text on this panel
|
void |
setString(String sname,
Font f,
Color c) |
void |
setString(String sname,
Font f,
Color c,
Dimension dd)
Sets the string.
|
void |
setStringPositionX(double x)
Set the text position in X relative to the frame width
|
void |
setStringPositionY(double y)
Set the text position in Y relative to the frame
height.
|
void |
showBorder(boolean show)
Show or not the blue borders during editing.
|
void |
showBorderNoUpdate(boolean show)
Show or not the blue borders during editing.
|
getAccessibleContext, getUI, getUIClassID, setUI, updateUIaddAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, 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, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateadd, add, add, add, add, addContainerListener, 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, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validateaction, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, 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, 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, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCyclepublic void setDefault()
public void setDefault(Object com)
public void disposeMe()
public void setRotation(int rotation)
rotation - Rotation of the text (0, -90, 90)public int getRotation()
public void setString(String sname, Font f, Color c, Dimension dd)
sname - Text of the stringf - Font usedc - Color usedpublic void setGFont(Font f)
f - Fontpublic void setGColor(Color c)
c - Color of the panelpublic Color getGColor()
public Font getGFont()
public Color getGBackground()
public String getString()
public void showBorder(boolean show)
show - true if shownpublic boolean isBorder()
public void showBorderNoUpdate(boolean show)
show - true if shownpublic void setString(String sname)
sname - Textpublic Font getMFont()
public Color getMColor()
public void setGBackground(Color c)
c - Color of this panelpublic void setGRecBackground(Color c)
c - Color of the rectanglepublic JPanel getJPanel()
public void setSizeMargin(int x,
int y)
x - size in Xy - size in Ypublic int getSizeX()
public int getSizeY()
public double getStringPositionX()
public double getStringPositionY()
public void setStringPositionX(double x)
x - position of text in X (from 0 to 1)public void setStringPositionY(double y)
y - position of text in Y (from 0 to 1)Jas4pp 1.5 © Java Analysis Studio for Particle Physics