Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gradient + Margin issue #211

Open
restyler opened this issue Dec 24, 2020 · 0 comments
Open

Gradient + Margin issue #211

restyler opened this issue Dec 24, 2020 · 0 comments

Comments

@restyler
Copy link

restyler commented Dec 24, 2020

When I attach gradient to the qrcode, the margin trims eyes incorrectly. Images with issue and the code is attached.
simple-qrcode v.4.1.0
php 7.4.13
imagick module 3.4.4

With svg, everything works properly.

<?php
ini_set('display_errors', 1);

require_once '../vendor/autoload.php';
use SimpleSoftwareIO\QrCode\Generator;

$qrcode = new Generator;

$format = $_GET['format'] ?? 'svg';
$qrcode->format($format);
$qrcode->margin(2);
$qrcode->gradient(100,100,55,100,100,255,'horizontal');

if ($format == 'png') {
    header('Content-Type: image/png');
}

echo $qrcode->size(600)->generate('https://test.net/very-long-url');

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant