|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--java.awt.Component
|
+--java.awt.Container
|
+--javax.swing.JComponent
|
+--javax.swing.JPanel
|
+--com.jfimagine.jfdraw.gui.DrawAdapter
|
+--com.jfimagine.jfdraw.gui.DrawPane
Draw pane class. A main drawing pane with rulers, scrollbars and drawing canvas inside.
| Nested Class Summary |
| 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 | |
protected Ruler |
m_columnView
Horizontal and vertical rulers. |
protected DrawCanvas |
m_drawCanvas
Drawing Canvas |
protected javax.swing.JScrollPane |
m_drawScrollPane
|
protected boolean |
m_hideRulers
if hide rulers |
protected boolean |
m_hideScrollbars
if hide scrollbars Since rulers are part of this scroll panes, so hide scroll bars would also hide rulers. |
protected DrawFrame |
m_parentDrawFrame
parent draw frame |
protected Ruler |
m_rowView
|
| Fields inherited from class com.jfimagine.jfdraw.gui.DrawAdapter |
listenerList |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, 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 | |
DrawPane()
Constructor |
|
DrawPane(boolean initIt)
Constructor |
|
| Method Summary | |
CanvasFormat |
getCanvasFormat()
Get canvas format. |
DrawCanvas |
getDrawCanvas()
get current Drawing Canvas |
java.lang.String |
getFileName()
get the file name of current opened page. |
boolean |
getIsMetric()
get if ruler is a metric one. |
JFPageFormat |
getPageFormat()
Get page format. |
javax.swing.JScrollPane |
getScrollPane()
get current scroll pane. |
void |
initComponents()
Init all gui components of this DrawPane. |
boolean |
isHideGrids()
if hide grids now |
boolean |
isHidePopupMenus()
if hide popupmenus now |
boolean |
isHideRulers()
if hide rulers now |
boolean |
isHideScrollbars()
if hide scrollbars now |
boolean |
isUsePageBounds()
if use page bounds to restrict drawing |
protected DrawCanvas |
newDrawCanvas()
to create a new instance of DrawCanvas class |
void |
newFile()
new file operation. |
void |
notifyObjectSelected(ObjectList objList)
Notify object selected, tell to do some changes in the drawing framework. |
boolean |
openFile(java.lang.String fileName)
open a specified file |
boolean |
saveFile(java.lang.String fileName)
Save current page to a specified file. |
void |
setCanvasFormat(CanvasFormat canvasFormat)
Set canvas format. |
void |
setFileName(java.lang.String fileName)
set the file name of current opened page. |
void |
setHideGrids(boolean hideGrids)
set if hide grids |
void |
setHidePopupMenus(boolean hidePopupMenus)
set if hide popupmenus |
void |
setHideRulers(boolean hideRulers)
set if hide rulers |
void |
setHideScrollbars(boolean hideScrollbars)
set if hide scrollbars |
void |
setIsMetric(boolean isMetric)
set ruler as metric or english measurement. |
void |
setPageFormat(java.awt.print.PageFormat pageFormat)
Set page format. |
void |
setUsePageBounds(boolean usePageBounds)
set if use page bounds to restrict drawing |
void |
setZoomScale(double zoomScale)
set zoom scale |
| Methods inherited from class com.jfimagine.jfdraw.gui.DrawAdapter |
actionPerformed, addGraphEventListener, closeAllWindows, fireAction, fireGraphEvent, focusWindowByTitle, getDesktop, removeGraphEventListener, setDefaultFrameParameters, setLayerName |
| 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, paint, 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 |
protected Ruler m_columnView
protected Ruler m_rowView
protected DrawCanvas m_drawCanvas
protected DrawFrame m_parentDrawFrame
protected javax.swing.JScrollPane m_drawScrollPane
protected boolean m_hideRulers
protected boolean m_hideScrollbars
| Constructor Detail |
public DrawPane()
public DrawPane(boolean initIt)
initIt - True if initiate components, false otherwise.
If you use false here to avoid initiating components when constructing,
you need to call initComponents immediately.| Method Detail |
public boolean isHideRulers()
public void setHideRulers(boolean hideRulers)
public boolean isHideScrollbars()
public void setHideScrollbars(boolean hideScrollbars)
public boolean isHideGrids()
public void setHideGrids(boolean hideGrids)
public boolean isHidePopupMenus()
public void setHidePopupMenus(boolean hidePopupMenus)
public boolean isUsePageBounds()
public void setUsePageBounds(boolean usePageBounds)
public void initComponents()
protected DrawCanvas newDrawCanvas()
public DrawCanvas getDrawCanvas()
getDrawCanvas in class DrawAdapterpublic javax.swing.JScrollPane getScrollPane()
public void setZoomScale(double zoomScale)
zoomScale - A new zoom scale.public void setIsMetric(boolean isMetric)
setIsMetric in class DrawAdapterisMetric - True if is metric, false english.public boolean getIsMetric()
getIsMetric in class DrawAdapterpublic JFPageFormat getPageFormat()
public void setPageFormat(java.awt.print.PageFormat pageFormat)
pageFormat - A new page format.public CanvasFormat getCanvasFormat()
public void setCanvasFormat(CanvasFormat canvasFormat)
canvasFormat - A new canvas format.public void newFile()
newFile in class DrawAdapterpublic boolean openFile(java.lang.String fileName)
openFile in class DrawAdapterfileName - A spcified file namepublic boolean saveFile(java.lang.String fileName)
saveFile in class DrawAdapterfileName - A file to be saved into.public java.lang.String getFileName()
getFileName in class DrawAdapterpublic void setFileName(java.lang.String fileName)
setFileName in class DrawAdapterfileName - A new file namepublic void notifyObjectSelected(ObjectList objList)
notifyObjectSelected in class DrawAdapterobjList - A new selected object list.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||