|
|||||||||||
| 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
projectPrototype.view.graphicEditor.GraphicEditor
Editor,
Serialized Form| Nested Class Summary | |
private class |
GraphicEditor.MouseClick
|
private class |
GraphicEditor.MouseMotion
|
| Nested classes inherited from class javax.swing.JPanel |
javax.swing.JPanel.AccessibleJPanel |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| 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 | |
private Operator |
activeOperator
Selected Operator. |
private java.util.LinkedList |
currentGraphicElements
Graphic elements wich are being created. |
private java.util.LinkedList |
graphicElementsList
Graphic Elements contained by the Graphic Editor. |
private Operator[] |
operators
Operators of the Graphic Editor. |
private State[] |
states
States of the Graphic editor. |
| Fields inherited from class javax.swing.JPanel |
|
| 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.Container |
|
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface projectPrototype.view.graphicEditor.Editor |
CFP, CSP, IDENTIFICATION, LINK_CFP, LINK_CSP, MODIFICATION, OVER_OBJECT, OVER_SELECTOR, TRANSLATION |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
GraphicEditor()
Creates a Graphic Editor |
|
| Method Summary | |
void |
addGraphicElement()
Adds the created Graphic Elements to the graphicElementsList. |
void |
bringForward(GraphicElement graphicElement)
Bring forward a Graphic Element |
void |
bringToFront(GraphicElement graphicElement)
Bring to front the Graphic Element. |
void |
changeCursor(java.awt.Cursor cursor)
Sets the mouse Cursor. |
private void |
clbp(double x,
double y)
This method is called when left mouse button is pressed and CTRL key is down (clbp) |
Operator |
getActiveOpertator()
Returns the active Operator. |
GraphicElement |
getGraphicElement(int i)
Return a GraphicElement. |
GraphicElement |
getGraphicElementOver(Point point)
Returns the Graphic Element over the Point. |
int |
getGraphicElementsListSize()
Returns the number of Graphic Elements |
State |
getState(int i)
Returns the active State. |
private void |
lbp(double x,
double y)
This method is called when the left mouse button is pressed (lbp) |
private void |
lbr(double x,
double y)
This method is called when the left mouse button is released (lbr) |
void |
paint()
Paints the Graphic Elements |
void |
paint(java.awt.Graphics g)
Paints the Graphic Elements |
private void |
rm(double x,
double y)
This method is called when the mouse is moved |
void |
selectNone()
Unselect all Graphic Elements |
void |
sendBackward(GraphicElement graphicElement)
Send backward a Graphic Element |
void |
sendToBack(GraphicElement graphicElement)
Send to back a Graphic Element |
void |
setCurrentGraphicElement(GraphicElement graphicElement)
Indicates to the Graphic Editor wich graphic element is being created. |
void |
setCurrentGraphicElements(java.util.LinkedList graphicElements)
Sets Graphics Elements being created. |
void |
setOperator(int operator)
Switch operator. |
private void |
showPopup(double x,
double y)
This method is called to show a PopupMenu |
| Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class javax.swing.JComponent |
addAncestorListener, addNotify, addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getGraphics, getHeight, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPreferredSize, getPropertyChangeListeners, getPropertyChangeListeners, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, isDoubleBuffered, isLightweightComponent, isManagingFocus, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isPreferredSizeSet, isRequestFocusEnabled, isValidateRoot, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFont, setForeground, 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, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setLayout, 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, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getParent, getPeer, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusUpCycle |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
private Operator[] operators
private Operator activeOperator
private State[] states
private java.util.LinkedList currentGraphicElements
private java.util.LinkedList graphicElementsList
| Constructor Detail |
public GraphicEditor()
| Method Detail |
public void paint(java.awt.Graphics g)
public void setOperator(int operator)
setOperator in interface Editoroperator - Operator to be set.public Operator getActiveOpertator()
getActiveOpertator in interface Editorpublic State getState(int i)
getState in interface Editori - State to be retrieved
public void setCurrentGraphicElement(GraphicElement graphicElement)
setCurrentGraphicElement in interface EditorgraphicElement - Graphic element being created.public void addGraphicElement()
addGraphicElement in interface Editorpublic int getGraphicElementsListSize()
getGraphicElementsListSize in interface Editorpublic GraphicElement getGraphicElement(int i)
getGraphicElement in interface Editori - Index of the Graphic Element
private void lbp(double x,
double y)
x - X mouse coordinatey - Y mouse coordinate
private void lbr(double x,
double y)
x - X mouse coordinatey - Y mouse coordinate
private void clbp(double x,
double y)
x - X mouse coordinatey - Y mouse coordinate
private void rm(double x,
double y)
x - X mouse coordinatey - Y mouse coordinate
private void showPopup(double x,
double y)
x - X mouse coordinatey - Y mouse coordinatepublic void selectNone()
selectNone in interface Editorpublic void bringToFront(GraphicElement graphicElement)
bringToFront in interface EditorgraphicElement - Graphic Element to bring to front.public void sendToBack(GraphicElement graphicElement)
Editor
sendToBack in interface EditorgraphicElement - Graphic Element so send to backEditor.sendToBack(GraphicElement)public void bringForward(GraphicElement graphicElement)
Editor
bringForward in interface EditorgraphicElement - Graphic Element to bring forwardEditor.bringForward(GraphicElement)public void sendBackward(GraphicElement graphicElement)
Editor
sendBackward in interface EditorgraphicElement - Graphic Element to send backwardEditor.sendBackward(GraphicElement)public void paint()
Editor
paint in interface EditorEditor.paint()public void changeCursor(java.awt.Cursor cursor)
Editor
changeCursor in interface Editorcursor - Cursor to be set.Editor.changeCursor(java.awt.Cursor)public GraphicElement getGraphicElementOver(Point point)
Editor
getGraphicElementOver in interface Editorpoint - Point over a Graphic Element
projectPrototype.view.graphicEditor.Editor#getGraphicElementOverPoint(Point)public void setCurrentGraphicElements(java.util.LinkedList graphicElements)
Editor
setCurrentGraphicElements in interface EditorgraphicElements - Graphic Elements being createdEditor.setCurrentGraphicElements(java.util.LinkedList)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||