Java Code Examples for mil.nga.geopackage.style.Color#getOpacity()

The following examples show how to use mil.nga.geopackage.style.Color#getOpacity() . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: StyleRow.java    From geopackage-android with MIT License 5 votes vote down vote up
/**
 * Set the color
 *
 * @param color color
 */
public void setColor(Color color) {
    String hex = null;
    Double opacity = null;
    if (color != null) {
        hex = color.getColorHexShorthand();
        opacity = new Double(color.getOpacity());
    }
    setColor(hex);
    setOpacity(opacity);
}
 
Example 2
Source File: StyleRow.java    From geopackage-android with MIT License 5 votes vote down vote up
/**
 * Set the color
 *
 * @param color color
 */
public void setFillColor(Color color) {
    String hex = null;
    Double opacity = null;
    if (color != null) {
        hex = color.getColorHexShorthand();
        opacity = new Double(color.getOpacity());
    }
    setFillColor(hex);
    setFillOpacity(opacity);
}
 
Example 3
Source File: StyleRow.java    From geopackage-java with MIT License 5 votes vote down vote up
/**
 * Set the color
 * 
 * @param color
 *            color
 */
public void setColor(Color color) {
	String hex = null;
	Double opacity = null;
	if (color != null) {
		hex = color.getColorHexShorthand();
		opacity = new Double(color.getOpacity());
	}
	setColor(hex);
	setOpacity(opacity);
}
 
Example 4
Source File: StyleRow.java    From geopackage-java with MIT License 5 votes vote down vote up
/**
 * Set the color
 * 
 * @param color
 *            color
 */
public void setFillColor(Color color) {
	String hex = null;
	Double opacity = null;
	if (color != null) {
		hex = color.getColorHexShorthand();
		opacity = new Double(color.getOpacity());
	}
	setFillColor(hex);
	setFillOpacity(opacity);
}