net.sourceforge.jsh3modtool.gui.imagetable
Class BaseCell

java.lang.Object
  extended by net.sourceforge.jsh3modtool.gui.imagetable.BaseCell
Direct Known Subclasses:
FolderCell, ImageCell

public class BaseCell
extends java.lang.Object

An abstract cell for the image table.

Author:
redsolo

Constructor Summary
protected BaseCell()
          Creates a new instance of AbstractCell
 
Method Summary
 java.lang.String getCachedName()
          Returns the cached name.
 int getCachedNameMaxWidth()
          Returns the max width that the cached name was created for.
 void recacheName(java.lang.String fullName, int maxWidth, java.awt.FontMetrics fontMetrics)
          Recache the name for the cell
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BaseCell

protected BaseCell()
Creates a new instance of AbstractCell

Method Detail

getCachedName

public java.lang.String getCachedName()
Returns the cached name. The cached name is the name (shortened) to fit the latest set max width.

Returns:
the cached name.

getCachedNameMaxWidth

public int getCachedNameMaxWidth()
Returns the max width that the cached name was created for.

Returns:
the max width that the cached name was created for.

recacheName

public void recacheName(java.lang.String fullName,
                        int maxWidth,
                        java.awt.FontMetrics fontMetrics)
Recache the name for the cell

Parameters:
fullName - the full name that should be shortened
maxWidth - the max size of the name (of the cached name)
fontMetrics - a fontmetrics that is used to calculate the width of a string


Copyright © 2005 sourceforge.net. All Rights Reserved.