protected Graphics createGraphics(ImageFormatter formatter,int width,int height){
  java.awt.Graphics graphics=null;
  if (formatter == null) {
    logger.warning("ImageServer.createGraphics: Formatter is null, returning null graphics.");
    return null;
  }
  graphics=formatter.getGraphics(width,height,getTransparent());
  if (graphics == null) {
    logger.warning("ImageServer.createGraphics: NOT able to create Graphics!");
    return null;
  }
  if (logger.isLoggable(Level.FINE)) {
    logger.fine("graphics is cool");
  }
  if (doAntiAliasing && graphics instanceof java.awt.Graphics2D) {
    java.awt.Graphics2D g2d=(java.awt.Graphics2D)graphics;
    g2d.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING,RenderingHints.VALUE_TEXT_ANTIALIAS_ON);
    g2d.setRenderingHint(RenderingHints.KEY_ANTIALIASING,RenderingHints.VALUE_ANTIALIAS_ON);
  }
  return graphics;
}

protected Graphics createGraphics ( ImageFormatter formatter , int width , int height ) { java . awt . Graphics graphics = null ; if ( formatter == null ) { logger . warning ( "ImageServer.createGraphics: Formatter is null, returning null graphics." ) ; return null ; } graphics = formatter . getGraphics ( width , height , getTransparent ( ) ) ; if ( graphics == null ) { logger . warning ( "ImageServer.createGraphics: NOT able to create Graphics!" ) ; return null ; } if ( logger . isLoggable ( Level . FINE ) ) { logger . fine ( "graphics is cool" ) ; } if ( doAntiAliasing && graphics instanceof java . awt . Graphics2D ) { java . awt . Graphics2D g2d = ( java . awt . Graphics2D ) graphics ; g2d . setRenderingHint ( RenderingHints . KEY_TEXT_ANTIALIASING , RenderingHints . VALUE_TEXT_ANTIALIAS_ON ) ; g2d . setRenderingHint ( RenderingHints . KEY_ANTIALIASING , RenderingHints . VALUE_ANTIALIAS_ON ) ; } return graphics ; }
create a java . awt . graphics to use for an image . the graphics will affect the image contained within the imageformatter .
