Package ghidra.app.decompiler.component
Class ClangTextField
- java.lang.Object
-
- docking.widgets.fieldpanel.field.VerticalLayoutTextField
-
- docking.widgets.fieldpanel.field.WrappingVerticalLayoutTextField
-
- ghidra.app.decompiler.component.ClangTextField
-
public class ClangTextField extends WrappingVerticalLayoutTextField
-
-
Field Summary
-
Fields inherited from class docking.widgets.fieldpanel.field.VerticalLayoutTextField
hlFactory, isClipped, preferredWidth, startX, subFields, textElements, width
-
-
Constructor Summary
Constructors Constructor Description ClangTextField(java.util.List<ClangToken> tokenList, FieldElement[] fieldElements, FieldElement lineNumberFieldElement, int x, int width, HighlightFactory hlFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getLineNumber()
int
getLineNumberWidth()
ClangToken
getToken(FieldLocation loc)
Gets the C language token at the indicated location.void
paint(javax.swing.JComponent c, java.awt.Graphics g, PaintContext context, FieldBackgroundColorManager selectionMap, RowColLocation cursorLoc, int rowHeight)
Paints this field.-
Methods inherited from class docking.widgets.fieldpanel.field.WrappingVerticalLayoutTextField
dataToScreenLocation
-
Methods inherited from class docking.widgets.fieldpanel.field.VerticalLayoutTextField
calculateHeight, contains, generateText, generateText, getCol, getCursorBounds, getFieldElement, getHeight, getHeightAbove, getHeightBelow, getNumCols, getNumRows, getPreferredWidth, getRow, getScrollableUnitIncrement, getStartX, getSubfields, getText, getTextWithLineSeparators, getWidth, getX, getY, isClipped, isPrimary, isValid, layoutElements, rowHeightChanged, screenLocationToTextOffset, screenToDataLocation, setPrimary, textOffsetToScreenLocation, toString
-
-
-
-
Constructor Detail
-
ClangTextField
public ClangTextField(java.util.List<ClangToken> tokenList, FieldElement[] fieldElements, FieldElement lineNumberFieldElement, int x, int width, HighlightFactory hlFactory)
-
-
Method Detail
-
getToken
public ClangToken getToken(FieldLocation loc)
Gets the C language token at the indicated location.- Parameters:
loc
- the field location- Returns:
- the token
-
paint
public void paint(javax.swing.JComponent c, java.awt.Graphics g, PaintContext context, FieldBackgroundColorManager selectionMap, RowColLocation cursorLoc, int rowHeight)
Description copied from interface:Field
Paints this field.- Specified by:
paint
in interfaceField
- Overrides:
paint
in classVerticalLayoutTextField
g
- the graphics context.context
- common paint parametersselectionMap
- contains background color information for the field.cursorLoc
- the row,column cursor location within the field or null if the field does not contain the cursor- See Also:
docking.widgets.fieldpanel.field.Field#paint(java.awt.Graphics, docking.widgets.fieldpanel.internal.PaintContext, boolean, docking.widgets.fieldpanel.support.RowColLocation)
-
getLineNumberWidth
public int getLineNumberWidth()
-
getLineNumber
public int getLineNumber()
-
-