ForeColor, BackColor Properties

Determine the foreground and background colors used to draw the barcode.


public SimpleColor getForeSimpleColor()
public void setForeSimpleColor(SimpleColor value)

public SimpleColor getBackSimpleColor() public void setBackSimpleColor(SimpleColor value)
AWT Version
public Color getForeColor()
public void setForeColor(Color foreColor)

public Color getBackColor() public void setBackColor(Color backColor)
(Color refers to java.awt.Color)


foreColor, backColor

Specify the foreground and background colors.


If you're using the PNG image format, you need to keep in mind with the current generation of browsers, the support for PNG is limited and therefore changing these properties may result in an image that cannot be well rendered by the browsers (technically, certain browsers may fail to render PNG images that contain a palette).

The default values are black for foreColor and white for backColor.

SimpleColor is defined as,

package com.bokai.drawing;

public class SimpleColor
	// 0-255 for each value
	public SimpleColor(int r, int g, int b)
	public java.awt.Color getColor();
	public int getRed();
	public int getGreen();
	public int getBlue();
	public int getRGB();