borland Packages  Class Hierarchy  jbcl.model Package  Index 

CustomPaintSite interface

borland.jbcl.model.ItemPaintSite
   +----borland.jbcl.model.CustomPaintSite

About the CustomPaintSite interface

Properties  Methods  

Implemented by CustomItemEditor, CustomItemPainter

Classes that implement the CustomPaintSite interface can provide custom item painters and painters with information about the host container in which the painting occurs. CustomPaintSite has the methods to return the background color, the foreground color, the font, the alignment setting, the margins for the item being painted.


CustomPaintSite properties

*Read-only properties **Write-only properties

Properties defined in this interface

Properties implemented in borland.jbcl.model.ItemPaintSite

CustomPaintSite methods

Methods defined in this interface


CustomPaintSite properties

alignment

 public void setAlignment(int alignment)
Determines the alignment of the item being painted. Specify alignment using the borland.jbcl.util.Alignment variables.

background

 public void setBackground(java.awt.Color color)
Determines the background color for the item being painted.

font

 public void setFont(java.awt.Font font)
Determines the font to use for the item being painted.

foreground

 public void setForeground(java.awt.Color color)
Determines the foreground color for the item being painted.

itemMargins

 public void setItemMargins(java.awt.Insets margins)
Determines the margins around the item being painted.

CustomPaintSite methods

reset()

  public void reset()
Resets the properties of CustomPaintSite to their default values.