Skip to content

gradientCenterX,gradientCenterY不是dimension,应该是float #164

@Sigasiiiiii

Description

@Sigasiiiiii

/**
* Sets the position of the center of the gradient as a fraction of the
* width and height.
*


* The default value is (0.5, 0.5).
*


* Note: changing this property will affect all instances
* of a drawable loaded from a resource. It is recommended to invoke
* {@link #mutate()} before changing this property.
*
* @param x the X-position of the center of the gradient
* @param y the Y-position of the center of the gradient
*
* @see #mutate()
* @see #setGradientType(int)
* @see #getGradientCenterX()
* @see #getGradientCenterY()
*/
public void setGradientCenter(float x, float y) {
mGradientState.setGradientCenter(x, y);
mGradientIsDirty = true;
invalidateSelf();
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions