org.openscience.jmol.app.jmolpanel
Class AppConsole
java.lang.Object
org.jmol.console.JmolConsole
org.openscience.jmol.app.jmolpanel.AppConsole
- All Implemented Interfaces:
- java.awt.event.ActionListener, java.awt.event.WindowListener, java.util.EventListener, JmolAppConsoleInterface, JmolCallbackListener, EnterListener
public class AppConsole
- extends JmolConsole
- implements JmolAppConsoleInterface, EnterListener
Fields inherited from class org.jmol.console.JmolConsole |
defaultMessage, editButton, externalContainer, historyButton, label1, labels, menuMap, nTab, runButton, scriptEditor, stateButton, viewer, viewerFrame |
Constructor Summary |
AppConsole()
|
AppConsole(JmolViewer viewer,
java.awt.Container externalContainer,
java.lang.String enabledButtons)
general entry point |
Methods inherited from class org.jmol.console.JmolConsole |
addWindowListener, dispose, getLabel, getPane, getScriptEditor, getWindow, notifyCallback, notifyEnabled, setCallbackFunction, setEnabled, setTitle, setVisible, updateLabels, windowActivated, windowClosed, windowClosing, windowDeactivated, windowDeiconified, windowIconified, windowOpened |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ALL_BUTTONS
public static final java.lang.String ALL_BUTTONS
- See Also:
- Constant Field Values
jcd
javax.swing.JDialog jcd
console
protected AppConsole.ConsoleTextPane console
stepButton
protected javax.swing.JButton stepButton
buttons
protected java.util.Map<java.lang.String,javax.swing.AbstractButton> buttons
varButton
private javax.swing.JButton varButton
haltButton
private javax.swing.JButton haltButton
closeButton
private javax.swing.JButton closeButton
clearButton
private javax.swing.JButton clearButton
helpButton
private javax.swing.JButton helpButton
undoButton
private javax.swing.JButton undoButton
redoButton
private javax.swing.JButton redoButton
checkButton
private javax.swing.JButton checkButton
topButton
private javax.swing.JButton topButton
buttonPanel
private javax.swing.JPanel buttonPanel
isError
boolean isError
execThread
AppConsole.ExecuteCommandThread execThread
MAXUNDO
private static int MAXUNDO
undoStack
private java.lang.String[] undoStack
undoPointer
private int undoPointer
undoSaved
private boolean undoSaved
dontsave
private boolean dontsave
AppConsole
public AppConsole(JmolViewer viewer,
java.awt.Container externalContainer,
java.lang.String enabledButtons)
- general entry point
- Parameters:
viewer
- externalContainer
- a JFrame or JPanel or JDialogenabledButtons
-
AppConsole
public AppConsole()
getAppConsole
public JmolAppConsoleInterface getAppConsole(JmolViewer viewer)
- don't delete! used by Viewer after it gets the class by name
- Specified by:
getAppConsole
in interface JmolAppConsoleInterface
- Parameters:
viewer
-
- Returns:
- AppConsole or AppletConsole
sendConsoleEcho
public void sendConsoleEcho(java.lang.String strEcho)
- Specified by:
sendConsoleEcho
in interface JmolAppConsoleInterface
- Specified by:
sendConsoleEcho
in class JmolConsole
sendConsoleMessage
public void sendConsoleMessage(java.lang.String strStatus)
- Specified by:
sendConsoleMessage
in interface JmolAppConsoleInterface
- Specified by:
sendConsoleMessage
in class JmolConsole
setButton
protected javax.swing.JButton setButton(java.lang.String label)
- Overrides:
setButton
in class JmolConsole
setupLabels
protected void setupLabels()
- Specified by:
setupLabels
in class JmolConsole
layoutWindow
private void layoutWindow(java.lang.String enabledButtons)
enableButton
private void enableButton(java.lang.String name)
setError
private void setError(boolean TF)
enterPressed
public void enterPressed()
- Specified by:
enterPressed
in interface EnterListener
execute
protected void execute(java.lang.String strCommand)
- Specified by:
execute
in class JmolConsole
executeCommandAsThread
void executeCommandAsThread(java.lang.String strCommand)
zap
public void zap()
- Specified by:
zap
in interface JmolAppConsoleInterface
undoClear
private void undoClear()
undoSetEnabled
private boolean undoSetEnabled()
undoRedo
private void undoRedo(boolean isRedo)
undoSave
private void undoSave(boolean incrementPtr)
executeCommand
void executeCommand(java.lang.String strCommand)
clearContent
protected void clearContent(java.lang.String text)
- Specified by:
clearContent
in class JmolConsole
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
- Specified by:
actionPerformed
in interface java.awt.event.ActionListener
- Overrides:
actionPerformed
in class JmolConsole
completeCommand
protected java.lang.String completeCommand(java.lang.String thisCmd)
- Overrides:
completeCommand
in class JmolConsole
getText
public java.lang.String getText()
- Specified by:
getText
in interface JmolAppConsoleInterface
- Specified by:
getText
in class JmolConsole