Skip to content

QrColor

Alexander Zhirkevich edited this page Sep 5, 2022 · 1 revision

Style of QR code element painting

Source

fun interface QrColor  {

    @ColorInt
    operator fun invoke(i: Int, j: Int, width: Int, height: Int) : Int
}

Methods

 @ColorInt
 operator fun invoke(i: Int, j: Int, width: Int, height: Int) : Int

Return [i,j] pixel color of current element

Default implementations

Implementation Description
QrColor.Unspecified Special color style. If it is applied to frame or ball - they will be painted as dark pixels. If it is applied to logo background - it will be painted as QR code background. Otherwise - returns transparent colour
QrColor.Solid Solid color
QrColor.LinearGradient Linear gradient
QrColor.SquareGradient Square gradient
QrColor.RhombusGradient Rhombus gradient
QrColor.RadialGradient Radial gradient
QrColor.CrossingGradient Crossing gradient
Clone this wiki locally