com.sas.awt.print
Interface AnnotationInterface

All Superinterfaces:
StaticAnnotationInterface
All Known Implementing Classes:
Annotation

public interface AnnotationInterface
extends StaticAnnotationInterface

AnnotationInterface defines the interface necessary to access and modify information for an Annotation. Line index values are 1-based, while alignment values should be one of the values from com.sas.visuals.Alignment.

See Also:
Alignment

Method Summary
 void addTransformInterface(String text, TransformInterface formatter)
          add a TransformInterface for the given string
 Object clone()
          clone the implementation
 void setBottomMargin(Length margin)
          set the bottom margin
 void setFont(Font font)
          set the font for all lines in the annotation
 void setFont(Font font, int lineNumber)
          set the font for a specific line (all Alignments) in the annotation
 void setFont(Font font, int lineNumber, int align)
          set the font for a specific line (all Alignments) in the annotation
 void setForeground(Color color)
          set the color for all lines in the annotation
 void setForeground(Color color, int lineNumber)
          set the color for a specific line (all Alignments) in the annotation
 void setForeground(Color color, int lineNumber, int align)
          set the color for a specific line at a specific Alignment in the annotation
 void setLeftMargin(Length margin)
          set the left margin
 void setMessage(String message, int line, int align)
          set the message format string for a line at a given Alignment.
 void setRightMargin(Length margin)
          set the right margin
 void setTopMargin(Length margin)
          sets the top margin
 void setVerticalJustification(int justification)
          set the vertical Alignment for the annotation.
 
Methods inherited from interface com.sas.awt.print.StaticAnnotationInterface
getBottomMargin, getFont, getForeground, getLeftMargin, getLineCount, getMessage, getRightMargin, getText, getTopMargin, getVerticalJustification
 

Method Detail

setMessage

public void setMessage(String message,
                       int line,
                       int align)
set the message format string for a line at a given Alignment. The line index is 1-based
Parameters:
String - message format string
int - line number
int - Alignment value

addTransformInterface

public void addTransformInterface(String text,
                                  TransformInterface formatter)
add a TransformInterface for the given string
Parameters:
String - to translate
TransformInterface - - formatter

setForeground

public void setForeground(Color color)
set the color for all lines in the annotation
Parameters:
color - the new line color.

setForeground

public void setForeground(Color color,
                          int lineNumber)
set the color for a specific line (all Alignments) in the annotation
Parameters:
color - the new line color.
lineNumber - the line number of the message

setForeground

public void setForeground(Color color,
                          int lineNumber,
                          int align)
set the color for a specific line at a specific Alignment in the annotation
Parameters:
color - the new line color.
int - line number of the message
int - Alignment value

setFont

public void setFont(Font font)
set the font for all lines in the annotation
Parameters:
font - the new line font.

setFont

public void setFont(Font font,
                    int lineNumber)
set the font for a specific line (all Alignments) in the annotation
Parameters:
font - the new line font.
lineNumber - the line number of the message

setFont

public void setFont(Font font,
                    int lineNumber,
                    int align)
set the font for a specific line (all Alignments) in the annotation
Parameters:
Font - the new line font.
int - the line number of the message
int - Alignment value

setTopMargin

public void setTopMargin(Length margin)
sets the top margin
Parameters:
Length - com.sas.measures.Length specifying the top margin

setBottomMargin

public void setBottomMargin(Length margin)
set the bottom margin
Parameters:
Length - com.sas.measures.Length specifying the bottom margin

setLeftMargin

public void setLeftMargin(Length margin)
set the left margin
Parameters:
Length - com.sas.measures.Length specifying the left margin

setRightMargin

public void setRightMargin(Length margin)
set the right margin
Parameters:
Length - com.sas.measures.Length specifying the right margin

setVerticalJustification

public void setVerticalJustification(int justification)
set the vertical Alignment for the annotation. The Alignment should be set to Annotation.TOP for headers and Annotation.BOTTOM for footers.
Parameters:
int - vertical Alignment

clone

public Object clone()
clone the implementation




Copyright © 2005 SAS Institute Inc. All Rights Reserved.
javadoc generated Thu, 16 Feb 2006 01:47:02