japlot.jaxodraw
Class JaxoOptionsPanel
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- javax.swing.JComponent
-
- javax.swing.JPanel
-
- japlot.jaxodraw.JaxoOptionsPanel
-
- All Implemented Interfaces:
- java.awt.event.ActionListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible
- Direct Known Subclasses:
- JaxoLineOptionsPanel
public abstract class JaxoOptionsPanel extends javax.swing.JPanel implements java.awt.event.ActionListenerA panel to change the parameters of a line object.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Field Summary
-
Fields inherited from class javax.swing.JComponent
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
-
-
Constructor Summary
Constructors Constructor and Description JaxoOptionsPanel()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method and Description voidactionPerformed(java.awt.event.ActionEvent evt)Checks for ActionEvents that have ocurred on the panel, presently only whether the color button has been pressed in which case a new color chooser panel is popped up.voidaddColorPanel(int gridx, int gridy)Adds the color panel to this OptionPanel.voidaddFinalDimSPanel(int gridx, int gridy)Adds the position panel to this OptionPanel.java.awt.ColorgetColor()Returns the new color.java.awt.GridBagConstraintsgetGBConstraints()Returns the GridBagConstraints of this option panel.java.awt.GridBagLayoutgetGBLayout()Returns the GridBagLayout of this option panel.java.awt.InsetsgetInsets()Returns the current insets of this option panel.javax.swing.IcongetPanelIcon()Returns the icon for this option panel.java.lang.StringgetPanelTitle()Returns the current title of this option panel.intgetXfin()Returns the new Xfin.intgetXin()Returns the new Xin.intgetYfin()Returns the new Yfin.intgetYin()Returns the new Yin.voidsetColor(java.awt.Color color)Sets the newColor property.voidsetGBConstraints(int gx, int gy)Sets the GridBagConstraints and insets.voidsetGBLayout(javax.swing.JPanel panel)Applies the current GridBagConstraints to the specified JPanel.voidsetInsets(int top, int left, int bottom, int right)Sets the insets for this option panel.voidsetPanelIcon(java.lang.String icon)Sets the icon for this option panel.voidsetPanelTitle(java.lang.String title)Sets the title for this option panel.voidsetXYLineCoord(int x, int y, int relw, int relh)Sets the Xin, Xfin, Yin and Yfin coordinates.abstract booleanshowPanel()An abstract method that displays the EditPanel.-
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, setUI, updateUI
-
Methods inherited from class javax.swing.JComponent
addAncestorListener, 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, 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, update
-
Methods inherited from class java.awt.Container
add, 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, validate
-
Methods inherited from class java.awt.Component
action, 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, transferFocusUpCycle
-
-
-
-
Method Detail
-
actionPerformed
public final void actionPerformed(java.awt.event.ActionEvent evt)
Checks for ActionEvents that have ocurred on the panel, presently only whether the color button has been pressed in which case a new color chooser panel is popped up.- Specified by:
actionPerformedin interfacejava.awt.event.ActionListener- Parameters:
evt- The ActionEvent that has ocurred.
-
setPanelIcon
public final void setPanelIcon(java.lang.String icon)
Sets the icon for this option panel.- Parameters:
icon- A string with the path to the icon file.
-
getPanelIcon
public final javax.swing.Icon getPanelIcon()
Returns the icon for this option panel.- Returns:
- The current icon of this option panel.
-
setPanelTitle
public final void setPanelTitle(java.lang.String title)
Sets the title for this option panel.- Parameters:
title- A string with the panel title (this string gets internationalized here, so make sure it is in the properties files).
-
getPanelTitle
public final java.lang.String getPanelTitle()
Returns the current title of this option panel.- Returns:
- The current title of this option panel.
-
setInsets
public final void setInsets(int top, int left, int bottom, int right)Sets the insets for this option panel.- Parameters:
top- The top inset.left- The left inset.bottom- The bottom inset.right- The right inset.
-
setColor
public final void setColor(java.awt.Color color)
Sets the newColor property.- Parameters:
color- The new color.
-
getGBLayout
public final java.awt.GridBagLayout getGBLayout()
Returns the GridBagLayout of this option panel.- Returns:
- The GridBagLayout of this option panel.
-
setGBLayout
public final void setGBLayout(javax.swing.JPanel panel)
Applies the current GridBagConstraints to the specified JPanel.- Parameters:
panel- The panel to apply the layout to.
-
getGBConstraints
public final java.awt.GridBagConstraints getGBConstraints()
Returns the GridBagConstraints of this option panel.- Returns:
- The GridBagConstraints of this option panel.
-
setGBConstraints
public final void setGBConstraints(int gx, int gy)Sets the GridBagConstraints and insets.- Parameters:
gx- The x coordinate of the GridBagConstraint.gy- The y coordinate of the GridBagConstraint.
-
getInsets
public final java.awt.Insets getInsets()
Returns the current insets of this option panel.- Overrides:
getInsetsin classjavax.swing.JComponent- Returns:
- The current insets of this option panel.
-
getColor
public final java.awt.Color getColor()
Returns the new color.- Returns:
- The new color.
-
getXin
public final int getXin()
Returns the new Xin.- Returns:
- The new Xin.
-
getXfin
public final int getXfin()
Returns the new Xfin.- Returns:
- The new Xfin.
-
getYin
public final int getYin()
Returns the new Yin.- Returns:
- The new Yin.
-
getYfin
public final int getYfin()
Returns the new Yfin.- Returns:
- The new Yfin.
-
setXYLineCoord
public final void setXYLineCoord(int x, int y, int relw, int relh)Sets the Xin, Xfin, Yin and Yfin coordinates.- Parameters:
x- The x coordinate.y- The y coordinate.relw- The relative width.relh- The relative height.
-
addColorPanel
public final void addColorPanel(int gridx, int gridy)Adds the color panel to this OptionPanel.- Parameters:
gridx- The x position of the color panel.gridy- The y position of the color panel.
-
addFinalDimSPanel
public final void addFinalDimSPanel(int gridx, int gridy)Adds the position panel to this OptionPanel.- Parameters:
gridx- The x position of the color panel.gridy- The y position of the color panel.
-
showPanel
public abstract boolean showPanel()
An abstract method that displays the EditPanel.- Returns:
- A boolean variable that indicates if the object has been modified.
-
-
DMelt 3.0 © DataMelt by jWork.ORG