Package com.ms.fx Previous
Previous
Contents
Contents
Index
Index
Next
Next

Class FxFill

Constructors , Methods

public abstract class FxFill extends FxColor
 {
  // Constructors
  public FxFill();
  public FxFill(int rgb);
  public FxFill(int r, int g, int b);

  // Methods
  public boolean fillRectCallback(FxGraphics g, int x, int y, int width, int height);
  public boolean drawLineCallback(FxGraphics g, int x1, int y1, int x2, int y2);
  public boolean drawScanLinesCallback(FxGraphics g, boolean xChanging, int points[], int offset, int nPoints);
  public boolean drawPolygonCallback(FxGraphics g, int xPoints[], int yPoints[], int nPoints);
  public boolean drawRectCallback(FxGraphics g, int x, int y, int width, int height);
  public boolean drawRoundRectCallback(FxGraphics g, int x, int y, int width, int height, int arcWidth, int arcHeight);
  public boolean fillRoundRectCallback(FxGraphics g, int x, int y, int width, int height, int arcWidth, int arcHeight);
  public boolean drawOvalCallback(FxGraphics g, int x, int y, int width, int height);
  public boolean fillOvalCallback(FxGraphics g, int x, int y, int width, int height);
  public boolean drawArcCallback(FxGraphics g, int x, int y, int width, int height, int startAngle, int arcAngle);
  public boolean fillArcCallback(FxGraphics g, int x, int y, int width, int height, int startAngle, int arcAngle);
  public boolean fillPolygonCallback(FxGraphics g, int xPoints[], int yPoints[], int nPoints);
  public boolean drawStringCallback(FxGraphics g, String str, int x, int y, Rectangle r, int options,
							 int dx[], int dy[], boolean metaList);
  public boolean drawCharsCallback(FxGraphics g, char data[], int offset, int length, int x, int y,
							 Rectangle r, int options, int dx[], int dy[], boolean metaList);
  public boolean drawBytesCallback(FxGraphics g, byte data[], int offset, int length, int x, int y,
							 Rectangle r, int options, int dx[], int dy[], boolean metaList);
  public boolean fill3DRectCallback(FxGraphics g, int x, int y, int width, int height, boolean raised);
  public boolean draw3DRectCallback(FxGraphics g, int x, int y, int width, int height, boolean raised);
}

A class that defines and manages fill objects.

The Microsoft com.ms.fx Java package is more powerful and more flexible than other graphics packages because it uses extensible objects.


Constructors


FxFill

public FxFill();

Creates a fill object.


FxFill

public FxFill(int rgb);

Creates a fill object with a default color.

ParameterDescription
rgb The RGB (red, green, and blue) color to use as a default.


FxFill

public FxFill(int r, int g, int b);

Creates a fill object with a default color setting.

ParameterDescription
r The amount of red.
g The amount of green.
b The amount of blue.


Methods


fillRectCallback

public boolean fillRectCallback(FxGraphics g, int x, int y, int width, int height);

Draws a filled rectangle.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the rectangle's starting point.
y The y coordinate of the rectangle's starting point.
width The width of the rectangle.
height The height of the rectangle.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawLineCallback

public boolean drawLineCallback(FxGraphics g, int x1, int y1, int x2, int y2);

Draws a line.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x1 The x coordinate of the starting point of the line.
y1 The y coordinate of the starting point of the line.
x2 The x coordinate of the ending point of the line.
y2 The y coordinate of the ending point of the line.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawScanLinesCallback

public boolean drawScanLinesCallback(FxGraphics g, boolean xChanging, int points[], int offset, int nPoints);

Draws fast lines, either horizontally or vertically.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
xChanging The direction the line should be drawn, either horizontally or vertically.
points An array of points.
offset The offset to use.
nPoints The number of points in the array.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawPolygonCallback

public boolean drawPolygonCallback(FxGraphics g, int xPoints[], int yPoints[], int nPoints);

Draws a polygon.

Return Value:

Returns true if successful; otherwise returns false.

ParameterDescription
g The graphics object to use.
xPoints An array containing the polygon's x coordinates.
yPoints An array containing the polygon's y coordinates.
nPoints The number of points in the polygon.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawRectCallback

public boolean drawRectCallback(FxGraphics g, int x, int y, int width, int height);

Draws a rectangle.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the rectangle's starting point.
y The y coordinate of the rectangle's starting point.
width The width of the rectangle.
height The height of the rectangle.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawRoundRectCallback

public boolean drawRoundRectCallback(FxGraphics g, int x, int y, int width, int height, int arcWidth, int arcHeight);

Draws a rectangle that has rounded edges.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the rectangle's starting point.
y The y coordinate of the rectangle's starting point.
width The width of the rectangle.
height The height of the rectangle.
arcWidth The arc width of the rectangle's rounded edges.
arcHeight The arc height of the rectangle's rounded edges.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


