Here you can find the source of toARGB(String colorString)
Parameter | Description |
---|---|
colorString | #RRGGBB or #AARRGGBB or... read Color#parseColor(String) |
public static int toARGB(String colorString)
//package com.java2s; //License from project: Open Source License public class Main { /**/* w ww . jav a 2 s .co m*/ * @param alpha * [0..255] * @param red * [0..255] * @param green * [0..255] * @param blue * [0..255] * @return the calculated argb value */ public static int toARGB(int alpha, int red, int green, int blue) { return android.graphics.Color.argb(alpha, red, green, blue); } /** * @param colorString * #RRGGBB or #AARRGGBB or... read * {@link Color#parseColor(String)} * @return */ public static int toARGB(String colorString) { return android.graphics.Color.parseColor(colorString); } }