de.enough.polish.ui.backgrounds
Class GradientRadialBackground
java.lang.Object
de.enough.polish.ui.Background
de.enough.polish.ui.backgrounds.GradientRadialBackground
- All Implemented Interfaces:
- Serializable
public class GradientRadialBackground
- extends Background
Generates a radial gradient from the inner-color to the outer-color.
- Author:
- Robert Virkus
|
Constructor Summary |
GradientRadialBackground(int innerColor,
int outerColor,
int start,
int end)
Creates a new radial gradient background |
GradientRadialBackground(int innerColor,
int outerColor,
int start,
int end,
int centerX,
int centerY)
Creates a new radial gradient background |
|
Method Summary |
void |
paint(int x,
int y,
int width,
int height,
javax.microedition.lcdui.Graphics g)
Paints this background. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
GradientRadialBackground
public GradientRadialBackground(int innerColor,
int outerColor,
int start,
int end)
- Creates a new radial gradient background
- Parameters:
innerColor - the color at the top of the gradientouterColor - the color at the bottom of the gradientstart - the line counted from the top at which the gradient starts, either in pixels or in percentend - the line counted from the top at which the gradient ends, either in pixels or in percent
GradientRadialBackground
public GradientRadialBackground(int innerColor,
int outerColor,
int start,
int end,
int centerX,
int centerY)
- Creates a new radial gradient background
- Parameters:
innerColor - the color at the top of the gradientouterColor - the color at the bottom of the gradientstart - the line counted from the top at which the gradient starts, either in pixels or in percentend - the line counted from the top at which the gradient ends, either in pixels or in percentcenterX - the horizontal center in percent. 0 is the center, -100 is the very left, +100 the very rightcenterY - the vertical center in percent. 0 is the center, -100 is the very top, +100 the very bottom
paint
public void paint(int x,
int y,
int width,
int height,
javax.microedition.lcdui.Graphics g)
- Description copied from class:
Background
- Paints this background.
- Specified by:
paint in class Background
- Parameters:
x - the horizontal start pointy - the vertical start pointwidth - the width of the backgroundheight - the height of the backgroundg - the Graphics on which the background should be painted.