SimpleSoftwareIO\QrCode\BaconQrCodeGenerator::color PHP Method

color() public method

Changes the foreground color of a QrCode.
public color ( integer $red, integer $green, integer $blue )
$red integer
$green integer
$blue integer
    public function color($red, $green, $blue)
    {
        $this->writer->getRenderer()->setForegroundColor(new Rgb($red, $green, $blue));
        return $this;
    }

Usage Example

Beispiel #1
0
 /**
  * Changes the foreground color of a QrCode
  *
  * @param int $red
  * @param int $green
  * @param int $blue
  * @return $this 
  * @static 
  */
 public static function color($red, $green, $blue)
 {
     return \SimpleSoftwareIO\QrCode\BaconQrCodeGenerator::color($red, $green, $blue);
 }