public class PdeTextArea extends JEditTextArea
Modifier and Type | Field and Description |
---|---|
static String |
BREAK_MARKER |
static String |
STEP_MARKER |
LEFT_OF_SCROLLBAR, leftHandGutter
TOOL_TIP_TEXT_KEY, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
Constructor and Description |
---|
PdeTextArea(TextAreaDefaults defaults,
InputHandler inputHandler,
Editor editor) |
Modifier and Type | Method and Description |
---|---|
int |
_offsetToX(int line,
int offset)
Convert a character offset to a horizontal pixel position inside
the text area.
|
void |
clearGutterText()
Clear all gutter text.
|
void |
clearGutterText(int lineIdx)
Clear the gutter text of a specific line.
|
Editor |
getEditor() |
Image |
getGutterGradient() |
String |
getGutterText(int lineIdx)
Retrieve the gutter text of a specific line.
|
void |
setGutterText(int lineIdx,
String text)
Set the gutter text of a specific line.
|
void |
setMode(Mode mode) |
int |
xToOffset(int line,
int x)
Convert a horizontal pixel position to a character offset.
|
addCaretListener, blinkCaret, copy, copyAsHTML, cut, getBracketLine, getBracketPosition, getCaretLine, getCaretPosition, getDefaults, getDocument, getDocumentLength, getElectricScroll, getFirstLine, getHorizontalOffset, getHorizontalScrollPosition, getInputHandler, getInputMethodRequests, getLastLine, getLineCount, getLineLength, getLineOfOffset, getLineSelectionStopOffset, getLineStartNonWhiteSpaceOffset, getLineStartOffset, getLineStopNonWhiteSpaceOffset, getLineStopOffset, getLineText, getLineText, getMagicCaretPosition, getMarkLine, getMarkPosition, getPainter, getRightClickPopup, getScrollPosition, getSelectedText, getSelectionStart, getSelectionStart, getSelectionStartLine, getSelectionStop, getSelectionStop, getSelectionStopLine, getText, getText, getText, getTextAsHtml, getTokenMarker, getVerticalScrollPosition, getVisibleLines, isCaretBlinkEnabled, isCaretVisible, isEditable, isOverwriteEnabled, isSelectionActive, lineToY, offsetToX, overwriteSetSelectedText, paste, processKeyEvent, recalculateVisibleLines, removeCaretListener, removeNotify, scrollTo, scrollToCaret, select, selectAll, selectNone, setCaretBlinkEnabled, setCaretPosition, setCaretVisible, setDocument, setDocument, setEditable, setElectricScroll, setFirstLine, setHorizontalOffset, setHorizontalScrollPosition, setInputHandler, setMagicCaretPosition, setOrigin, setOverwriteEnabled, setRightClickPopup, setScrollPosition, setSelectedText, setSelectedText, setSelectionEnd, setSelectionStart, setText, setTokenMarker, setVerticalScrollPosition, updateScrollBars, xyToOffset, yToLine
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, 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, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update, updateUI
add, add, add, add, add, addContainerListener, 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, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, 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, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
public static final String BREAK_MARKER
public static final String STEP_MARKER
public PdeTextArea(TextAreaDefaults defaults, InputHandler inputHandler, Editor editor)
public Image getGutterGradient()
public void setMode(Mode mode)
public void setGutterText(int lineIdx, String text)
lineIdx
- the line index (0-based)text
- the textpublic void clearGutterText(int lineIdx)
lineIdx
- the line index (0-based)public void clearGutterText()
public String getGutterText(int lineIdx)
lineIdx
- the line index (0-based)public int _offsetToX(int line, int offset)
_offsetToX
in class JEditTextArea
line
- the 0-based line numberoffset
- the character offset (0 is the first character on a line)public int xToOffset(int line, int x)
xToOffset
in class JEditTextArea
line
- the 0-based line numberx
- the horizontal pixel positionpublic Editor getEditor()