Class DiffHighlightCodeAreaPainter
- java.lang.Object
-
- org.exbin.bined.swing.extended.ExtendedCodeAreaPainter
-
- org.exbin.bined.swing.extended.diff.DiffHighlightCodeAreaPainter
-
- All Implemented Interfaces:
org.exbin.bined.swing.CodeAreaPainter
,CaretsProfileCapableCodeAreaPainter
,ColorsProfileCapableCodeAreaPainter
,LayoutProfileCapableCodeAreaPainter
,ThemeProfileCapableCodeAreaPainter
@ParametersAreNonnullByDefault public class DiffHighlightCodeAreaPainter extends ExtendedCodeAreaPainter
Highlighting painter for basic binary diff.
-
-
Field Summary
-
Fields inherited from class org.exbin.bined.swing.extended.ExtendedCodeAreaPainter
codeArea, unprintableCharactersMapping
-
-
Constructor Summary
Constructors Constructor Description DiffHighlightCodeAreaPainter(org.exbin.bined.swing.CodeAreaCore codeArea)
DiffHighlightCodeAreaPainter(org.exbin.bined.swing.CodeAreaCore codeArea, org.exbin.auxiliary.paged_data.BinaryData comparedData)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.Color
getDiffColor()
java.awt.Color
getPositionTextColor(long rowDataPosition, int byteOnRow, int charOnRow, org.exbin.bined.CodeAreaSection section, boolean unprintables)
Returns background color for particular code.void
paintMainArea(java.awt.Graphics g)
void
setComparedData(org.exbin.auxiliary.paged_data.BinaryData comparedData)
void
setDiffColor(java.awt.Color diffColor)
-
Methods inherited from class org.exbin.bined.swing.extended.ExtendedCodeAreaPainter
attach, computeCenterOnScrollPosition, computeMovePosition, computePositionScrollVisibility, computeRevealScrollPosition, computeScrolling, detach, drawCenteredChars, drawShiftedChars, fontChanged, getBytesPerRow, getCaretsProfile, getColorsProfile, getCursorPositionRect, getCharactersPerRow, getLayoutProfile, getMouseCursorShape, getPositionBackgroundColor, getPositionPoint, getPositionZone, getRowHeight, getThemeProfile, isInitialized, mousePositionToClosestCaretPosition, paintBackground, paintComponent, paintCursor, paintHeader, paintOutsideArea, paintRowBackground, paintRowPosition, paintRows, paintRowText, rebuildColors, recomputeCharPositions, reset, resetCaret, resetColors, resetFont, resetLayout, scrollPositionChanged, scrollPositionModified, setCaretsProfile, setColorsProfile, setLayoutProfile, setThemeProfile, updateCache, updateRectToCursorPosition, updateScrollBars
-
-
-
-
Constructor Detail
-
DiffHighlightCodeAreaPainter
public DiffHighlightCodeAreaPainter(org.exbin.bined.swing.CodeAreaCore codeArea)
-
DiffHighlightCodeAreaPainter
public DiffHighlightCodeAreaPainter(org.exbin.bined.swing.CodeAreaCore codeArea, @Nullable org.exbin.auxiliary.paged_data.BinaryData comparedData)
-
-
Method Detail
-
paintMainArea
public void paintMainArea(@Nonnull java.awt.Graphics g)
- Specified by:
paintMainArea
in interfaceorg.exbin.bined.swing.CodeAreaPainter
- Overrides:
paintMainArea
in classExtendedCodeAreaPainter
-
getPositionTextColor
@Nullable public java.awt.Color getPositionTextColor(long rowDataPosition, int byteOnRow, int charOnRow, org.exbin.bined.CodeAreaSection section, boolean unprintables)
Description copied from class:ExtendedCodeAreaPainter
Returns background color for particular code.- Overrides:
getPositionTextColor
in classExtendedCodeAreaPainter
- Parameters:
rowDataPosition
- row data positionbyteOnRow
- byte on current rowcharOnRow
- character on current rowsection
- current sectionunprintables
- flag for unprintable characters- Returns:
- color or null for default color
-
setComparedData
public void setComparedData(org.exbin.auxiliary.paged_data.BinaryData comparedData)
-
getDiffColor
@Nonnull public java.awt.Color getDiffColor()
-
setDiffColor
public void setDiffColor(java.awt.Color diffColor)
-
-