ChartCat 1.2

li.netcat.chart.util
Class TextLook

java.lang.Object
  extended byli.netcat.chart.util.TextLook

public class TextLook
extends java.lang.Object

Immutable class that represents the look of a text label. It consists of the properties font and foreground paint.

This class also provides some static defaults that are used during the construction phase of certain parts.

Author:
Arthur Marxer

Constructor Summary
TextLook(java.awt.Font font, java.awt.Paint foreground)
          Constructs a new instance of a TextLook with the given font and foreground.
TextLook(java.awt.Font font, Pen pen)
          Constructs a new instance of a TextLook with the given font and foreground.
 
Method Summary
 TextLook font(java.awt.Font font)
          Constructs a new instance of a TextLook with the given font as font.
 TextLook foreground(java.awt.Paint paint)
          Constructs a new instance of a TextLook with the given paint as foreground.
static TextLook getDefaultLarge()
          Returns the default of a large sized TextLook.
static TextLook getDefaultMedium()
          Returns the default of a medium sized TextLook.
static TextLook getDefaultNormal()
          Returns the default of a normal sized TextLook.
static TextLook getDefaultSmall()
          Returns the default of a small TextLook.
 java.awt.Font getFont()
          Returns the font of this TextLook.
 java.awt.Paint getForeground()
          Returns the foreground paint of this TextLook.
 Pen getPen()
          Returns the pen that is used to paint this text.
 TextLook pen(Pen pen)
          Constructs a new instance of a TextLook with the given pen.
static void setDefaultLarge(TextLook textLook)
          Returns the default of a large sized TextLook.
static void setDefaultMedium(TextLook textLook)
          Sets the default of a medium sized TextLook.
static void setDefaultNormal(TextLook textLook)
          Sets the default of a normal sized TextLook.
static void setDefaultSmall(TextLook textLook)
          Sets the default of a small TextLook.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TextLook

public TextLook(java.awt.Font font,
                java.awt.Paint foreground)
Constructs a new instance of a TextLook with the given font and foreground.

Parameters:
font - The font to be used, not null.
foreground - The foreground paint, not null.

TextLook

public TextLook(java.awt.Font font,
                Pen pen)
Constructs a new instance of a TextLook with the given font and foreground.

Parameters:
font - The font to be used, not null.
Method Detail

getDefaultSmall

public static TextLook getDefaultSmall()
Returns the default of a small TextLook.

Returns:
The default of a small TextLook, never null.

setDefaultSmall

public static void setDefaultSmall(TextLook textLook)
Sets the default of a small TextLook.

Parameters:
textLook - The new small TextLook.

getDefaultNormal

public static TextLook getDefaultNormal()
Returns the default of a normal sized TextLook.

Returns:
The default of a normal sized TextLook, never null.

setDefaultNormal

public static void setDefaultNormal(TextLook textLook)
Sets the default of a normal sized TextLook.

Parameters:
textLook - The new normal sized TextLook.

getDefaultMedium

public static TextLook getDefaultMedium()
Returns the default of a medium sized TextLook.

Returns:
The default of a medium sized TextLook, never null.

setDefaultMedium

public static void setDefaultMedium(TextLook textLook)
Sets the default of a medium sized TextLook.

Parameters:
textLook - The new medium sized TextLook, never null.

getDefaultLarge

public static TextLook getDefaultLarge()
Returns the default of a large sized TextLook.

Returns:
The default of a large sized TextLook, never null.

setDefaultLarge

public static void setDefaultLarge(TextLook textLook)
Returns the default of a large sized TextLook.

Returns:
The default of a large sized TextLook, never null.

getFont

public java.awt.Font getFont()
Returns the font of this TextLook.

Returns:
The font of this TextLook, never null.

getForeground

public java.awt.Paint getForeground()
Returns the foreground paint of this TextLook.

Returns:
The foreground paint of this TextLook.

getPen

public Pen getPen()
Returns the pen that is used to paint this text.

Returns:
The pen that is used to paint this text.

font

public TextLook font(java.awt.Font font)
Constructs a new instance of a TextLook with the given font as font.

Parameters:
font - The new font, not null.
Returns:
A new instance of a TextLook.

foreground

public TextLook foreground(java.awt.Paint paint)
Constructs a new instance of a TextLook with the given paint as foreground.

Parameters:
paint - The new foreground paint.
Returns:
A new instance of a TextLook.

pen

public TextLook pen(Pen pen)
Constructs a new instance of a TextLook with the given pen.

Parameters:
pen - The new pen used to paint the text.
Returns:
A new instance of a TextLook.

ChartCat 1.2

Copyright © 2003 - 2005 NetCat Inc.. All rights reserved. Feedback

Chart,Charting,Charts,Java,Java Chart,Java Charting,Java Charts,Chart Java,Charts Java,3D,3D Chart,3Dchart,Graph,Graphs,Chart Graph,Java Graph,Diagram,Diagrams,Java Diagram,Java Diagrams,Curve,Curves,Bar Chart,Pie Chart,Line Chart,Area Chart,Bar Graph,Pie Graph,Line Graph,Java Diagram,Chart Diagram,Package,Library,Chart Library,Chart Engine,Chart Package,Graph Package,Paint,Support,Graphic,Graphics,Print, Chart,Charting,Charts,Java,Java Chart,Java Charting,Java Charts,Chart Java,Charts Java,3D,3D Chart,3Dchart,Graph,Graphs,Chart Graph,Java Graph,Diagram,Diagrams,Java Diagram,Java Diagrams,Curve,Curves,Bar Chart,Pie Chart,Line Chart,Area Chart,Bar Graph,Pie Graph,Line Graph,Java Diagram,Chart Diagram,Package,Library,Chart Library,Chart Engine,Chart Package,Graph Package,Paint,Support,Graphic,Graphics,Print, Chart,Charting,Charts,Java,Java Chart,Java Charting,Java Charts,Chart Java,Charts Java,3D,3D Chart,3Dchart,Graph,Graphs,Chart Graph,Java Graph,Diagram,Diagrams,Java Diagram,Java Diagrams,Curve,Curves,Bar Chart,Pie Chart,Line Chart,Area Chart,Bar Graph,Pie Graph,Line Graph,Java Diagram,Chart Diagram,Package,Library,Chart Library,Chart Engine,Chart Package,Graph Package,Paint,Support,Graphic,Graphics,Print