|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.Window | +--java.awt.Frame | +--javax.swing.JFrame | +--koala.dynamicjava.gui.Main
A Graphical User Interface for DynamicJava
Inner Class Summary | |
protected class |
Main.AboutAction
Pop the About dialog |
protected class |
Main.ClearAction
To clear the output |
protected class |
Main.EditorCaretListener
To listen to the editor caret |
protected class |
Main.EvalAction
To evaluate the content of the buffer |
protected class |
Main.EvalSelectionAction
To evaluate the content of the selection |
protected class |
Main.ExitAction
To exit the application |
protected class |
Main.InterpreterThread
To run the interpreter |
protected class |
Main.OptionsAction
To pop the Options dialog |
protected class |
Main.ReinitAction
Reinitializes the interpreter |
protected class |
Main.ScrollBarModelChangeListener
To listen to the changes in the output area vertical scroll bar model |
protected class |
Main.StopAction
To stop the interpreter thread |
Inner classes inherited from class javax.swing.JFrame |
javax.swing.JFrame.AccessibleJFrame |
Inner classes inherited from class java.awt.Frame |
java.awt.Frame.AccessibleAWTFrame |
Inner classes inherited from class java.awt.Window |
java.awt.Window.AccessibleAWTWindow |
Inner classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
Inner classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent |
Field Summary | |
static java.lang.String |
ABOUT_ACTION
|
protected static java.util.ResourceBundle |
bundle
The resource bundle |
static java.lang.String |
CLEAR_ACTION
|
static java.lang.String |
COPY_ACTION
|
static java.lang.String |
CUT_ACTION
|
protected Editor |
editor
The editor |
protected java.io.PrintStream |
err
The current error stream |
static java.lang.String |
EVAL_ACTION
|
static java.lang.String |
EVAL_S_ACTION
|
protected Main.EvalAction |
evalAction
The evaluator |
protected Main.EvalSelectionAction |
evalSelection
The selection evaluator |
static java.lang.String |
EXIT_ACTION
|
protected static int |
instances
The number of instances of this class |
protected Interpreter |
interpreter
The DynamicJava current interpreter |
protected boolean |
isRunning
Is the interpreter running? |
protected java.util.Map |
listeners
The map that contains the listeners |
static java.lang.String |
OPEN_ACTION
|
protected OptionsDialog |
options
The options dialog |
static java.lang.String |
OPTIONS_ACTION
|
protected OptionsDialog.OptionSet |
optionSet
The object used to store the options |
protected java.io.PrintStream |
out
The current output stream |
protected javax.swing.JTextArea |
output
The text area used to display the output |
static java.lang.String |
PASTE_ACTION
|
static java.lang.String |
REDO_ACTION
|
static java.lang.String |
REINIT_ACTION
|
protected static java.lang.String |
RESOURCE
The resource file name |
protected static ResourceManager |
rManager
The resource manager |
static java.lang.String |
SAVE_ACTION
|
static java.lang.String |
SAVE_AS_ACTION
|
protected javax.swing.BoundedRangeModel |
scrollBarModel
The output area vertical scroll bar model |
protected int |
selectionEnd
The current selection end |
protected int |
selectionStart
The current selection start |
protected StatusBar |
status
The status bar |
static java.lang.String |
STOP_ACTION
|
protected Main.StopAction |
stopAction
The stop action |
protected java.io.PrintStream |
textComponentStream
The text component stream |
protected java.lang.Thread |
thread
The current interpreter thread |
static java.lang.String |
UNDO_ACTION
|
Fields inherited from class javax.swing.JFrame |
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled |
Fields inherited from class java.awt.Frame |
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR |
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, HIDE_ON_CLOSE |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
Main()
Creates the interface |
Method Summary | |
protected void |
applyOptions()
Applies the options |
protected Interpreter |
createInterpreter()
Creates a new interpreter |
protected void |
exit()
Called when the interface exits |
javax.swing.Action |
getAction(java.lang.String key)
Returns the action associated with the given string or null on error |
protected int |
getCurrentLine(int p)
Returns the line number that match the given position |
Editor |
getEditor()
Returns the editor |
OptionsDialog.OptionSet |
getOptions()
Gets the options |
OptionsDialog |
getOptionsDialog()
Returns the options dialog |
javax.swing.JTextArea |
getOutputArea()
Returns the output area |
void |
loadOptions()
Loads the options |
static void |
main(java.lang.String[] args)
The entry point of the program |
protected void |
reinitializeInterpreter()
Reinitializes the interpreter |
protected void |
restoreOptions()
Restores the options |
void |
saveOptions()
Saves the options to System.getProperty("user.home") + "/.djava/options" |
void |
setOptions(OptionsDialog.OptionSet opt)
Sets the options |
protected java.lang.String |
stringToJavaString(java.lang.String s)
translates a string to a java source string |
Methods inherited from class javax.swing.JFrame |
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getJMenuBar, getLayeredPane, getRootPane, isRootPaneCheckingEnabled, paramString, processKeyEvent, processWindowEvent, remove, setContentPane, setDefaultCloseOperation, setGlassPane, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, update |
Methods inherited from class java.awt.Frame |
addNotify, finalize, getCursorType, getFrames, getIconImage, getMenuBar, getState, getTitle, isResizable, remove, removeNotify, setCursor, setIconImage, setMenuBar, setResizable, setState, setTitle |
Methods inherited from class java.awt.Window |
addWindowListener, applyResourceBundle, applyResourceBundle, dispose, getFocusOwner, getGraphicsConfiguration, getInputContext, getListeners, getLocale, getOwnedWindows, getOwner, getToolkit, getWarningString, hide, isShowing, pack, postEvent, processEvent, removeWindowListener, setCursor, show, toBack, toFront |
Methods inherited from class java.awt.Container |
add, add, add, add, add, addContainerListener, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getInsets, getLayout, getMaximumSize, getMinimumSize, getPreferredSize, insets, invalidate, isAncestorOf, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setFont, validate, validateTree |
Methods inherited from class java.awt.Component |
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addPropertyChangeListener, addPropertyChangeListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, getBackground, getBounds, getBounds, getColorModel, getComponentOrientation, getCursor, getDropTarget, getFont, getFontMetrics, getForeground, getGraphics, getHeight, getInputMethodRequests, getLocation, getLocation, getLocationOnScreen, getName, getParent, getPeer, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isDisplayable, isDoubleBuffered, isEnabled, isFocusTraversable, 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, processMouseEvent, processMouseMotionEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setDropTarget, setEnabled, setForeground, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, size, toString, transferFocus |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.awt.MenuContainer |
getFont, postEvent |
Field Detail |
public static final java.lang.String OPEN_ACTION
public static final java.lang.String SAVE_ACTION
public static final java.lang.String SAVE_AS_ACTION
public static final java.lang.String EXIT_ACTION
public static final java.lang.String UNDO_ACTION
public static final java.lang.String REDO_ACTION
public static final java.lang.String CUT_ACTION
public static final java.lang.String COPY_ACTION
public static final java.lang.String PASTE_ACTION
public static final java.lang.String CLEAR_ACTION
public static final java.lang.String OPTIONS_ACTION
public static final java.lang.String EVAL_ACTION
public static final java.lang.String EVAL_S_ACTION
public static final java.lang.String STOP_ACTION
public static final java.lang.String REINIT_ACTION
public static final java.lang.String ABOUT_ACTION
protected static int instances
protected static final java.lang.String RESOURCE
protected static java.util.ResourceBundle bundle
protected static ResourceManager rManager
protected Editor editor
protected javax.swing.JTextArea output
protected javax.swing.BoundedRangeModel scrollBarModel
protected StatusBar status
protected OptionsDialog options
protected Interpreter interpreter
protected int selectionStart
protected int selectionEnd
protected Main.EvalAction evalAction
protected Main.EvalSelectionAction evalSelection
protected Main.StopAction stopAction
protected java.lang.Thread thread
protected boolean isRunning
protected OptionsDialog.OptionSet optionSet
protected java.io.PrintStream textComponentStream
protected java.io.PrintStream out
protected java.io.PrintStream err
protected java.util.Map listeners
Constructor Detail |
public Main()
Method Detail |
public static void main(java.lang.String[] args)
public void setOptions(OptionsDialog.OptionSet opt)
public OptionsDialog.OptionSet getOptions()
public void saveOptions() throws java.io.IOException
protected java.lang.String stringToJavaString(java.lang.String s)
public void loadOptions()
public OptionsDialog getOptionsDialog()
public Editor getEditor()
public javax.swing.JTextArea getOutputArea()
protected void exit()
protected void reinitializeInterpreter()
protected void applyOptions()
protected int getCurrentLine(int p)
p
- a positionprotected void restoreOptions()
protected Interpreter createInterpreter()
public javax.swing.Action getAction(java.lang.String key) throws MissingListenerException
getAction
in interface ActionMap
key
- the key mapped with the action to getMissingListenerException
- if the action is not found
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |