|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IlLineStyle
This interface describes a pattern with which a 1D line can be filled.
When a line is drawn, the pattern is drawn in the foreground color,
and the remainder of the line is drawn in the background color.
If the background color is null, it means that the line is transparent.
| Method Summary | |
|---|---|
double |
drawLine(Graphics g,
int x1,
int y1,
int x2,
int y2,
Color foreground,
Color background,
double offset)
Draws a line of thickness 1. |
double |
getPeriod()
Returns the periodicity of the pattern. |
int |
pixelColor(double offset)
Returns the color for a given offset. |
| Method Detail |
|---|
double getPeriod()
int pixelColor(double offset)
double drawLine(Graphics g,
int x1,
int y1,
int x2,
int y2,
Color foreground,
Color background,
double offset)
g - The Graphics where the line will be drawn.x1 - Starting point of the line.y1 - Starting point of the line.x2 - End point of the line.y2 - End point of the line.foreground - Foreground color.background - Background color or null.offset - The starting pixel within the pattern (>=0, < getPeriod()).
|
||||||||||
| PREV CLASS Documentation homepage NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||