|
|||||||||
| 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
chemaxon.alchemist.utils.AbstractAlchemistMoleculeView
chemaxon.alchemist.utils.AlchemistMoleculeView
chemaxon.alchemist.utils.AbstractAlchemistMoleculeEditor
public abstract class AbstractAlchemistMoleculeEditor
| Nested Class Summary | |
|---|---|
protected static class |
AbstractAlchemistMoleculeEditor.MoleculeIndexArray
|
| Nested classes/interfaces inherited from class javax.swing.JPanel |
|---|
javax.swing.JPanel.AccessibleJPanel |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
javax.swing.JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
java.awt.Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
protected javax.swing.AbstractAction |
ADD_MOLECULE_ACTION
Action for perform add molecule to the editor. |
protected javax.swing.AbstractAction |
APPLY_MOLECULE_EDIT_ACTION
This method applies performed molecule modification action |
protected javax.swing.AbstractAction |
CANCEL_MOLECULE_EDIT_ACTION
This method cancels performed molecule modification action |
protected javax.swing.AbstractAction |
EDIT_MOLECULE_ACTION
Action for perform edit selected molecule. |
protected boolean |
isLoading
|
protected javax.swing.event.SwingPropertyChangeSupport |
notifier
|
static java.lang.String |
PROPERTY_KEY_ADDED
|
static java.lang.String |
PROPERTY_KEY_EDITED
|
static java.lang.String |
PROPERTY_KEY_REMOVED
|
protected javax.swing.AbstractAction |
REMOVE_MOLECULE_ACTION
This method removes the selected molecule from the table. |
protected MSketchPane |
sketch
|
| Fields inherited from class chemaxon.alchemist.utils.AlchemistMoleculeView |
|---|
columnComboBox, currentRowNum, DEFAULT_MAX_COLNUM, DEFAULT_MAX_ROWNUM, inputStream, isToolbarVisible, maxColNum, maxMolecules, maxRowNum, percent, rowComboBox, scrollBar, source |
| Fields inherited from class chemaxon.alchemist.utils.AbstractAlchemistMoleculeView |
|---|
colNum, dataModel, holderPanel, rowNum, view |
| 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.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 | |
|---|---|
AbstractAlchemistMoleculeEditor(int defaultRowNum,
int defaultColNum,
int maxRowNum,
int maxColNum,
javax.swing.event.SwingPropertyChangeSupport notifier,
MSketchPane sketch)
|
|
AbstractAlchemistMoleculeEditor(int defaultRowNum,
int defaultColNum,
javax.swing.event.SwingPropertyChangeSupport notifier,
MSketchPane sketch)
Constructor from superclass |
|
| Method Summary | |
|---|---|
void |
addMolecule()
AddMolecule action handler |
void |
applyChanges()
Apply Changes action handler |
void |
cancelChanges()
Cancel Changes action handler |
void |
clear()
This method clears the editor, and closes the input stream |
void |
editMolecule()
EditMolecule action handler |
javax.swing.AbstractAction |
getADD_MOLECULE_ACTION()
|
javax.swing.AbstractAction |
getAPPLY_MOLECULE_EDIT_ACTION()
|
javax.swing.AbstractAction |
getCANCEL_MOLECULE_EDIT_ACTION()
|
javax.swing.AbstractAction |
getEDIT_MOLECULE_ACTION()
|
int |
getMoleculeCount()
Returns the number of the molecules in the editor |
Molecule[] |
getMolecules()
This method returns all the molecules from the editor Warning! |
javax.swing.AbstractAction |
getREMOVE_MOLECULE_ACTION()
|
int |
getScrollPosition()
|
boolean |
hasModified()
|
protected abstract void |
hideEditor()
|
void |
importMolecules(java.io.InputStream inputStream)
This method load the molecule from the given stream |
void |
importMolecules(Molecule[] molecules)
This method imports molecules array to the editor |
void |
importMolecules(java.lang.String path)
This method loads the molecule file from given path |
boolean |
isMoleculeSelected()
|
boolean |
isNonEmptyCellSelected()
Returns if there is a non-empty cell selected |
protected void |
refreshGridLayout()
|
protected void |
refreshView()
This method refreshes the molecule view depending on storage |
void |
removeMolecule()
RemoveMolecule action handler |
void |
setEnabled(boolean enabled)
Sets enabled property |
void |
setScrollPosition(int position)
|
protected abstract void |
showEditor()
|
void |
writeToFile(java.io.File file)
Writes the editor's content into the given file with smiles format |
void |
writeToFile(java.io.File file,
java.lang.String format)
Writes the editor's content into the given file with the given format |
void |
writeToStream(java.io.OutputStream outputStream,
java.lang.String format)
Writes the editor's content into the given file with the given format |
| Methods inherited from class chemaxon.alchemist.utils.AlchemistMoleculeView |
|---|
addListSelectionListerer, close, decreaseView, getColCount, getMaxColCount, getMaxRowCount, getProgressPercentage, getRowCount, getTopPanel, getView, increaseView, removeListSelectionListener, setColCount, setRowCount |
| Methods inherited from class chemaxon.alchemist.utils.AbstractAlchemistMoleculeView |
|---|
GetDispOpts, getHolderPanel, isMoleculeLabelVisible, SetDispOpts, setMinimumSize, setMoleculeLabelVisible |
| Methods inherited from class javax.swing.JPanel |
|---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class javax.swing.JComponent |
|---|
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBorder, getBounds, getClientProperty, getComponentGraphics, 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, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, 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, 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, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, 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, firePropertyChange, 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, hide, 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, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, 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, transferFocusUpCycle |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected boolean isLoading
protected MSketchPane sketch
protected javax.swing.event.SwingPropertyChangeSupport notifier
protected final javax.swing.AbstractAction ADD_MOLECULE_ACTION
protected final javax.swing.AbstractAction EDIT_MOLECULE_ACTION
protected final javax.swing.AbstractAction APPLY_MOLECULE_EDIT_ACTION
protected final javax.swing.AbstractAction CANCEL_MOLECULE_EDIT_ACTION
protected final javax.swing.AbstractAction REMOVE_MOLECULE_ACTION
public static final java.lang.String PROPERTY_KEY_EDITED
public static final java.lang.String PROPERTY_KEY_ADDED
public static final java.lang.String PROPERTY_KEY_REMOVED
| Constructor Detail |
|---|
public AbstractAlchemistMoleculeEditor(int defaultRowNum,
int defaultColNum,
javax.swing.event.SwingPropertyChangeSupport notifier,
MSketchPane sketch)
defaultRowNum - defaultColNum - notifier -
public AbstractAlchemistMoleculeEditor(int defaultRowNum,
int defaultColNum,
int maxRowNum,
int maxColNum,
javax.swing.event.SwingPropertyChangeSupport notifier,
MSketchPane sketch)
| Method Detail |
|---|
public void importMolecules(java.lang.String path)
importMolecules in class AlchemistMoleculeViewpath - is the path to molecule filepublic void importMolecules(java.io.InputStream inputStream)
AlchemistMoleculeView
importMolecules in class AlchemistMoleculeViewprotected void refreshView()
refreshView in class AlchemistMoleculeViewprotected void refreshGridLayout()
refreshGridLayout in class AlchemistMoleculeViewpublic int getMoleculeCount()
public void writeToFile(java.io.File file)
file -
public void writeToFile(java.io.File file,
java.lang.String format)
file - format -
public void writeToStream(java.io.OutputStream outputStream,
java.lang.String format)
throws MolFormatException,
java.io.IOException,
java.io.EOFException
outputStream - is the stream to write intoformat - is the export format string
MolFormatException
java.io.IOException
java.io.EOFExceptionpublic void importMolecules(Molecule[] molecules)
molecules - public Molecule[] getMolecules()
protected abstract void showEditor()
protected abstract void hideEditor()
public boolean hasModified()
public void clear()
clear in class AlchemistMoleculeViewpublic void setEnabled(boolean enabled)
AlchemistMoleculeView
setEnabled in class AlchemistMoleculeViewpublic int getScrollPosition()
public void setScrollPosition(int position)
public javax.swing.AbstractAction getADD_MOLECULE_ACTION()
public javax.swing.AbstractAction getEDIT_MOLECULE_ACTION()
public javax.swing.AbstractAction getAPPLY_MOLECULE_EDIT_ACTION()
public javax.swing.AbstractAction getCANCEL_MOLECULE_EDIT_ACTION()
public javax.swing.AbstractAction getREMOVE_MOLECULE_ACTION()
public boolean isMoleculeSelected()
public boolean isNonEmptyCellSelected()
true if there is a non-empty cell selectedpublic void addMolecule()
public void editMolecule()
public void removeMolecule()
public void applyChanges()
public void cancelChanges()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||