public final class CodeEditor extends Editor implements javax.swing.event.CaretListener, oracle.ide.ceditor.find.FindableEditor, BasicEditorPaneContainer, ToolTipProvider, javax.swing.event.UndoableEditListener, BaseLayoutListener, PopupManager, TextEditor, java.beans.PropertyChangeListener
CodeEditor
is the integration layer between the IDE
and the editor components to provide a code editor inside the IDE. There are some public methods available for getting the state of the editor component, such as where the cursor position is, and whether there is a selection. There are also public methods available for manipulating the cursor position or selection, and for mapping between offsets and lines.
Note: Public methods in this class involving line numbers are all 1-based. Contrast this with the LineMap interface in the TextBuffer which is 0-based. Do not get this mixed up! If you use both the LineMap and CodeEditor together, you will need to take this into account.
For clients that wish to install EditorPlugins to newly created
editors, register an EditorPluginsFactory
instance
using registerFactory()
. This method will be called
when an editor is created.
Modifier and Type | Class and Description |
---|---|
protected class |
CodeEditor.CEToolbar
Our override of the Toolbar class so that it is invisible when it is
empty.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
EDITOR_CONTEXT
Deprecated.
use CodeEditorCon
|
static java.lang.String |
TYPE_CPP
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_DIFF
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_HTML
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_IDL
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_JAVA
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_JS
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_JSP
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_PLAIN
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_PLSQL
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_PROPERTIES
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_SQL
Deprecated.
use CodeEditorConstants
|
static java.lang.String |
TYPE_XML
Deprecated.
use CodeEditorConstants
|
_addin, _context, ATTRIBUTE_BACKGROUND_COLOR, ATTRIBUTE_CUSTOM_HORIZONTAL_SCROLLBAR, ATTRIBUTE_CUSTOM_VERTICAL_SCROLLBAR, ATTRIBUTE_DELAY_PALETTE_LOAD, ATTRIBUTE_HORIZONTAL_BLOCK_INCREMENT, ATTRIBUTE_HORIZONTAL_SCROLLBAR_POLICY, ATTRIBUTE_HORIZONTAL_UNIT_INCREMENT, ATTRIBUTE_MENU_ID, ATTRIBUTE_OLD_EDITOR, ATTRIBUTE_SCROLLABLE, ATTRIBUTE_VERTICAL_BLOCK_INCREMENT, ATTRIBUTE_VERTICAL_SCROLLBAR_POLICY, ATTRIBUTE_VERTICAL_UNIT_INCREMENT, CUSTOM_BORDER, PROPERTY_FIXED_BOTTOM_MARGIN, PROPERTY_FIXED_LEFT_MARGIN, PROPERTY_FIXED_RIGHT_MARGIN, PROPERTY_FIXED_TOP_MARGIN, PROPERTY_SCROLLABLE_LEFT_MARGIN, PROPERTY_SCROLLABLE_TOP_MARGIN
EMPTY_SELECTION, PROJECT_PROP, VISIBLE_PROP, WORKSPACE_PROP
Constructor and Description |
---|
CodeEditor()
Constructs a new Code Editor which makes use of the editor package.
|
Modifier and Type | Method and Description |
---|---|
void |
addCEToolTipProvider(CEToolTipProvider provider)
Registers a
CEToolTipProvider implementation to
receive requests for tooltip information when the mouse travels
over the code editor. |
void |
addCursorListener(CursorListener listener)
Adds a
CursorListener to the list of cursor listeners. |
void |
addCursorListener(CursorListener listener,
boolean batchEvents)
Adds a
CursorListener to the list of cursor listeners. |
void |
addHelpableProvider(HelpableProvider helpableProvider)
Adds a
HelpableProvider for this class from which the
code editor can retrieve help info. |
protected boolean |
canCopy()
Deprecated.
|
protected boolean |
canCut()
Deprecated.
|
protected boolean |
canPaste()
Deprecated.
|
void |
caretUpdate(javax.swing.event.CaretEvent event)
Called when the caret position is updated.
|
void |
changeDocumentType(java.lang.String highlightingType)
Change the syntax highlighting type to use for this current CodeEditor
instance.
|
void |
close()
Close this editor - this gives us a chance to clean up any resources.
|
void |
close(Layout layout)
Close the given
Layout . |
static HighlightStyle |
createHighlightStyle(java.lang.String internalName,
java.lang.String publicName,
int priority,
java.awt.Color fgColor,
java.awt.Color bgColor)
Utility routine to create a new highlight style with background and
foreground attributes.
|
static HighlightStyle |
createHighlightStyle(java.lang.String internalName,
java.lang.String publicName,
int priority,
java.awt.Color fgColor,
java.awt.Color bgColor,
int fontStyle,
int underlinePredefine,
java.awt.Color underlineColor)
Utility routine to create a new highlight style with background,
foreground, font, and underline attributes.
|
int |
getCaretLine()
Return the line that the caret is on.
|
int |
getCaretPosition()
Returns the position of the text insertion caret for the
editor component.
|
static CodeEditor |
getCodeEditor(BasicEditorPane editor)
Fetch the Code Editor associated with the given editor component.
|
static Context |
getContext(BasicEditorPane editor)
Fetch the IDE context associated with the given editor component.
|
Controller |
getController()
Gets the
Controller associated with this view. |
java.awt.Component |
getDefaultFocusComponent()
This method is used to know what component should get the focus by default.
|
java.lang.Object |
getEditorAttribute(java.lang.String attribute) |
protected java.lang.String |
getEditorText()
Get the contents of the editor as a String for refreshing the
IDE buffer.
|
FileOverviewMargin |
getFileOverviewMargin()
Deprecated.
getOverview()
|
java.awt.Component |
getFixedBottomMargin() |
java.awt.Component |
getFixedRightMargin() |
java.awt.Component |
getFixedTopMargin() |
BasicEditorPane |
getFocusedEditorPane()
Fetches the focused (active) editor pane embedded in the editor
in which to perform Find operations on.
|
java.awt.Component |
getGUI()
Get the view's root graphical user interface component.
|
CodeEditorGutter |
getGutter()
Fetches the gutter associated with this editor on the left margin.
|
HelpableProvider |
getHelpableProvider()
Deprecated.
|
HelpInfo |
getHelpInfo()
Fetch the
HelpInfo topic to display for this view. |
int |
getLineCount()
Fetches the number of lines in this
TextBuffer . |
int |
getLineEndOffset(int line)
Given a specified line, returns the offset from the beginning
of a
TextBuffer that the line ends at. |
int |
getLineFromOffset(int offset)
Given an offset from the beginning of the underlying
TextBuffer , fetches the line number containing that
offset using a Forward bias. |
int |
getLineStartOffset(int line)
Given a specified line, returns the offset from the beginning
of the
TextBuffer for the start of the line. |
BasicEditorOverview |
getOverview() |
java.awt.Component |
getScrollableLeftMargin() |
java.lang.String |
getSelectedText()
Returns the selected text contained in this TextComponent.
|
int |
getSelectionEnd()
Returns the end position of the current text selection.
|
protected Element[] |
getSelectionFromUI()
This method retrieve's the selection in this View directly from the UI.
|
int |
getSelectionStart()
Returns the start position of the current text selection.
|
javax.swing.Icon |
getTabIcon()
Get the Icon to use when displaying this View as a tab in a JTabbedPane
host such as the EditorFrame.
|
java.lang.String |
getText(int offset,
int length)
Fetches a portion of the text represented by the component.
|
Toolbar |
getToolbar()
Get the Toolbar that is the fixed top margin above the code editor
view.
|
java.lang.String |
getToolTipText(BasicEditorPane editorPane,
java.awt.event.MouseEvent mouseEvent,
int offset)
Requests from the editor client an appropriate tooltip to display
for the given editor.
|
boolean |
gotoLine(int line,
int column,
boolean highlightLine)
Moves the current cursor position to the beginning of the
indicated line, and highlight the line if it is requested.
|
boolean |
gotoOffset(int offset,
int selectionLength)
Moves the current cursor position to the given offset, and
selects up to the given length after that offset.
|
boolean |
hasSelectedText()
Return whether or not there is any text selected.
|
void |
hidePopup(BasicEditorPane editorPane)
Informs the editor client that the popup menu (if showing) should
now be hidden.
|
void |
init(Layout layout)
Initialize this editor's layout information from the given
Layout instance. |
void |
loadSettings(StructuredPropertyAccess node)
Reloads the editor settings.
|
void |
moveCaretPosition(int offset)
Moves the caret to a new position, leaving behind a mark defined
by the last time setCaretPosition was called.
|
void |
open()
Open this editor on the context set by a prior call to
setContext.
|
void |
propertyChange(java.beans.PropertyChangeEvent event) |
static void |
registerFactory(EditorPluginsFactory factory)
Deprecated.
declarative registration via the ceditor.plugin or ceditor.plugin-factory hook is preferred
|
static void |
registerNodeType(java.lang.Class nodeClass,
java.lang.String highlightingType)
Registers the given node class for the given syntax
highlighting type to use.
|
static void |
registerViewLimitProviderFactory(ViewLimitProviderFactory factory)
Register a ViewLimitProviderFactory with the code editor.
|
static void |
registerViewSelectionHelperFactory(ViewSelectionHelperFactory factory)
Register a ViewSelectionHelperFactory with the code editor.
|
void |
removeCEToolTipProvider(CEToolTipProvider provider)
Deregisters a previously registered
CEToolTipProvider
implementation when it no longer wants to handle tooltip requests. |
void |
removeCursorListener(CursorListener listener)
Removes a
CursorListener from the list of cursor listeners. |
void |
removeHelpableProvider(HelpableProvider helpableProvider)
Removes a previously registered
HelpableProvider . |
void |
replaceSelection(java.lang.String content)
Replaces the currently selected content with the new content
represented by the given String.
|
void |
save(Layout layout)
Save this editor's layout information to the given
Layout instance. |
void |
saveSettings(StructuredPropertyAccess node)
Saves the editor settings.
|
void |
setCaretPosition(int offset)
Sets the position of the text insertion caret for the editor
component.
|
void |
setContext(Context context)
Set the context behind this editor.
|
void |
setFixedBottomMarginComponent(javax.swing.JComponent panel)
Installs a panel at the bottom of the code editor.
|
void |
setHelpableProvider(HelpableProvider helpableProvider)
Deprecated.
|
void |
setHelpInfo(HelpInfo helpInfo)
Sets the default help info topic that this code editor displays.
|
void |
setSelectionEnd(int selectionEnd)
Sets the end of the selection to the specified position.
|
void |
setSelectionStart(int selectionStart)
Sets the start of the selection to the specified position.
|
void |
setToolbarHelpInfo(HelpInfo helpInfo)
Sets the default help info topic that the code editor toolbar displays.
|
void |
showPopup(BasicEditorPane editorPane,
java.awt.event.MouseEvent mouseEvent)
Informs the editor client that the user requested a popup menu in
the given editor pane, at the location specified in the
mouseEvent.
|
void |
undoableEditHappened(javax.swing.event.UndoableEditEvent event)
An UndoableEdit happened in the editor.
|
void |
update(java.lang.Object observed,
UpdateMessage change)
Notification message.
|
addPreferredLayoutListener, addPropertyChangeListener, editorHidden, editorShown, firePropertyChangeEvent, getBottomComponent, getContext, getContextMenu, getDependentNodes, getDisplayName, getEditorAddin, getFixedLeftMargin, getMiniToolbar, getPreferredLayoutBaseName, getPreferredLayoutURL, getScrollableTopMargin, getTabDescription, getTabLabel, getTitleLabel, getType, initializeActiveLayout, initializeLayout, isReady, newId, prepareForSaving, removePreferredLayoutListener, removePropertyChangeListener, setEditorAddin, setEditorAttribute, setPreferredLayoutBaseName, setPreferredLayoutURL, setType
activate, addViewListener, addViewSelectionListener, addViewStateListener, deactivate, fireViewCollapsed, fireViewExpanded, fireViewSelectionChanged, getContext, getId, getSelection, getTabName, getViewWithoutDecoration, isVisible, loadLayout, loadManifestToolbar, loadManifestToolbar, owner, removeViewListener, removeViewSelectionListener, removeViewStateListener, saveLayout, scheduleUpdateSelection, setId, setOwner, setToolbarVisible, show, toString, updateSelection, updateSelectionImpl, updateTitle, updateToolbarActions, updateVisibleActions, updateVisibleActions
@Deprecated public static final java.lang.String EDITOR_CONTEXT
@Deprecated public static final java.lang.String TYPE_PLAIN
@Deprecated public static final java.lang.String TYPE_JAVA
@Deprecated public static final java.lang.String TYPE_SQL
@Deprecated public static final java.lang.String TYPE_PLSQL
@Deprecated public static final java.lang.String TYPE_JSP
@Deprecated public static final java.lang.String TYPE_HTML
@Deprecated public static final java.lang.String TYPE_XML
@Deprecated public static final java.lang.String TYPE_PROPERTIES
@Deprecated public static final java.lang.String TYPE_IDL
@Deprecated public static final java.lang.String TYPE_CPP
@Deprecated public static final java.lang.String TYPE_JS
@Deprecated public static final java.lang.String TYPE_DIFF
public CodeEditor()
@Deprecated public static void registerFactory(EditorPluginsFactory factory)
EditorPluginsFactory
with the CodeEditor
so that when a new Code Editor is created, the factory is given
a chance to create EditorPlugins to be installed into the editor
based on the node type that the Code Editor was created with.factory
- the EditorPluginsFactory to registerpublic static void registerNodeType(java.lang.Class nodeClass, java.lang.String highlightingType)
TYPE_*
public constants
specified in this class. The provided node class MUST
implement the TextNode
interface, as only
TextNode
implementations are editable by the
code editor.nodeClass
- the class of the node to registerhighlightingType
- the syntax highlighting type to usepublic void changeDocumentType(java.lang.String highlightingType)
TYPE_*
public constants specified in this class.highlightingType
- the syntax highlighting type to usepublic static HighlightStyle createHighlightStyle(java.lang.String internalName, java.lang.String publicName, int priority, java.awt.Color fgColor, java.awt.Color bgColor)
internalName
- the (unique) name of the style used internally for
registration purposespublicName
- the (translated) name of the style that can be
displayed by the UI to identify the style to userspriority
- the priority of the highlight when rendering (1-100)fgColor
- the color to use for the foreground of the text, null
not to change the foreground of the textbgColor
- the color to use for the background of the text, null
not to change the background of the textpublic static HighlightStyle createHighlightStyle(java.lang.String internalName, java.lang.String publicName, int priority, java.awt.Color fgColor, java.awt.Color bgColor, int fontStyle, int underlinePredefine, java.awt.Color underlineColor)
internalName
- the (unique) name of the style used internally for
registration purposespublicName
- the (translated) name of the style that can be
displayed by the UI to identify the style to userspriority
- the priority of the highlight when rendering (1-100)fgColor
- the color to use for the foreground of the text, null
not to change the foreground of the textbgColor
- the color to use for the background of the text, null
not to change the background of the textfontStyle
- the font style to use, such as Font.BOLDunderlinePredefine
- the underline predefined index to use, such as
HighlightRegistry.SINGLE_UNDERLINE, or -1 for noneunderlineColor
- the underline color to use, or null for nonepublic Toolbar getToolbar()
getToolbar
in class View
public void setFixedBottomMarginComponent(javax.swing.JComponent panel)
This method must be called during the plugins installation, the panel will not appear if the method is called after the editor has been displayed.
This panel will be shared among the different plugins. If a panel has already been installed, this method will throw.
panel
- The panel to show at the bottom of the editor.getFixedBottomMargin()
public java.lang.String getText(int offset, int length) throws javax.swing.text.BadLocationException
offset
- the starting offset >= 0length
- the length to retrieve >= 0javax.swing.text.BadLocationException
- if the offset or length are invalidpublic void setCaretPosition(int offset)
offset
- the new caret position to setpublic void moveCaretPosition(int offset)
offset
- the offset to move the caret tosetCaretPosition(int)
public int getCaretPosition()
public int getCaretLine()
public void replaceSelection(java.lang.String content)
content
- the new content to replace the current selectionpublic boolean hasSelectedText()
public java.lang.String getSelectedText()
java.lang.IllegalArgumentException
- if the selection doesn't
have a valid mapping into the document for some reasonpublic int getSelectionStart()
public int getSelectionEnd()
public void setSelectionStart(int selectionStart)
selectionStart
- the new start of the selectionpublic void setSelectionEnd(int selectionEnd)
selectionEnd
- the new end of the selectionpublic void addCursorListener(CursorListener listener)
CursorListener
to the list of cursor listeners.
Cursor listeners are notifed to changes in the caret position.
Cursor listeners added here are notified immediately of caret position changes
(same as calling addCursorListener(listener, false);listener
- the listener to addpublic void addCursorListener(CursorListener listener, boolean batchEvents)
CursorListener
to the list of cursor listeners.
Cursor listeners are notifed to changes in the caret position.listener
- the listener to addbatchEvents
- if true quick cursor changes will be grouped into
one notification. if false listeners will be notified of every caret change.public void removeCursorListener(CursorListener listener)
CursorListener
from the list of cursor listeners.listener
- the listener to removepublic CodeEditorGutter getGutter()
@Deprecated public FileOverviewMargin getFileOverviewMargin()
public BasicEditorOverview getOverview()
public void addCEToolTipProvider(CEToolTipProvider provider)
CEToolTipProvider
implementation to
receive requests for tooltip information when the mouse travels
over the code editor.provider
- the tooltip provider to registerpublic void removeCEToolTipProvider(CEToolTipProvider provider)
CEToolTipProvider
implementation when it no longer wants to handle tooltip requests.provider
- the provider to deregisterpublic boolean gotoOffset(int offset, int selectionLength)
offset
- the offset to move the cursor to (zero-based)selectionLength
- the length of the selection, 0 if not desired.public boolean gotoLine(int line, int column, boolean highlightLine)
gotoLine
in interface TextEditor
line
- the line to go to (one-based)column
- the column to go to (one-based)highlightLine
- whether to highlight the specified linepublic BasicEditorPane getFocusedEditorPane()
getFocusedEditorPane
in interface BasicEditorPaneContainer
BasicEditorPane
that currently has focuspublic void showPopup(BasicEditorPane editorPane, java.awt.event.MouseEvent mouseEvent)
showPopup
in interface PopupManager
editorPane
- the editorPane that the user request occurred inmouseEvent
- the mouse event describing the location of the
popup request.public void hidePopup(BasicEditorPane editorPane)
hidePopup
in interface PopupManager
editorPane
- the editorPane for which the popup should be hiddenpublic void propertyChange(java.beans.PropertyChangeEvent event)
propertyChange
in interface java.beans.PropertyChangeListener
public void caretUpdate(javax.swing.event.CaretEvent event)
caretUpdate
in interface javax.swing.event.CaretListener
event
- the caret eventpublic int getLineCount()
TextBuffer
. For
example, a 5-line TextBuffer
has lines 0 through 4.TextBuffer
public int getLineFromOffset(int offset)
TextBuffer
, fetches the line number containing that
offset using a Forward bias. This means if line A starts with
offset B, and previous line A-1 ends with offset B,
getLineFromOffset(B)
will return line A.public int getLineStartOffset(int line)
TextBuffer
for the start of the line.line
- a line in the TextBuffer
public int getLineEndOffset(int line)
TextBuffer
that the line ends at.line
- a line in the TextBuffer
public static Context getContext(BasicEditorPane editor)
editor
- the editor paneprotected Element[] getSelectionFromUI()
View
getSelectionFromUI
in class View
public static void registerViewSelectionHelperFactory(ViewSelectionHelperFactory factory)
public static void registerViewLimitProviderFactory(ViewLimitProviderFactory factory)
public static CodeEditor getCodeEditor(BasicEditorPane editor)
editor
- the editor panepublic void setContext(Context context)
setContext
in class Editor
public void open()
open
in class Editor
Editor.setContext(oracle.ide.Context)
public java.awt.Component getDefaultFocusComponent()
getDefaultFocusComponent
in class Editor
public void close()
public Controller getController()
Controller
associated with this view.getController
in interface ControllerProvider
getController
in class Editor
public java.lang.Object getEditorAttribute(java.lang.String attribute)
getEditorAttribute
in class Editor
attribute
- takes values from ATTRIBUTE_ constants.public void saveSettings(StructuredPropertyAccess node)
Editor
Example:
public void saveSettings(Element element) { String value = "value"; element.setAttribute("key", value); Node ownerNode = element.getOwnerNode(); for(int i=0;i<3;i++) { Element subElement = ownerNode.createElement("sub"); String subValue = "sub-value-"+i; subElement.setAttribute("sub-key", subValue); element.appendChild(subElement); } }
saveSettings
in class Editor
public void loadSettings(StructuredPropertyAccess node)
Editor
This method will be called when the the product is restarted but also when an editor is split. If the new editor is of the same type as the original, the settings will be taken from the original (saveSettings) and will be applied to the new editor (loadSettings). If your editor needs to make the difference, it can test for the element.getName() which will return "DUPLICATON". Example:
String value = element.getAttribute("key"); System.out.println("value = " + value); NodeList childNodes = element.getChildNodes(); int length = childNodes.getLength(); for(int i=0;i<length;i++) { Node childNode = childNodes.item(i); if ("sub".equals(childNode.getNodeName())) { Element subElement = (Element) childNode; String subValue = subElement.getAttribute("sub-key"); System.out.println("subValue = " + subValue); } }
loadSettings
in class Editor
public java.awt.Component getGUI()
public java.awt.Component getScrollableLeftMargin()
getScrollableLeftMargin
in class Editor
public java.awt.Component getFixedRightMargin()
getFixedRightMargin
in class Editor
public java.awt.Component getFixedTopMargin()
getFixedTopMargin
in class Editor
public java.awt.Component getFixedBottomMargin()
getFixedBottomMargin
in class Editor
public javax.swing.Icon getTabIcon()
getTabIcon
in class Editor
Editor
public void update(java.lang.Object observed, UpdateMessage change)
public java.lang.String getToolTipText(BasicEditorPane editorPane, java.awt.event.MouseEvent mouseEvent, int offset)
getToolTipText
in interface ToolTipProvider
editorPane
- the editor where the tooltip will be displayedmouseEvent
- the mouse event that generated the tooltipoffset
- the document offset where the mouse cursor is locatedpublic void undoableEditHappened(javax.swing.event.UndoableEditEvent event)
undoableEditHappened
in interface javax.swing.event.UndoableEditListener
public void save(Layout layout)
Layout
instance.
The code editor saves the caret position and the vertical scrollbar value.
save
in interface BaseLayoutListener
layout
- the Layout
instancepublic void init(Layout layout)
Layout
instance.
The code editor restores the caret position and the vertical
scrollbar value from the values stored in the Layout
instance.
init
in interface BaseLayoutListener
layout
- the Layout
instancepublic void close(Layout layout)
Layout
.close
in interface BaseLayoutListener
layout
- the Layout
instancepublic HelpInfo getHelpInfo()
HelpInfo
topic to display for this view.getHelpInfo
in interface Helpable
getHelpInfo
in class View
public void setHelpInfo(HelpInfo helpInfo)
helpInfo
- the default help info topic that should be displayedpublic void setToolbarHelpInfo(HelpInfo helpInfo)
helpInfo
- the default help info topic that should be displayed for the toolbarpublic void addHelpableProvider(HelpableProvider helpableProvider)
HelpableProvider
for this class from which the
code editor can retrieve help info. This can be used to return
context-sensitive help info for the current editor caret
position. Note that the code editor will query registered
HelpableProvider's until it gets the first non-null help info.
To change the default non-context-sensitive help topic, use
setHelpInfo() instead.helpableProvider
- the helpable provider to registerpublic void removeHelpableProvider(HelpableProvider helpableProvider)
HelpableProvider
.helpableProvider
- the helpableProvider to deregister@Deprecated public void setHelpableProvider(HelpableProvider helpableProvider)
HelpableProvider
for this class. ThehelpableProvider
- The class to delegate to for help.@Deprecated public HelpableProvider getHelpableProvider()
HelpableProvider
for this class if one exists,
othewise null
will be returned. This is deprecated
and will always return null.protected java.lang.String getEditorText()
@Deprecated protected boolean canCut()
@Deprecated protected boolean canCopy()
@Deprecated protected boolean canPaste()