fillRoundRectCallback

public boolean fillRoundRectCallback(FxGraphics g, int x, int y, int width, int height, int arcWidth, int arcHeight);

Draws a filled rectangle that has rounded edges.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the rectangle's starting point.
y The y coordinate of the rectangle's starting point.
width The width of the rectangle.
height The height of the rectangle.
arcWidth The arc width of the rectangle's rounded edges.
arcHeight The arc height of the rectangle's rounded edges.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawOvalCallback

public boolean drawOvalCallback(FxGraphics g, int x, int y, int width, int height);

Draws an oval.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the upper left part of the oval.
y The y coordinate of the upper left part of the oval.
width The width of the oval.
height The height of the oval.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


fillOvalCallback

public boolean fillOvalCallback(FxGraphics g, int x, int y, int width, int height);

Draws a filled oval.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the upper left part of the oval.
y The y coordinate of the upper left part of the oval.
width The width of the oval.
height The height of the oval.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawArcCallback

public boolean drawArcCallback(FxGraphics g, int x, int y, int width, int height, int startAngle, int arcAngle);

Draws an arc.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the arc's starting point.
y The y coordinate of the arc's starting point.
width The width of the arc.
height The height of the arc.
startAngle The starting angle of the arc.
arcAngle The angle of the arc.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


fillArcCallback

public boolean fillArcCallback(FxGraphics g, int x, int y, int width, int height, int startAngle, int arcAngle);

Draws a filled arc.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the arc's starting point.
y The y coordinate of the arc's starting point.
width The width of the arc.
height The height of the arc.
startAngle The starting angle of the arc.
arcAngle The angle of the arc.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


fillPolygonCallback

public boolean fillPolygonCallback(FxGraphics g, int xPoints[], int yPoints[], int nPoints);

Draws a filled polygon.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
xPoints An array containing the polygon's x coordinates.
yPoints An array containing the polygon's y coordinates.
nPoints The number of points in the polygon.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawStringCallback

public boolean drawStringCallback(FxGraphics g, String str, int x, int y, Rectangle r, int options, int dx[], int dy[], boolean metaList);

Draws a string.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
str The string to draw.
x The x coordinate of the location where the string should be drawn.
y The y coordinate of the location where the string should be drawn.
r The optional rectangle for clipping and opaquing.
options The options for this method.
dx An array of dx values.
dy An array of dy values.
metaList The value that determines if a meta list should be used.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawCharsCallback

public boolean drawCharsCallback(FxGraphics g, char data[], int offset, int length, int x, int y, Rectangle r, int options, int dx[], int dy[], boolean metaList);

Draw an array of characters.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
data The array of characters to be drawn.
offset The offset to use.
length The length of the array used.
x The x coordinate of the location where the characters should be drawn.
y The y coordinate of the location where the characters should be drawn.
r The optional rectangle for clipping and opaquing.
options The options for this method.
dx An array of dx values.
dy An array of dy values.
metaList The value that determines if a meta list should be used.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


drawBytesCallback

public boolean drawBytesCallback(FxGraphics g, byte data[], int offset, int length, int x, int y, Rectangle r, int options, int dx[], int dy[], boolean metaList);

Draws an array of bytes.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
data The array of bytes.
offset The offset to use.
length The length of the array used.
x The x coordinate of the location where the bytes should be drawn.
y The y coordinate of the location where the bytes should be drawn.
r The optional rectangle for clipping and opaquing.
options The options for this method.
dx An array of dx values.
dy An array of dy values.
metaList The value that determines if a meta list should be used.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


fill3DRectCallback

public boolean fill3DRectCallback(FxGraphics g, int x, int y, int width, int height, boolean raised);

Draws a filled three-dimensional rectangle.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the location where the rectangle is drawn.
y The y coordinate of the location where the rectangle is drawn.
width The width of the rectangle.
height The height of the rectangle.
raised Determines if the three-dimensional edge is raised or sunken.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.


draw3DRectCallback

public boolean draw3DRectCallback(FxGraphics g, int x, int y, int width, int height, boolean raised);

Draws a three-dimensional rectangle.

Return Value:

Returns true if successful; otherwise, returns false.

ParameterDescription
g The graphics object to use.
x The x coordinate of the location where the rectangle is drawn.
y The y coordinate of the location where the rectangle is drawn.
width The width of the rectangle.
height the height of the rectangle.
raised Determines if the three-dimensional edge is raised or sunken.

Remarks:

This method is used internally and is not intended to be called by applications. It is made public so that derived classes may extend the callback functionality.



Top© 1997 Microsoft Corporation. All rights reserved. Legal Notices.