Package org.exbin.bined.swing.basic
Class CodeArea
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- javax.swing.JComponent
-
- org.exbin.bined.swing.CodeAreaCore
-
- org.exbin.bined.swing.basic.CodeArea
-
- All Implemented Interfaces:
java.awt.image.ImageObserver
,java.awt.MenuContainer
,java.io.Serializable
,org.exbin.bined.capability.BackgroundPaintCapable
,org.exbin.bined.capability.BasicScrollingCapable
,org.exbin.bined.capability.CaretCapable
,org.exbin.bined.capability.ClipboardCapable
,org.exbin.bined.capability.CodeCharactersCaseCapable
,org.exbin.bined.capability.CodeTypeCapable
,org.exbin.bined.capability.EditModeCapable
,org.exbin.bined.capability.CharsetCapable
,org.exbin.bined.capability.RowWrappingCapable
,org.exbin.bined.capability.ScrollingCapable
,org.exbin.bined.capability.SelectionCapable
,org.exbin.bined.capability.ViewModeCapable
,org.exbin.bined.CodeAreaControl
,org.exbin.bined.DataProvider
,DefaultCodeArea
,AntialiasingCapable
,BasicColorsCapable
,FontCapable
,CodeAreaSwingControl
@ParametersAreNonnullByDefault public class CodeArea extends CodeAreaCore implements DefaultCodeArea, CodeAreaSwingControl
Code area component.- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class javax.swing.JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
-
-
Constructor Summary
Constructors Constructor Description CodeArea()
Creates new instance with default command handler and painter.CodeArea(CodeAreaCommandHandler.CodeAreaCommandHandlerFactory commandHandlerFactory)
Creates new instance with provided command handler factory method.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addCaretMovedListener(org.exbin.bined.CaretMovedListener caretMovedListener)
void
addEditModeChangedListener(org.exbin.bined.EditModeChangedListener editModeChangedListener)
void
addScrollingListener(org.exbin.bined.ScrollingListener scrollingListener)
void
addSelectionChangedListener(org.exbin.bined.SelectionChangedListener selectionChangedListener)
void
centerOnCursor()
void
centerOnPosition(long dataPosition, int dataOffset, org.exbin.bined.CodeAreaSection section)
void
centerOnPosition(org.exbin.bined.CodeAreaCaretPosition caretPosition)
void
clearSelection()
org.exbin.bined.CodeAreaCaretPosition
computeMovePosition(org.exbin.bined.CodeAreaCaretPosition position, org.exbin.bined.basic.MovementDirection direction)
org.exbin.bined.basic.CodeAreaScrollPosition
computeScrolling(org.exbin.bined.basic.CodeAreaScrollPosition startPosition, org.exbin.bined.basic.ScrollingDirection scrollingShift)
org.exbin.bined.EditOperation
getActiveOperation()
org.exbin.bined.CodeAreaSection
getActiveSection()
AntialiasingMode
getAntialiasingMode()
Returns antialiasing mode for text painting.org.exbin.bined.basic.BasicBackgroundPaintMode
getBackgroundPaintMode()
java.util.Optional<BasicCodeAreaColorsProfile>
getBasicColors()
Returns basic profile for colors.DefaultCodeAreaCaret
getCaret()
org.exbin.bined.CodeAreaCaretPosition
getCaretPosition()
org.exbin.bined.ClipboardHandlingMode
getClipboardHandlingMode()
java.awt.Font
getCodeFont()
Returns font used for text painting.org.exbin.bined.CodeCharactersCase
getCodeCharactersCase()
int
getCodeOffset()
org.exbin.bined.CodeType
getCodeType()
long
getDataPosition()
org.exbin.bined.EditMode
getEditMode()
org.exbin.bined.EditOperation
getEditOperation()
org.exbin.bined.ScrollBarVisibility
getHorizontalScrollBarVisibility()
org.exbin.bined.basic.HorizontalScrollUnit
getHorizontalScrollUnit()
java.nio.charset.Charset
getCharset()
int
getMaxBytesPerRow()
int
getMaxRowPositionLength()
int
getMinRowPositionLength()
int
getMouseCursorShape(int positionX, int positionY)
CodeAreaPainter
getPainter()
org.exbin.bined.RowWrappingMode
getRowWrapping()
org.exbin.bined.basic.CodeAreaScrollPosition
getScrollPosition()
org.exbin.bined.SelectionRange
getSelection()
org.exbin.bined.CodeAreaSelection
getSelectionHandler()
org.exbin.bined.ScrollBarVisibility
getVerticalScrollBarVisibility()
org.exbin.bined.basic.VerticalScrollUnit
getVerticalScrollUnit()
org.exbin.bined.basic.CodeAreaViewMode
getViewMode()
int
getWrappingBytesGroupSize()
boolean
hasSelection()
boolean
isEditable()
boolean
isInitialized()
boolean
isShowMirrorCursor()
org.exbin.bined.CodeAreaCaretPosition
mousePositionToClosestCaretPosition(int positionX, int positionY, org.exbin.bined.CaretOverlapMode overflowMode)
protected void
notifyCaretChanged()
protected void
notifyCaretMoved()
void
notifyDataChanged()
Notifies component, that the internal data was changed.protected void
notifyScrolled()
protected void
notifySelectionChanged()
void
paintComponent(java.awt.Graphics g)
Paints the main component.void
removeCaretMovedListener(org.exbin.bined.CaretMovedListener caretMovedListener)
void
removeEditModeChangedListener(org.exbin.bined.EditModeChangedListener editModeChangedListener)
void
removeScrollingListener(org.exbin.bined.ScrollingListener scrollingListener)
void
removeSelectionChangedListener(org.exbin.bined.SelectionChangedListener selectionChangedListener)
void
repaint()
void
reset()
Resets painter state for new painting.void
resetColors()
Rebuilds colors after UIManager change.void
resetPainter()
void
revealCursor()
void
revealPosition(long dataPosition, int dataOffset, org.exbin.bined.CodeAreaSection section)
void
revealPosition(org.exbin.bined.CodeAreaCaretPosition caretPosition)
void
setAntialiasingMode(AntialiasingMode antialiasingMode)
Sets antialiasing mode for text painting.void
setBackgroundPaintMode(org.exbin.bined.basic.BasicBackgroundPaintMode borderPaintMode)
void
setBasicColors(BasicCodeAreaColorsProfile colorsProfile)
Sets basic profile for colors.void
setBorder(javax.swing.border.Border border)
void
setCaretPosition(long dataPosition)
void
setCaretPosition(long dataPosition, int codeOffset)
void
setCaretPosition(org.exbin.bined.CodeAreaCaretPosition caretPosition)
void
setClipboardHandlingMode(org.exbin.bined.ClipboardHandlingMode clipboardHandlingMode)
void
setCodeFont(java.awt.Font codeFont)
Sets font used for text painting.void
setCodeCharactersCase(org.exbin.bined.CodeCharactersCase codeCharactersCase)
void
setCodeType(org.exbin.bined.CodeType codeType)
void
setEditMode(org.exbin.bined.EditMode editMode)
void
setEditOperation(org.exbin.bined.EditOperation editOperation)
void
setHorizontalScrollBarVisibility(org.exbin.bined.ScrollBarVisibility horizontalScrollBarVisibility)
void
setHorizontalScrollUnit(org.exbin.bined.basic.HorizontalScrollUnit horizontalScrollUnit)
void
setCharset(java.nio.charset.Charset charset)
void
setMaxBytesPerRow(int maxBytesPerRow)
void
setMaxRowPositionLength(int maxRowPositionLength)
void
setMinRowPositionLength(int minRowPositionLength)
void
setPainter(CodeAreaPainter painter)
void
setRowWrapping(org.exbin.bined.RowWrappingMode rowWrapping)
void
setScrollPosition(org.exbin.bined.basic.CodeAreaScrollPosition scrollPosition)
void
setSelection(long start, long end)
void
setSelection(org.exbin.bined.SelectionRange selectionRange)
void
setShowMirrorCursor(boolean showMirrorCursor)
void
setVerticalScrollBarVisibility(org.exbin.bined.ScrollBarVisibility verticalScrollBarVisibility)
void
setVerticalScrollUnit(org.exbin.bined.basic.VerticalScrollUnit verticalScrollUnit)
void
setViewMode(org.exbin.bined.basic.CodeAreaViewMode viewMode)
void
setWrappingBytesGroupSize(int groupSize)
void
updateLayout()
Requests update of the component layout.void
updateScrollBars()
void
updateScrollPosition(org.exbin.bined.basic.CodeAreaScrollPosition scrollPosition)
Updates scroll position.void
updateUI()
-
Methods inherited from class org.exbin.bined.swing.CodeAreaCore
addDataChangedListener, canPaste, copy, copyAsCode, cut, delete, getCommandHandler, getContentData, getDataSize, paste, pasteFromCode, removeDataChangedListener, selectAll, setCommandHandler, setContentData
-
Methods inherited from class 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, getUI, getUIClassID, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintImmediately, paintImmediately, paramString, print, printAll, printBorder, printComponent, printChildren, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
-
Methods inherited from class 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, setLayout, transferFocusDownCycle, validate, validateTree
-
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleContext, 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, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, checkImage, checkImage, 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, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
-
-
-
Constructor Detail
-
CodeArea
public CodeArea()
Creates new instance with default command handler and painter.
-
CodeArea
public CodeArea(CodeAreaCommandHandler.CodeAreaCommandHandlerFactory commandHandlerFactory)
Creates new instance with provided command handler factory method.- Parameters:
commandHandlerFactory
- command handler or null for default handler
-
-
Method Detail
-
getPainter
@Nonnull public CodeAreaPainter getPainter()
-
setPainter
public void setPainter(CodeAreaPainter painter)
-
paintComponent
public void paintComponent(java.awt.Graphics g)
Description copied from interface:CodeAreaSwingControl
Paints the main component.- Specified by:
paintComponent
in interfaceCodeAreaSwingControl
- Overrides:
paintComponent
in classjavax.swing.JComponent
- Parameters:
g
- graphics
-
updateUI
public void updateUI()
- Overrides:
updateUI
in classjavax.swing.JComponent
-
setBorder
public void setBorder(@Nullable javax.swing.border.Border border)
- Overrides:
setBorder
in classjavax.swing.JComponent
-
getCaret
@Nonnull public DefaultCodeAreaCaret getCaret()
- Specified by:
getCaret
in interfaceorg.exbin.bined.capability.CaretCapable
-
isShowMirrorCursor
public boolean isShowMirrorCursor()
- Specified by:
isShowMirrorCursor
in interfaceorg.exbin.bined.capability.CaretCapable
-
setShowMirrorCursor
public void setShowMirrorCursor(boolean showMirrorCursor)
- Specified by:
setShowMirrorCursor
in interfaceorg.exbin.bined.capability.CaretCapable
-
getMinRowPositionLength
public int getMinRowPositionLength()
- Specified by:
getMinRowPositionLength
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
setMinRowPositionLength
public void setMinRowPositionLength(int minRowPositionLength)
- Specified by:
setMinRowPositionLength
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
getMaxRowPositionLength
public int getMaxRowPositionLength()
- Specified by:
getMaxRowPositionLength
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
setMaxRowPositionLength
public void setMaxRowPositionLength(int maxRowPositionLength)
- Specified by:
setMaxRowPositionLength
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
isInitialized
public boolean isInitialized()
-
getDataPosition
public long getDataPosition()
- Specified by:
getDataPosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
getCodeOffset
public int getCodeOffset()
- Specified by:
getCodeOffset
in interfaceorg.exbin.bined.capability.CaretCapable
-
getActiveSection
@Nonnull public org.exbin.bined.CodeAreaSection getActiveSection()
- Specified by:
getActiveSection
in interfaceorg.exbin.bined.capability.CaretCapable
-
getCaretPosition
@Nonnull public org.exbin.bined.CodeAreaCaretPosition getCaretPosition()
- Specified by:
getCaretPosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
setCaretPosition
public void setCaretPosition(org.exbin.bined.CodeAreaCaretPosition caretPosition)
- Specified by:
setCaretPosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
setCaretPosition
public void setCaretPosition(long dataPosition)
- Specified by:
setCaretPosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
setCaretPosition
public void setCaretPosition(long dataPosition, int codeOffset)
- Specified by:
setCaretPosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
getMouseCursorShape
public int getMouseCursorShape(int positionX, int positionY)
- Specified by:
getMouseCursorShape
in interfaceorg.exbin.bined.capability.CaretCapable
-
getCodeCharactersCase
@Nonnull public org.exbin.bined.CodeCharactersCase getCodeCharactersCase()
- Specified by:
getCodeCharactersCase
in interfaceorg.exbin.bined.capability.CodeCharactersCaseCapable
-
setCodeCharactersCase
public void setCodeCharactersCase(org.exbin.bined.CodeCharactersCase codeCharactersCase)
- Specified by:
setCodeCharactersCase
in interfaceorg.exbin.bined.capability.CodeCharactersCaseCapable
-
resetColors
public void resetColors()
Description copied from interface:CodeAreaSwingControl
Rebuilds colors after UIManager change.- Specified by:
resetColors
in interfaceCodeAreaSwingControl
-
getViewMode
@Nonnull public org.exbin.bined.basic.CodeAreaViewMode getViewMode()
- Specified by:
getViewMode
in interfaceorg.exbin.bined.capability.ViewModeCapable
-
setViewMode
public void setViewMode(org.exbin.bined.basic.CodeAreaViewMode viewMode)
- Specified by:
setViewMode
in interfaceorg.exbin.bined.capability.ViewModeCapable
-
getCodeType
@Nonnull public org.exbin.bined.CodeType getCodeType()
- Specified by:
getCodeType
in interfaceorg.exbin.bined.capability.CodeTypeCapable
-
setCodeType
public void setCodeType(org.exbin.bined.CodeType codeType)
- Specified by:
setCodeType
in interfaceorg.exbin.bined.capability.CodeTypeCapable
-
revealCursor
public void revealCursor()
- Specified by:
revealCursor
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
revealPosition
public void revealPosition(org.exbin.bined.CodeAreaCaretPosition caretPosition)
- Specified by:
revealPosition
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
revealPosition
public void revealPosition(long dataPosition, int dataOffset, org.exbin.bined.CodeAreaSection section)
-
centerOnCursor
public void centerOnCursor()
- Specified by:
centerOnCursor
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
centerOnPosition
public void centerOnPosition(org.exbin.bined.CodeAreaCaretPosition caretPosition)
- Specified by:
centerOnPosition
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
centerOnPosition
public void centerOnPosition(long dataPosition, int dataOffset, org.exbin.bined.CodeAreaSection section)
-
mousePositionToClosestCaretPosition
@Nonnull public org.exbin.bined.CodeAreaCaretPosition mousePositionToClosestCaretPosition(int positionX, int positionY, org.exbin.bined.CaretOverlapMode overflowMode)
- Specified by:
mousePositionToClosestCaretPosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
computeMovePosition
@Nonnull public org.exbin.bined.CodeAreaCaretPosition computeMovePosition(org.exbin.bined.CodeAreaCaretPosition position, org.exbin.bined.basic.MovementDirection direction)
- Specified by:
computeMovePosition
in interfaceorg.exbin.bined.capability.CaretCapable
-
computeScrolling
@Nonnull public org.exbin.bined.basic.CodeAreaScrollPosition computeScrolling(org.exbin.bined.basic.CodeAreaScrollPosition startPosition, org.exbin.bined.basic.ScrollingDirection scrollingShift)
- Specified by:
computeScrolling
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
updateScrollBars
public void updateScrollBars()
-
getScrollPosition
@Nonnull public org.exbin.bined.basic.CodeAreaScrollPosition getScrollPosition()
- Specified by:
getScrollPosition
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
setScrollPosition
public void setScrollPosition(org.exbin.bined.basic.CodeAreaScrollPosition scrollPosition)
- Specified by:
setScrollPosition
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
updateScrollPosition
public void updateScrollPosition(org.exbin.bined.basic.CodeAreaScrollPosition scrollPosition)
Description copied from interface:CodeAreaSwingControl
Updates scroll position.- Specified by:
updateScrollPosition
in interfaceCodeAreaSwingControl
- Parameters:
scrollPosition
- scroll position
-
getVerticalScrollBarVisibility
@Nonnull public org.exbin.bined.ScrollBarVisibility getVerticalScrollBarVisibility()
- Specified by:
getVerticalScrollBarVisibility
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
setVerticalScrollBarVisibility
public void setVerticalScrollBarVisibility(org.exbin.bined.ScrollBarVisibility verticalScrollBarVisibility)
- Specified by:
setVerticalScrollBarVisibility
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
getVerticalScrollUnit
@Nonnull public org.exbin.bined.basic.VerticalScrollUnit getVerticalScrollUnit()
- Specified by:
getVerticalScrollUnit
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
setVerticalScrollUnit
public void setVerticalScrollUnit(org.exbin.bined.basic.VerticalScrollUnit verticalScrollUnit)
- Specified by:
setVerticalScrollUnit
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
getHorizontalScrollBarVisibility
@Nonnull public org.exbin.bined.ScrollBarVisibility getHorizontalScrollBarVisibility()
- Specified by:
getHorizontalScrollBarVisibility
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
setHorizontalScrollBarVisibility
public void setHorizontalScrollBarVisibility(org.exbin.bined.ScrollBarVisibility horizontalScrollBarVisibility)
- Specified by:
setHorizontalScrollBarVisibility
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
getHorizontalScrollUnit
@Nonnull public org.exbin.bined.basic.HorizontalScrollUnit getHorizontalScrollUnit()
- Specified by:
getHorizontalScrollUnit
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
setHorizontalScrollUnit
public void setHorizontalScrollUnit(org.exbin.bined.basic.HorizontalScrollUnit horizontalScrollUnit)
- Specified by:
setHorizontalScrollUnit
in interfaceorg.exbin.bined.capability.BasicScrollingCapable
-
reset
public void reset()
Description copied from interface:CodeAreaSwingControl
Resets painter state for new painting.- Specified by:
reset
in interfaceCodeAreaSwingControl
-
updateLayout
public void updateLayout()
Description copied from interface:CodeAreaSwingControl
Requests update of the component layout. Notifies code area, that change of parameters will affect layout and it should be recomputed and updated if necessary.- Specified by:
updateLayout
in interfaceCodeAreaSwingControl
- Specified by:
updateLayout
in classCodeAreaCore
-
repaint
public void repaint()
- Overrides:
repaint
in classjava.awt.Component
-
resetPainter
public void resetPainter()
- Specified by:
resetPainter
in classCodeAreaCore
-
notifyCaretChanged
protected void notifyCaretChanged()
-
notifyDataChanged
public void notifyDataChanged()
Description copied from class:CodeAreaCore
Notifies component, that the internal data was changed.- Overrides:
notifyDataChanged
in classCodeAreaCore
-
getAntialiasingMode
@Nonnull public AntialiasingMode getAntialiasingMode()
Description copied from interface:AntialiasingCapable
Returns antialiasing mode for text painting.- Specified by:
getAntialiasingMode
in interfaceAntialiasingCapable
- Returns:
- antialiasing mode
-
setAntialiasingMode
public void setAntialiasingMode(AntialiasingMode antialiasingMode)
Description copied from interface:AntialiasingCapable
Sets antialiasing mode for text painting.- Specified by:
setAntialiasingMode
in interfaceAntialiasingCapable
- Parameters:
antialiasingMode
- antialiasing mode
-
getSelection
@Nonnull public org.exbin.bined.SelectionRange getSelection()
- Specified by:
getSelection
in interfaceorg.exbin.bined.capability.SelectionCapable
-
setSelection
public void setSelection(org.exbin.bined.SelectionRange selectionRange)
- Specified by:
setSelection
in interfaceorg.exbin.bined.capability.SelectionCapable
-
setSelection
public void setSelection(long start, long end)
- Specified by:
setSelection
in interfaceorg.exbin.bined.capability.SelectionCapable
-
clearSelection
public void clearSelection()
- Specified by:
clearSelection
in interfaceorg.exbin.bined.CodeAreaControl
- Specified by:
clearSelection
in interfaceorg.exbin.bined.capability.SelectionCapable
- Overrides:
clearSelection
in classCodeAreaCore
-
hasSelection
public boolean hasSelection()
- Specified by:
hasSelection
in interfaceorg.exbin.bined.CodeAreaControl
- Specified by:
hasSelection
in interfaceorg.exbin.bined.capability.SelectionCapable
- Overrides:
hasSelection
in classCodeAreaCore
-
getSelectionHandler
@Nonnull public org.exbin.bined.CodeAreaSelection getSelectionHandler()
- Specified by:
getSelectionHandler
in interfaceorg.exbin.bined.capability.SelectionCapable
-
getCharset
@Nonnull public java.nio.charset.Charset getCharset()
- Specified by:
getCharset
in interfaceorg.exbin.bined.capability.CharsetCapable
-
setCharset
public void setCharset(java.nio.charset.Charset charset)
- Specified by:
setCharset
in interfaceorg.exbin.bined.capability.CharsetCapable
-
isEditable
public boolean isEditable()
- Specified by:
isEditable
in interfaceorg.exbin.bined.capability.EditModeCapable
-
getEditMode
@Nonnull public org.exbin.bined.EditMode getEditMode()
- Specified by:
getEditMode
in interfaceorg.exbin.bined.capability.EditModeCapable
-
setEditMode
public void setEditMode(org.exbin.bined.EditMode editMode)
- Specified by:
setEditMode
in interfaceorg.exbin.bined.capability.EditModeCapable
-
getActiveOperation
@Nonnull public org.exbin.bined.EditOperation getActiveOperation()
- Specified by:
getActiveOperation
in interfaceorg.exbin.bined.capability.EditModeCapable
-
getEditOperation
@Nonnull public org.exbin.bined.EditOperation getEditOperation()
- Specified by:
getEditOperation
in interfaceorg.exbin.bined.capability.EditModeCapable
-
setEditOperation
public void setEditOperation(org.exbin.bined.EditOperation editOperation)
- Specified by:
setEditOperation
in interfaceorg.exbin.bined.capability.EditModeCapable
-
getClipboardHandlingMode
@Nonnull public org.exbin.bined.ClipboardHandlingMode getClipboardHandlingMode()
- Specified by:
getClipboardHandlingMode
in interfaceorg.exbin.bined.capability.ClipboardCapable
-
setClipboardHandlingMode
public void setClipboardHandlingMode(org.exbin.bined.ClipboardHandlingMode clipboardHandlingMode)
- Specified by:
setClipboardHandlingMode
in interfaceorg.exbin.bined.capability.ClipboardCapable
-
getCodeFont
@Nonnull public java.awt.Font getCodeFont()
Description copied from interface:FontCapable
Returns font used for text painting.- Specified by:
getCodeFont
in interfaceFontCapable
- Returns:
- font
-
setCodeFont
public void setCodeFont(java.awt.Font codeFont)
Description copied from interface:FontCapable
Sets font used for text painting.- Specified by:
setCodeFont
in interfaceFontCapable
- Parameters:
codeFont
- font
-
getBackgroundPaintMode
@Nonnull public org.exbin.bined.basic.BasicBackgroundPaintMode getBackgroundPaintMode()
- Specified by:
getBackgroundPaintMode
in interfaceorg.exbin.bined.capability.BackgroundPaintCapable
-
setBackgroundPaintMode
public void setBackgroundPaintMode(org.exbin.bined.basic.BasicBackgroundPaintMode borderPaintMode)
- Specified by:
setBackgroundPaintMode
in interfaceorg.exbin.bined.capability.BackgroundPaintCapable
-
getRowWrapping
@Nonnull public org.exbin.bined.RowWrappingMode getRowWrapping()
- Specified by:
getRowWrapping
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
setRowWrapping
public void setRowWrapping(org.exbin.bined.RowWrappingMode rowWrapping)
- Specified by:
setRowWrapping
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
getWrappingBytesGroupSize
public int getWrappingBytesGroupSize()
- Specified by:
getWrappingBytesGroupSize
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
setWrappingBytesGroupSize
public void setWrappingBytesGroupSize(int groupSize)
- Specified by:
setWrappingBytesGroupSize
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
getMaxBytesPerRow
public int getMaxBytesPerRow()
- Specified by:
getMaxBytesPerRow
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
setMaxBytesPerRow
public void setMaxBytesPerRow(int maxBytesPerRow)
- Specified by:
setMaxBytesPerRow
in interfaceorg.exbin.bined.capability.RowWrappingCapable
-
getBasicColors
@Nonnull public java.util.Optional<BasicCodeAreaColorsProfile> getBasicColors()
Description copied from interface:BasicColorsCapable
Returns basic profile for colors.- Specified by:
getBasicColors
in interfaceBasicColorsCapable
- Returns:
- colors profile
-
setBasicColors
public void setBasicColors(BasicCodeAreaColorsProfile colorsProfile)
Description copied from interface:BasicColorsCapable
Sets basic profile for colors.- Specified by:
setBasicColors
in interfaceBasicColorsCapable
- Parameters:
colorsProfile
- colors profile
-
notifySelectionChanged
protected void notifySelectionChanged()
-
notifyCaretMoved
protected void notifyCaretMoved()
-
notifyScrolled
protected void notifyScrolled()
-
addSelectionChangedListener
public void addSelectionChangedListener(org.exbin.bined.SelectionChangedListener selectionChangedListener)
- Specified by:
addSelectionChangedListener
in interfaceorg.exbin.bined.capability.SelectionCapable
-
removeSelectionChangedListener
public void removeSelectionChangedListener(org.exbin.bined.SelectionChangedListener selectionChangedListener)
- Specified by:
removeSelectionChangedListener
in interfaceorg.exbin.bined.capability.SelectionCapable
-
addCaretMovedListener
public void addCaretMovedListener(org.exbin.bined.CaretMovedListener caretMovedListener)
- Specified by:
addCaretMovedListener
in interfaceorg.exbin.bined.capability.CaretCapable
-
removeCaretMovedListener
public void removeCaretMovedListener(org.exbin.bined.CaretMovedListener caretMovedListener)
- Specified by:
removeCaretMovedListener
in interfaceorg.exbin.bined.capability.CaretCapable
-
addScrollingListener
public void addScrollingListener(org.exbin.bined.ScrollingListener scrollingListener)
- Specified by:
addScrollingListener
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
removeScrollingListener
public void removeScrollingListener(org.exbin.bined.ScrollingListener scrollingListener)
- Specified by:
removeScrollingListener
in interfaceorg.exbin.bined.capability.ScrollingCapable
-
addEditModeChangedListener
public void addEditModeChangedListener(org.exbin.bined.EditModeChangedListener editModeChangedListener)
- Specified by:
addEditModeChangedListener
in interfaceorg.exbin.bined.capability.EditModeCapable
-
removeEditModeChangedListener
public void removeEditModeChangedListener(org.exbin.bined.EditModeChangedListener editModeChangedListener)
- Specified by:
removeEditModeChangedListener
in interfaceorg.exbin.bined.capability.EditModeCapable
-
-