Package org.robolectric.shadows
Class ShadowColor
java.lang.Object
org.robolectric.shadows.ShadowColor
@Implements(android.graphics.Color.class) public class ShadowColor extends Object
- 
Constructor SummaryConstructors Constructor Description ShadowColor()
- 
Method SummaryModifier and Type Method Description protected static intHSVToColor(int alpha, float[] hsv)protected static voidRGBToHSV(int red, int green, int blue, float[] hsv)This is implemented in native code in the Android SDK.
- 
Constructor Details- 
ShadowColorpublic ShadowColor()
 
- 
- 
Method Details- 
RGBToHSVThis is implemented in native code in the Android SDK.Since HSV == HSB then the implementation from Colorcan be used, with a small adjustment to the representation of the hue.Colorrepresents hue as 0..1 (where 1 == 100% == 360 degrees), whileColorrepresents hue as 0..360 degrees. The correct hue can be calculated by multiplying with 360.- Parameters:
- red- Red component
- green- Green component
- blue- Blue component
- hsv- Array to store HSV components
 
- 
HSVToColor
 
-