org.jzy3d.plot3d.text.drawable.cells
Class TextCellRenderer

java.lang.Object
  extended by org.jzy3d.plot3d.text.drawable.TextImageRenderer
      extended by org.jzy3d.plot3d.text.drawable.cells.TextCellRenderer

public class TextCellRenderer
extends TextImageRenderer

Experimental Wraps a Text into a cell with an assigned number of char width.

Author:
Martin

Field Summary
protected  Color borderColor
           
protected  boolean drawBorder
           
protected  boolean drawText
           
protected  Halign h
           
protected  int n
           
protected static int OFFSET_CONSTANT
           
protected  Coord3d sceneOffset
           
protected  Color textColor
           
 
Fields inherited from class org.jzy3d.plot3d.text.drawable.TextImageRenderer
font, text
 
Constructor Summary
TextCellRenderer(int n, String txt, Font font)
           
TextCellRenderer(int n, String txt, Font font, Halign halign, boolean drawBorder)
           
 
Method Summary
 Color getBorderColor()
           
 int getCharacterWidth()
           
 Halign getHorizontalAlignement()
           
 BufferedImageTexture getImage(float ratio)
           
 Coord3d getSceneOffset()
           
 Color getTextColor()
           
protected  IntegerCoord2d guessImageDimension(int n, Font font)
           
 boolean isBorderDisplayed()
           
 boolean isTextDisplayed()
           
 void setBorderColor(Color borderColor)
           
 void setBorderDisplayed(boolean drawBorder)
           
 void setCharacterWidth(int n)
           
 void setHorizontalAlignement(Halign h)
           
 void setSceneOffset(Coord3d sceneOffset)
           
 void setTextColor(Color textColor)
           
 void setTextDisplayed(boolean drawText)
           
 
Methods inherited from class org.jzy3d.plot3d.text.drawable.TextImageRenderer
getImage, guessImageDimension
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OFFSET_CONSTANT

protected static int OFFSET_CONSTANT

n

protected int n

h

protected Halign h

borderColor

protected Color borderColor

textColor

protected Color textColor

drawBorder

protected boolean drawBorder

drawText

protected boolean drawText

sceneOffset

protected Coord3d sceneOffset
Constructor Detail

TextCellRenderer

public TextCellRenderer(int n,
                        String txt,
                        Font font)

TextCellRenderer

public TextCellRenderer(int n,
                        String txt,
                        Font font,
                        Halign halign,
                        boolean drawBorder)
Method Detail

getImage

public BufferedImageTexture getImage(float ratio)
Overrides:
getImage in class TextImageRenderer

getBorderColor

public Color getBorderColor()

setBorderColor

public void setBorderColor(Color borderColor)

getTextColor

public Color getTextColor()

setTextColor

public void setTextColor(Color textColor)

isBorderDisplayed

public boolean isBorderDisplayed()

setBorderDisplayed

public void setBorderDisplayed(boolean drawBorder)

isTextDisplayed

public boolean isTextDisplayed()

setTextDisplayed

public void setTextDisplayed(boolean drawText)

getCharacterWidth

public int getCharacterWidth()

setCharacterWidth

public void setCharacterWidth(int n)

getHorizontalAlignement

public Halign getHorizontalAlignement()

setHorizontalAlignement

public void setHorizontalAlignement(Halign h)

getSceneOffset

public Coord3d getSceneOffset()

setSceneOffset

public void setSceneOffset(Coord3d sceneOffset)

guessImageDimension

protected IntegerCoord2d guessImageDimension(int n,
                                             Font font)