jfig.gui
Class JEditBaseobjectDialog

java.lang.Object
  extended byjava.awt.Component
      extended byjava.awt.Container
          extended byjava.awt.Window
              extended byjava.awt.Dialog
                  extended byjavax.swing.JDialog
                      extended byjfig.gui.JEditBaseobjectDialog
All Implemented Interfaces:
javax.accessibility.Accessible, java.awt.event.ActionListener, java.util.EventListener, java.awt.image.ImageObserver, java.awt.event.KeyListener, java.awt.MenuContainer, javax.swing.RootPaneContainer, java.io.Serializable, javax.swing.WindowConstants, java.awt.event.WindowListener
Direct Known Subclasses:
JEditCompoundDialog, JEditEllipseDialog, JEditImageDialog, JEditPolylineDialog, JEditRectangleDialog, JEditTextDialog, JEditTriggerDialog, JEditXSplineDialog

public class JEditBaseobjectDialog
extends javax.swing.JDialog
implements java.awt.event.ActionListener, java.awt.event.KeyListener, java.awt.event.WindowListener

dialog to edit a FigObject and its attributes.

JEditBaseobjectDialog: a dialog window to specify all global properties/attributes of the jfig editor. Editable attributes include line style, width, color, fill style, pattern, color, arrow mode and style, length, and width, object layer (depth), and all text attributes.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class javax.swing.JDialog
javax.swing.JDialog.AccessibleJDialog
 
Nested classes inherited from class java.awt.Dialog
java.awt.Dialog.AccessibleAWTDialog
 
Nested classes inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Nested classes inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
protected  JAttribsControlsFactory AC
           
protected  javax.swing.JButton applyButton
           
protected  javax.swing.JLabel arrowBLabel
           
protected  javax.swing.JLabel arrowFLabel
           
protected  JStateButton arrowModeButton
           
protected  javax.swing.JLabel arrowModeLabel
           
protected  JStateButton arrowStyleButton
           
protected  javax.swing.JLabel arrowStyleLabel
           
protected  javax.swing.JTextField b_arrowLengthField
           
protected  javax.swing.JTextField b_arrowThicknessField
           
protected  javax.swing.JTextField b_arrowWidthField
           
protected  java.awt.Color backgroundColor
           
protected  javax.swing.JButton cancelButton
           
protected  javax.swing.JComboBox centerFlushLeftChoice
           
protected  javax.swing.JScrollPane coordsScroller
           
protected  javax.swing.JTextArea coordsTextArea
           
protected  JNumericStateButton cornerRadiusButton
           
protected  javax.swing.JLabel cornerRadiusLabel
           
protected  FigAttribs currentAttribs
           
protected  javax.swing.JTextField dashLengthField
           
protected  boolean debug
           
protected  java.awt.Font defaultFont
           
protected  JNumericStateButton depthButton
           
protected  javax.swing.JLabel depthLabel
           
protected  FigBasicEditor editor
           
protected  javax.swing.JTextField f_arrowLengthField
           
protected  javax.swing.JTextField f_arrowThicknessField
           
protected  javax.swing.JTextField f_arrowWidthField
           
protected  JColorButton fillColorButton
           
protected  javax.swing.JLabel fillColorLabel
           
protected  JFillPatternButton fillPatternButton
           
protected  JFontButton fontSelectButton
           
protected  JNumericStateButton fontSizeButton
           
protected  javax.swing.JLabel fontStyleLabel
           
protected  javax.swing.JLabel landscapeLabel
           
protected  javax.swing.JComboBox landscapePortraitChoice
           
protected  JColorButton lineColorButton
           
protected  javax.swing.JLabel lineColorLabel
           
protected  JStateButton lineStyleButton
           
protected  javax.swing.JLabel lineStyleLabel
           
protected  JStateButton lineWidthButton
           
protected  javax.swing.JLabel lineWidthLabel
           
