Class PropertyBasedBackgroundColorModel
- java.lang.Object
-
- ghidra.app.util.viewer.listingpanel.PropertyBasedBackgroundColorModel
-
- All Implemented Interfaces:
BackgroundColorModel,ListingBackgroundColorModel,DomainObjectListener,java.util.EventListener
public class PropertyBasedBackgroundColorModel extends java.lang.Object implements ListingBackgroundColorModel, DomainObjectListener
DefaultBackgroundColorModelfor the ListingPanel where the color returned for an index is based on that corresponding address having a color set in the program's database. (You can "paint" colors over address ranges).
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringCOLOR_PROPERTY_NAME
-
Constructor Summary
Constructors Constructor Description PropertyBasedBackgroundColorModel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddomainObjectChanged(DomainObjectChangedEvent ev)Method called when a change is made to the domain object.java.awt.ColorgetBackgroundColor(java.math.BigInteger index)java.awt.ColorgetDefaultBackgroundColor()voidmodelDataChanged(ListingPanel listingPanel)Called when theAddressIndexMapor theProgramchanges.voidsetDefaultBackgroundColor(java.awt.Color c)voidsetEnabled(boolean b)
-
-
-
Field Detail
-
COLOR_PROPERTY_NAME
public static final java.lang.String COLOR_PROPERTY_NAME
- See Also:
- Constant Field Values
-
-
Method Detail
-
modelDataChanged
public void modelDataChanged(ListingPanel listingPanel)
Description copied from interface:ListingBackgroundColorModelCalled when theAddressIndexMapor theProgramchanges.- Specified by:
modelDataChangedin interfaceListingBackgroundColorModel- Parameters:
listingPanel- theListingPanelthat changed and where the newAddressIndexMapandProgramcan be retrieved.
-
getBackgroundColor
public java.awt.Color getBackgroundColor(java.math.BigInteger index)
- Specified by:
getBackgroundColorin interfaceBackgroundColorModel
-
getDefaultBackgroundColor
public java.awt.Color getDefaultBackgroundColor()
- Specified by:
getDefaultBackgroundColorin interfaceBackgroundColorModel
-
setDefaultBackgroundColor
public void setDefaultBackgroundColor(java.awt.Color c)
- Specified by:
setDefaultBackgroundColorin interfaceBackgroundColorModel
-
domainObjectChanged
public void domainObjectChanged(DomainObjectChangedEvent ev)
Description copied from interface:DomainObjectListenerMethod called when a change is made to the domain object.- Specified by:
domainObjectChangedin interfaceDomainObjectListener- Parameters:
ev- event containing the change record and type of change that was made
-
setEnabled
public void setEnabled(boolean b)
-
-