类 JConsole
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- javax.swing.JComponent
-
- javax.swing.JScrollPane
-
- org.meteoinfo.console.JConsole
-
- 所有已实现的接口:
ActionListener,KeyListener,MouseListener,ImageObserver,MenuContainer,PropertyChangeListener,Serializable,Runnable,EventListener,Accessible,ScrollPaneConstants,ConsoleInterface,GUIConsoleInterface
public class JConsole extends JScrollPane implements GUIConsoleInterface, Runnable, KeyListener, MouseListener, ActionListener, PropertyChangeListener
A JFC/Swing based console for the BeanShell desktop. This is a descendant of the old AWTConsole. Improvements by: Mark Donszelmann (Mark.Donszelmann@cern.ch) including Cut and Paste Improvements by: Daniel Leuck including Color and Image support, key press bug workaround- 另请参阅:
- 序列化表格
-
-
嵌套类概要
嵌套类 修饰符和类型 类 说明 static classJConsole.BlockingPipedInputStreamThe overridden read method in this class will not throw "Broken pipe" IOExceptions; It will simply wait for new writers and data.-
从类继承的嵌套类/接口 javax.swing.JScrollPane
JScrollPane.AccessibleJScrollPane, JScrollPane.ScrollBar
-
从类继承的嵌套类/接口 javax.swing.JComponent
JComponent.AccessibleJComponent
-
从类继承的嵌套类/接口 java.awt.Container
Container.AccessibleAWTContainer
-
-
字段概要
-
从类继承的字段 javax.swing.JScrollPane
columnHeader, horizontalScrollBar, horizontalScrollBarPolicy, lowerLeft, lowerRight, rowHeader, upperLeft, upperRight, verticalScrollBar, verticalScrollBarPolicy, viewport
-
从类继承的字段 javax.swing.JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
-
从类继承的字段 java.awt.Component
accessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
-
从接口继承的字段 java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
-
从接口继承的字段 javax.swing.ScrollPaneConstants
COLUMN_HEADER, HORIZONTAL_SCROLLBAR, HORIZONTAL_SCROLLBAR_ALWAYS, HORIZONTAL_SCROLLBAR_AS_NEEDED, HORIZONTAL_SCROLLBAR_NEVER, HORIZONTAL_SCROLLBAR_POLICY, LOWER_LEADING_CORNER, LOWER_LEFT_CORNER, LOWER_RIGHT_CORNER, LOWER_TRAILING_CORNER, ROW_HEADER, UPPER_LEADING_CORNER, UPPER_LEFT_CORNER, UPPER_RIGHT_CORNER, UPPER_TRAILING_CORNER, VERTICAL_SCROLLBAR, VERTICAL_SCROLLBAR_ALWAYS, VERTICAL_SCROLLBAR_AS_NEEDED, VERTICAL_SCROLLBAR_NEVER, VERTICAL_SCROLLBAR_POLICY, VIEWPORT
-
-
构造器概要
构造器 构造器 说明 JConsole()JConsole(InputStream cin, OutputStream cout)
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 voidactionPerformed(ActionEvent event)voiderror(Object o)ColorgetCommandColor()Get command colorPointgetDisplayPoint()Get popup window display pointPrintStreamgetErr()ReadergetIn()InputStreamgetInputStream()PrintStreamgetOut()JTextPanegetTextPane()Get TextPanevoidkeyPressed(KeyEvent e)voidkeyReleased(KeyEvent e)voidkeyTyped(KeyEvent e)voidmouseClicked(MouseEvent event)voidmouseEntered(MouseEvent event)voidmouseExited(MouseEvent event)voidmousePressed(MouseEvent event)voidmouseReleased(MouseEvent event)voidprint(Object o)voidprint(Object s, Color color)voidprint(Object s, Font font)voidprint(Object o, Font font, Color color)voidprint(Object s, String fontFamilyName, int size, Color color)voidprint(Object o, String fontFamilyName, int size, Color color, boolean bold, boolean italic, boolean underline)voidprint(Icon icon)voidprintln()Prints "\\n" (i.e. newline)voidprintln(Object o)voidprintln(Icon icon)voidpropertyChange(PropertyChangeEvent event)voidrequestFocus()voidrun()voidsetCommandColor(Color value)Set command colorvoidsetFont(Font font)voidsetNameCompletion(NameCompletion nc)AttributeSetsetStyle(Color color)AttributeSetsetStyle(Font font)AttributeSetsetStyle(Font font, Color color)voidsetWaitFeedback(boolean on)StringtoString()voidupdateOut()Update out - test failed-
从类继承的方法 javax.swing.JScrollPane
createHorizontalScrollBar, createVerticalScrollBar, createViewport, getAccessibleContext, getColumnHeader, getCorner, getHorizontalScrollBar, getHorizontalScrollBarPolicy, getRowHeader, getUI, getUIClassID, getVerticalScrollBar, getVerticalScrollBarPolicy, getViewport, getViewportBorder, getViewportBorderBounds, isValidateRoot, isWheelScrollingEnabled, paramString, setColumnHeader, setColumnHeaderView, setComponentOrientation, setCorner, setHorizontalScrollBar, setHorizontalScrollBarPolicy, setLayout, setRowHeader, setRowHeaderView, setUI, setVerticalScrollBar, setVerticalScrollBarPolicy, setViewport, setViewportBorder, setViewportView, setWheelScrollingEnabled, updateUI
-
从类继承的方法 javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, 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, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, 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, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
-
从类继承的方法 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, transferFocusDownCycle, validate, validateTree
-
从类继承的方法 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, 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, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCycle
-
-
-
-
构造器详细资料
-
JConsole
public JConsole()
-
JConsole
public JConsole(InputStream cin, OutputStream cout)
-
-
方法详细资料
-
getInputStream
public InputStream getInputStream()
-
getIn
public Reader getIn()
- 指定者:
getIn在接口中ConsoleInterface
-
getOut
public PrintStream getOut()
- 指定者:
getOut在接口中ConsoleInterface
-
getErr
public PrintStream getErr()
- 指定者:
getErr在接口中ConsoleInterface
-
getTextPane
public JTextPane getTextPane()
Get TextPane- 返回:
- TextPane
-
getCommandColor
public Color getCommandColor()
Get command color- 返回:
- Command color
-
setCommandColor
public void setCommandColor(Color value)
Set command color- 参数:
value- Command color
-
updateOut
public void updateOut()
Update out - test failed
-
requestFocus
public void requestFocus()
- 覆盖:
requestFocus在类中JComponent
-
keyPressed
public void keyPressed(KeyEvent e)
- 指定者:
keyPressed在接口中KeyListener
-
keyTyped
public void keyTyped(KeyEvent e)
- 指定者:
keyTyped在接口中KeyListener
-
keyReleased
public void keyReleased(KeyEvent e)
- 指定者:
keyReleased在接口中KeyListener
-
getDisplayPoint
public Point getDisplayPoint()
Get popup window display point- 返回:
- Point
-
println
public void println(Object o)
- 指定者:
println在接口中ConsoleInterface
-
print
public void print(Object o)
- 指定者:
print在接口中ConsoleInterface
-
println
public void println()
Prints "\\n" (i.e. newline)
-
error
public void error(Object o)
- 指定者:
error在接口中ConsoleInterface
-
println
public void println(Icon icon)
-
print
public void print(Icon icon)
-
print
public void print(Object s, Color color)
- 指定者:
print在接口中GUIConsoleInterface
-
print
public void print(Object o, String fontFamilyName, int size, Color color, boolean bold, boolean italic, boolean underline)
-
setStyle
public AttributeSet setStyle(Font font)
-
setStyle
public AttributeSet setStyle(Color color)
-
setStyle
public AttributeSet setStyle(Font font, Color color)
-
setFont
public void setFont(Font font)
- 覆盖:
setFont在类中JComponent
-
mouseClicked
public void mouseClicked(MouseEvent event)
- 指定者:
mouseClicked在接口中MouseListener
-
mousePressed
public void mousePressed(MouseEvent event)
- 指定者:
mousePressed在接口中MouseListener
-
mouseReleased
public void mouseReleased(MouseEvent event)
- 指定者:
mouseReleased在接口中MouseListener
-
mouseEntered
public void mouseEntered(MouseEvent event)
- 指定者:
mouseEntered在接口中MouseListener
-
mouseExited
public void mouseExited(MouseEvent event)
- 指定者:
mouseExited在接口中MouseListener
-
propertyChange
public void propertyChange(PropertyChangeEvent event)
- 指定者:
propertyChange在接口中PropertyChangeListener
-
actionPerformed
public void actionPerformed(ActionEvent event)
- 指定者:
actionPerformed在接口中ActionListener
-
setNameCompletion
public void setNameCompletion(NameCompletion nc)
- 指定者:
setNameCompletion在接口中GUIConsoleInterface
-
setWaitFeedback
public void setWaitFeedback(boolean on)
- 指定者:
setWaitFeedback在接口中GUIConsoleInterface
-
-