borland Packages  Class Hierarchy  jbcl.view Package  Index 

EllipsisTextItemPainter component

java.lang.Object
   +----borland.jbcl.view.TextItemPainter
           +----borland.jbcl.view.EllipsisTextItemPainter

About the EllipsisTextItemPainter component

Variables  Constructors  Properties  Methods  

Implements ItemPainter, Serializable

Like TextItemPainter, which it extends, the paint() method of EllipsisTextItemPainter extracts text from the passed data object and paints it in the given rectangle. If the entire text string cannot fit within the rectangle, however the paint() method of EllipsisTextItemPainter truncates the text and appends an ellipsis (...) to it, indicating that more text exists than is visible.

For example, suppose the text string is this:

Hello, all Java programmers
If an increasingly smaller rectangle is passed to the EllipsisTextItemPainter, the resulting text strings might look like this:
Hello, all Java pro...
Hello, all J...
Hello, ...
He...
...

The column headings of GridControl use an EllipsisTextItemPainter.


EllipsisTextItemPainter variables

Variables implemented in borland.jbcl.view.TextItemPainter

EllipsisTextItemPainter constructors

EllipsisTextItemPainter properties

*Read-only properties **Write-only properties

Properties implemented in borland.jbcl.view.TextItemPainter

Properties implemented in java.lang.Object

EllipsisTextItemPainter methods

Methods implemented in this class

Methods implemented in borland.jbcl.view.TextItemPainter

Methods implemented in java.lang.Object


EllipsisTextItemPainter constructors

EllipsisTextItemPainter()

  public EllipsisTextItemPainter()
Creates an EllipsisTextItemPainter.

EllipsisTextItemPainter(int)

  public EllipsisTextItemPainter(int alignment)
Constructs an EllipsisTextItemPainter that aligns the text as specified with the alignment parameter.

Parameters:

alignment
Specify on of the alignment variables.

EllipsisTextItemPainter(int, java.awt.Insets)

  public EllipsisTextItemPainter(int alignment, java.awt.Insets margins)
Constructs an EllipsisTextItemPainter with the specified alignment and margins.

Parameters:

alignment
Specify on of the alignment variables.
margins
An Insets object that defines the margins around the text.

EllipsisTextItemPainter(int, java.awt.Insets, borland.jbcl.model.ItemFormatter)

  public EllipsisTextItemPainter(int alignment, java.awt.Insets margins, borland.jbcl.model.ItemFormatter formatter)
Constructs an EllipsisTextItemPainter with the specified alignment and margins. The painter uses the specified ItemFormatter to format the text.

Parameters:

alignment
Specify on of the alignment variables.
margins
An Insets object that defines the margins around the text.
formatter
An ItemFormatter that determines how the text is formatted.