:octocat: fix PHPCS config, add Slevomat rules

This commit is contained in:
smiley
2024-07-21 14:54:15 +02:00
parent 89cdd09044
commit f32696c8a7
97 changed files with 462 additions and 654 deletions
+10 -12
View File
@@ -19,7 +19,7 @@ use chillerlan\QRCode\Data\QRMatrix;
use chillerlan\QRCode\Output\QRGdImagePNG;
use chillerlan\Settings\SettingsContainerInterface;
require_once __DIR__ . '/../vendor/autoload.php';
require_once __DIR__.'/../vendor/autoload.php';
// --------------------
// Class definition
@@ -27,7 +27,6 @@ require_once __DIR__ . '/../vendor/autoload.php';
class QRGdRounded extends QRGdImagePNG{
/** @inheritDoc */
public function __construct(SettingsContainerInterface|QROptions $options, QRMatrix $matrix){
// enable the internal scaling for better rounding results at scale < 20
$options->drawCircularModules = true;
@@ -35,7 +34,6 @@ class QRGdRounded extends QRGdImagePNG{
parent::__construct($options, $matrix);
}
/** @inheritDoc */
protected function module(int $x, int $y, int $M_TYPE):void{
/**
@@ -121,7 +119,7 @@ class QRGdRounded extends QRGdImagePNG{
(int)($y * $this->scale + $this->scale / 2),
($this->scale - 1),
($this->scale - 1),
$light
$light,
);
}
@@ -133,14 +131,14 @@ class QRGdRounded extends QRGdImagePNG{
// --------------------
$options = new QROptions([
'version' => 7,
'eccLevel' => EccLevel::H,
'outputInterface' => QRGdRounded::class,
'outputBase64' => false,
'scale' => 30,
'addLogoSpace' => true,
'logoSpaceWidth' => 13,
'logoSpaceHeight' => 13,
'version' => 7,
'eccLevel' => EccLevel::H,
'outputInterface' => QRGdRounded::class,
'outputBase64' => false,
'scale' => 30,
'addLogoSpace' => true,
'logoSpaceWidth' => 13,
'logoSpaceHeight' => 13,
]);