All Packages Class Hierarchy This Package Previous Next Index
Class jp.kyasu.awt.text.TextController
java.lang.Object
|
+----jp.kyasu.awt.text.TextController
- public abstract class TextController
- extends Object
- implements MouseListener, MouseMotionListener, KeyListener, FocusListener, ClipboardOwner, Serializable
The TextController
class is an abstract base class that
controlls the TextView
object.
- Version:
- 18 Dec 1998
- Author:
- Kazuki YASUMATSU
- See Also:
- TextView
-
A_COPY
- The action name for the copy operation.
-
A_CUT
- The action name for the cut operation.
-
A_FIND
- The action name for the find operation.
-
A_PASTE
- The action name for the paste operation.
-
A_PRINT
- The action name for the print operation.
-
A_UNDO
- The action name for the undo operation.
-
L_COPY
- The label name for the copy operation.
-
L_CUT
- The label name for the cut operation.
-
L_EDIT
- The label name for the edit menu.
-
L_FIND
- The label name for the find operation.
-
L_PASTE
- The label name for the paste operation.
-
L_PRINT
- The label name for the print operation.
-
L_UNDO
- The label name for the undo operation.
-
TextController()
- Constructs a text controller.
-
focusGained(FocusEvent)
- Invoked when a component gains the keyboard focus.
-
focusLost(FocusEvent)
- Invoked when a component loses the keyboard focus.
-
getClipboardString()
- Returns the string in the clipboard.
-
getClipboardText()
- Returns the text in the clipboard.
-
getClipboardText(TextStyle)
- Returns the text in the clipboard with the specified text style.
-
getCutBufferText()
- Returns the text in the cut buffer.
-
getResourceString(String, String)
- Returns the resource string indicated by the specified key.
-
getView()
- Returns the view of this controller.
-
isClickToFocus()
- Tests if the controller requests the focus when the mouse is clicked.
-
isMouseFocus()
- Tests if the controller requests the focus when the mouse enters
the view.
-
isSelectionVisibleAtFocus()
- Tests if the selection becomes visible when the view is focused.
-
keyPressed(KeyEvent)
- Invoked when a key has been pressed.
-
keyReleased(KeyEvent)
- Invoked when a key has been released.
-
keyTyped(KeyEvent)
- Invoked when a key has been typed.
-
lostOwnership(Clipboard, Transferable)
- Notifies this object that it is no longer the owner of the contents
of the clipboard.
-
mouseClicked(MouseEvent)
- Invoked when the mouse has been clicked on a component.
-
mouseDragged(MouseEvent)
- Invoked when the mouse button is pressed on a component and then dragged.
-
mouseEntered(MouseEvent)
- Invoked when the mouse enters a component.
-
mouseExited(MouseEvent)
- Invoked when the mouse exits a component.
-
mouseMoved(MouseEvent)
- Invoked when the mouse button has been moved on a component.
-
mousePressed(MouseEvent)
- Invoked when the mouse has been pressed on a component.
-
mouseReleased(MouseEvent)
- Invoked when the mouse has been released on a component.
-
setClickToFocus()
- Makes the controller request the focus when the mouse is clicked.
-
setClipboardString(String)
- Sets the string to the clipboard.
-
setClipboardText(Text)
- Sets the text to the clipboard.
-
setCutBuffer(Text)
- Sets the text to the cut buffer.
-
setMouseFocus()
- Makes the controller request the focus when the mouse enters the view.
-
setSelectionVisibleAtFocus(boolean)
- Makes the selection become visible when the view is focused.
L_EDIT
public static final String L_EDIT
- The label name for the edit menu.
L_COPY
public static final String L_COPY
- The label name for the copy operation.
L_CUT
public static final String L_CUT
- The label name for the cut operation.
L_PASTE
public static final String L_PASTE
- The label name for the paste operation.
L_FIND
public static final String L_FIND
- The label name for the find operation.
L_UNDO
public static final String L_UNDO
- The label name for the undo operation.
L_PRINT
public static final String L_PRINT
- The label name for the print operation.
A_COPY
public static final String A_COPY
- The action name for the copy operation.
A_CUT
public static final String A_CUT
- The action name for the cut operation.
A_PASTE
public static final String A_PASTE
- The action name for the paste operation.
A_FIND
public static final String A_FIND
- The action name for the find operation.
A_UNDO
public static final String A_UNDO
- The action name for the undo operation.
A_PRINT
public static final String A_PRINT
- The action name for the print operation.
TextController
public TextController()
- Constructs a text controller.
getResourceString
public static String getResourceString(String s,
String def)
- Returns the resource string indicated by the specified key.
- See Also:
- getResourceString
getView
public abstract TextView getView()
- Returns the view of this controller.
isClickToFocus
public boolean isClickToFocus()
- Tests if the controller requests the focus when the mouse is clicked.
- Returns:
-
true
if the controller requests the focus when
the mouse is clicked, false
if the controller
requests the focus when the mouse enters the view.
- See Also:
- isMouseFocus
isMouseFocus
public boolean isMouseFocus()
- Tests if the controller requests the focus when the mouse enters
the view.
- See Also:
- isClickToFocus
setClickToFocus
public void setClickToFocus()
- Makes the controller request the focus when the mouse is clicked.
- See Also:
- isClickToFocus, setMouseFocus
setMouseFocus
public void setMouseFocus()
- Makes the controller request the focus when the mouse enters the view.
- See Also:
- isMouseFocus, setClickToFocus
isSelectionVisibleAtFocus
public boolean isSelectionVisibleAtFocus()
- Tests if the selection becomes visible when the view is focused.
- See Also:
- setSelectionVisibleAtFocus
setSelectionVisibleAtFocus
public void setSelectionVisibleAtFocus(boolean b)
- Makes the selection become visible when the view is focused.
- See Also:
- isSelectionVisibleAtFocus
mouseClicked
public void mouseClicked(MouseEvent e)
- Invoked when the mouse has been clicked on a component.
- See Also:
- MouseListener
mousePressed
public void mousePressed(MouseEvent e)
- Invoked when the mouse has been pressed on a component.
- See Also:
- MouseListener
mouseReleased
public void mouseReleased(MouseEvent e)
- Invoked when the mouse has been released on a component.
- See Also:
- MouseListener
mouseEntered
public void mouseEntered(MouseEvent e)
- Invoked when the mouse enters a component.
- See Also:
- MouseListener
mouseExited
public void mouseExited(MouseEvent e)
- Invoked when the mouse exits a component.
- See Also:
- MouseListener
mouseDragged
public void mouseDragged(MouseEvent e)
- Invoked when the mouse button is pressed on a component and then dragged.
- See Also:
- MouseMotionListener
mouseMoved
public void mouseMoved(MouseEvent e)
- Invoked when the mouse button has been moved on a component.
- See Also:
- MouseMotionListener
keyTyped
public void keyTyped(KeyEvent e)
- Invoked when a key has been typed.
- See Also:
- KeyListener
keyPressed
public void keyPressed(KeyEvent e)
- Invoked when a key has been pressed.
- See Also:
- KeyListener
keyReleased
public void keyReleased(KeyEvent e)
- Invoked when a key has been released.
- See Also:
- KeyListener
focusGained
public void focusGained(FocusEvent e)
- Invoked when a component gains the keyboard focus.
- See Also:
- FocusListener
focusLost
public void focusLost(FocusEvent e)
- Invoked when a component loses the keyboard focus.
- See Also:
- FocusListener
lostOwnership
public synchronized void lostOwnership(Clipboard clipboard,
Transferable contents)
- Notifies this object that it is no longer the owner of the contents
of the clipboard.
- See Also:
- ClipboardOwner
getCutBufferText
public static synchronized Text getCutBufferText()
- Returns the text in the cut buffer.
setCutBuffer
public static synchronized void setCutBuffer(Text text)
- Sets the text to the cut buffer.
getClipboardText
public Text getClipboardText()
- Returns the text in the clipboard.
getClipboardText
public Text getClipboardText(TextStyle style)
- Returns the text in the clipboard with the specified text style.
setClipboardText
public void setClipboardText(Text text)
- Sets the text to the clipboard.
getClipboardString
public synchronized String getClipboardString()
- Returns the string in the clipboard.
setClipboardString
public synchronized void setClipboardString(String str)
- Sets the string to the clipboard.
All Packages Class Hierarchy This Package Previous Next Index