/// <summary> /// /// </summary> /// <param name="offset">Gradient offset, between 0.0f and 1.0f</param> /// <param name="color"><see cref="SciterColor"/> value</param> /// <returns></returns> public static SciterColorStop Create(float offset, SciterColor color) { return(new SciterColorStop(offset, color)); }
public bool Equals(SciterColor other) { return(Value == other.Value); }
internal SciterColorStop(float offset, SciterColor color) { Offset = offset; Color = color; }
internal SciterColorStop(float offset, byte r, byte g, byte b, byte alpha) { Offset = offset; Color = SciterColor.Create(r: r, g: g, b: b, alpha: alpha); }
/// <summary> /// Reads the <see cref="SciterValue"/> as a <see cref="SciterColor"/> /// </summary> /// <param name="sciterValue"></param> /// <param name="value">The output value</param> /// <returns></returns> public static bool TryAsColor(this SciterValue sciterValue, out SciterColor value) { return(sciterValue.TryAsColorInternal(out value)); }
public static bool TrySetFillColor(this SciterGraphics graphics, SciterColor fillColor) { return(graphics?.TrySetFillColorInternal(fillColor: fillColor) == true); }
public static SciterGraphics SetFillColor(this SciterGraphics graphics, SciterColor fillColor) { graphics?.SetFillColorInternal(fillColor: fillColor); return(graphics); }
public static bool TrySetLineColor(this SciterGraphics graphics, SciterColor lineColor) { return(graphics?.TrySetLineColorInternal(lineColor: lineColor) == true); }
public static SciterGraphics SetLineColor(this SciterGraphics graphics, SciterColor lineColor) { graphics?.SetLineColorInternal(lineColor: lineColor); return(graphics); }