protected  javax.swing.JButton okButton
           
protected  JNumericStateButton rotationAngleButton
           
protected  javax.swing.JLabel rotationAngleLabel
           
protected  FigAttribs savedAttribs
           
protected  java.lang.String savedCoords
           
protected  StatusMessage statusMessage
           
protected  JStateButton textAlignButton
           
protected  javax.swing.JLabel textAlignLabel
           
 
Fields inherited from class javax.swing.JDialog
accessibleContext, rootPane, rootPaneCheckingEnabled
 
Fields inherited from class java.awt.Dialog
 
Fields inherited from class java.awt.Window
 
Fields inherited from class java.awt.Container
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, EXIT_ON_CLOSE, HIDE_ON_CLOSE
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
JEditBaseobjectDialog(java.awt.Frame parent, FigBasicEditor editor, java.lang.String title)
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent evt)
           
 javax.swing.JPanel buildArrowModePanel()
           
 javax.swing.JPanel buildAttribsPanel()
          all of the attribute controls, in a nice one-column GridLayout
 javax.swing.JPanel buildBArrowPanel()
           
 javax.swing.JPanel buildButtonPanel()
          the panel to center the "OK", "Apply", and "Cancel" buttons
 javax.swing.JPanel buildCoordsPanel()
           
 javax.swing.JPanel buildCornerRadiusPanel()
           
 javax.swing.JPanel buildDepthPanel()
           
 javax.swing.JPanel buildFArrowPanel()
           
 javax.swing.JPanel buildFillStylePanel()
           
 javax.swing.JPanel buildFontSelectPanel()
           
 javax.swing.JPanel buildLabelsPanel()
          all of the attribute labels, in a nice one-column GridLayout
 javax.swing.JPanel buildLineColorPanel()
           
 javax.swing.JPanel buildLineStylePanel()
           
 javax.swing.JPanel buildOptionsPanel()
           
 javax.swing.JPanel buildRotationAnglePanel()
           
 javax.swing.JPanel buildTextAttributesPanel()
           
protected  void createControls()
          create all our GUI components
 void dbg(java.lang.String msg)
           
 void doApply()
           
 void doCancel()
           
 void doOK()
           
 void doRedraw()
           
 void getGUIDefaults()
          load fonts and background color from the SetupManager, if any
 void keyPressed(java.awt.event.KeyEvent evt)
          keyPressed(): Call the parent if the user presses or .
 void keyReleased(java.awt.event.KeyEvent evt)
           
 void keyTyped(java.awt.event.KeyEvent evt)
           
static void main(java.lang.String[] argv)
          main(), for debugging only
 void message(java.lang.String msg)
           
 void retrieveAttribs(FigAttribs attr)
          utility method to get the current attribute settings from the individual GUI buttons/choices/textfields
 void setAttributes(FigAttribs attribs)
          set the attribute object to edit.
 void showAttribs(FigAttribs attr)
          utility method to show the current attribute settings in the individual GUI buttons/choices/textfields
 void windowActivated(java.awt.event.WindowEvent we)
           
 void windowClosed(java.awt.event.WindowEvent we)
           
 void windowClosing(java.awt.event.WindowEvent we)
           
 void windowDeactivated(java.awt.event.WindowEvent we)
           
 void windowDeiconified(java.awt.event.WindowEvent we)
           
 void windowIconified(java.awt.event.WindowEvent we)
           
 void windowOpened(java.awt.event.WindowEvent we)
           
 
Methods inherited from class javax.swing.JDialog
addImpl, createRootPane, dialogInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update
 
Methods inherited from class java.awt.Dialog
addNotify, dispose, getTitle, hide, isModal, isResizable, isUndecorated, setModal, setResizable, setTitle, setUndecorated, show
 
Methods inherited from class java.awt.Window
addPropertyChangeListener, addPropertyChangeListener, addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, finalize, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getMostRecentFocusOwner, getOwnedWindows, getOwner, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindowStateListeners, isActive, isFocusableWindow, isFocusCycleRoot, isFocused, isShowing, pack, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, setCursor, setFocusableWindowState, setFocusCycleRoot, setLocationRelativeTo, toBack, toFront
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, removeNotify, setFocusTraversalKeys, setFocusTraversalPolicy, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isOpaque, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

editor

protected FigBasicEditor editor

savedAttribs

protected FigAttribs savedAttribs

currentAttribs

protected FigAttribs currentAttribs

savedCoords

protected java.lang.String savedCoords

statusMessage

protected StatusMessage statusMessage

defaultFont

protected java.awt.Font defaultFont

backgroundColor

protected java.awt.Color backgroundColor

debug

protected boolean debug

okButton

protected javax.swing.JButton okButton

applyButton

protected javax.swing.JButton applyButton

cancelButton

protected javax.swing.JButton cancelButton

AC

protected JAttribsControlsFactory AC

lineStyleButton

protected JStateButton lineStyleButton

lineWidthButton

protected JStateButton lineWidthButton

dashLengthField

protected javax.swing.JTextField dashLengthField

lineColorButton

protected JColorButton lineColorButton

arrowModeButton

protected JStateButton arrowModeButton

arrowStyleButton

protected JStateButton arrowStyleButton

f_arrowWidthField

protected javax.swing.JTextField f_arrowWidthField

f_arrowLengthField

protected javax.swing.JTextField f_arrowLengthField

f_arrowThicknessField

protected javax.swing.JTextField f_arrowThicknessField

b_arrowWidthField

protected javax.swing.JTextField b_arrowWidthField

b_arrowLengthField

protected javax.swing.JTextField b_arrowLengthField

b_arrowThicknessField

protected javax.swing.JTextField b_arrowThicknessField

fillColorButton

protected JColorButton fillColorButton

fillPatternButton

protected JFillPatternButton fillPatternButton

depthButton

protected JNumericStateButton depthButton

fontSelectButton

protected JFontButton fontSelectButton

fontSizeButton

protected JNumericStateButton fontSizeButton

textAlignButton

protected JStateButton textAlignButton

cornerRadiusButton

protected JNumericStateButton cornerRadiusButton

rotationAngleButton

protected JNumericStateButton rotationAngleButton

landscapePortraitChoice

protected javax.swing.JComboBox landscapePortraitChoice

centerFlushLeftChoice

protected javax.swing.JComboBox centerFlushLeftChoice

coordsTextArea

protected javax.swing.JTextArea coordsTextArea

coordsScroller

protected javax.swing.JScrollPane coordsScroller

lineStyleLabel

protected javax.swing.JLabel lineStyleLabel

lineWidthLabel

protected javax.swing.JLabel lineWidthLabel

lineColorLabel

protected javax.swing.JLabel lineColorLabel

arrowModeLabel

protected javax.swing.JLabel arrowModeLabel

arrowStyleLabel

protected javax.swing.JLabel arrowStyleLabel

arrowFLabel

protected javax.swing.JLabel arrowFLabel

arrowBLabel

protected javax.swing.JLabel arrowBLabel

fillColorLabel

protected javax.swing.JLabel fillColorLabel

fontStyleLabel

protected javax.swing.JLabel fontStyleLabel

textAlignLabel

protected javax.swing.JLabel textAlignLabel

cornerRadiusLabel

protected javax.swing.JLabel cornerRadiusLabel

depthLabel

protected javax.swing.JLabel depthLabel

landscapeLabel

protected javax.swing.JLabel landscapeLabel

rotationAngleLabel

protected javax.swing.JLabel rotationAngleLabel
Constructor Detail

JEditBaseobjectDialog

public JEditBaseobjectDialog(java.awt.Frame parent,
                             FigBasicEditor editor,
                             java.lang.String title)
Method Detail

setAttributes

public void setAttributes(FigAttribs attribs)
set the attribute object to edit.


getGUIDefaults

public void getGUIDefaults()
load fonts and background color from the SetupManager, if any


buildButtonPanel

public javax.swing.JPanel buildButtonPanel()
the panel to center the "OK", "Apply", and "Cancel" buttons


createControls

protected void createControls()
create all our GUI components


buildLabelsPanel

public javax.swing.JPanel buildLabelsPanel()
all of the attribute labels, in a nice one-column GridLayout


buildAttribsPanel

public javax.swing.JPanel buildAttribsPanel()
all of the attribute controls, in a nice one-column GridLayout


buildLineColorPanel

public javax.swing.JPanel buildLineColorPanel()

buildLineStylePanel

public javax.swing.JPanel buildLineStylePanel()

buildArrowModePanel

public javax.swing.JPanel buildArrowModePanel()

buildFArrowPanel

public javax.swing.JPanel buildFArrowPanel()

buildBArrowPanel

public javax.swing.JPanel buildBArrowPanel()

buildFillStylePanel

public javax.swing.JPanel buildFillStylePanel()

buildFontSelectPanel

public javax.swing.JPanel buildFontSelectPanel()

buildTextAttributesPanel

public javax.swing.JPanel buildTextAttributesPanel()

buildDepthPanel

public javax.swing.JPanel buildDepthPanel()

buildRotationAnglePanel

public javax.swing.JPanel buildRotationAnglePanel()

buildOptionsPanel

public javax.swing.JPanel buildOptionsPanel()

buildCornerRadiusPanel

public javax.swing.JPanel buildCornerRadiusPanel()

buildCoordsPanel

public javax.swing.JPanel buildCoordsPanel()

retrieveAttribs

public void retrieveAttribs(FigAttribs attr)
utility method to get the current attribute settings from the individual GUI buttons/choices/textfields


showAttribs

public void showAttribs(FigAttribs attr)
utility method to show the current attribute settings in the individual GUI buttons/choices/textfields


keyPressed

public void keyPressed(java.awt.event.KeyEvent evt)
keyPressed(): Call the parent if the user presses or .

Specified by:
keyPressed in interface java.awt.event.KeyListener

keyReleased

public void keyReleased(java.awt.event.KeyEvent evt)
Specified by:
keyReleased in interface java.awt.event.KeyListener

keyTyped

public void keyTyped(java.awt.event.KeyEvent evt)
Specified by:
keyTyped in interface java.awt.event.KeyListener

doRedraw

public void doRedraw()

doCancel

public void doCancel()

doApply

public void doApply()

doOK

public void doOK()

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent evt)
Specified by:
actionPerformed in interface java.awt.event.ActionListener

windowOpened

public void windowOpened(java.awt.event.WindowEvent we)
Specified by:
windowOpened in interface java.awt.event.WindowListener

windowClosing

public void windowClosing(java.awt.event.WindowEvent we)
Specified by:
windowClosing in interface java.awt.event.WindowListener

windowClosed

public void windowClosed(java.awt.event.WindowEvent we)
Specified by:
windowClosed in interface java.awt.event.WindowListener

windowIconified

public void windowIconified(java.awt.event.WindowEvent we)
Specified by:
windowIconified in interface java.awt.event.WindowListener

windowDeiconified

public void windowDeiconified(java.awt.event.WindowEvent we)
Specified by:
windowDeiconified in interface java.awt.event.WindowListener

windowActivated

public void windowActivated(java.awt.event.WindowEvent we)
Specified by:
windowActivated in interface java.awt.event.WindowListener

windowDeactivated

public void windowDeactivated(java.awt.event.WindowEvent we)
Specified by:
windowDeactivated in interface java.awt.event.WindowListener

message

public void message(java.lang.String msg)

dbg

public void dbg(java.lang.String msg)

main

public static void main(java.lang.String[] argv)
main(), for debugging only