smiley 2 лет назад
Родитель
Сommit
334fe5a42f
3 измененных файлов с 5 добавлено и 7 удалено
  1. 4 4
      examples/imageWithRoundedShapes.php
  2. 0 2
      examples/imagickImageAsBackground.php
  3. 1 1
      examples/text.php

+ 4 - 4
examples/imageWithRoundedShapes.php

@@ -62,28 +62,28 @@ class QRGdRounded extends QRGdImagePNG{
 		// Outer rounding
 		// Outer rounding
 		// ------------------
 		// ------------------
 
 
-		if($neighbours & (1 << 7)){ // neighbour left
+		if(($neighbours & (1 << 7))){ // neighbour left
 			// top left
 			// top left
 			imagefilledrectangle($this->image, $x1, $y1, ($x1 + $rectsize), ($y1 + $rectsize), $light);
 			imagefilledrectangle($this->image, $x1, $y1, ($x1 + $rectsize), ($y1 + $rectsize), $light);
 			// bottom left
 			// bottom left
 			imagefilledrectangle($this->image, $x1, ($y2 - $rectsize), ($x1 + $rectsize), $y2, $light);
 			imagefilledrectangle($this->image, $x1, ($y2 - $rectsize), ($x1 + $rectsize), $y2, $light);
 		}
 		}
 
 
-		if($neighbours & (1 << 3)){ // neighbour right
+		if(($neighbours & (1 << 3))){ // neighbour right
 			// top right
 			// top right
 			imagefilledrectangle($this->image, ($x2 - $rectsize), $y1, $x2, ($y1 + $rectsize), $light);
 			imagefilledrectangle($this->image, ($x2 - $rectsize), $y1, $x2, ($y1 + $rectsize), $light);
 			// bottom right
 			// bottom right
 			imagefilledrectangle($this->image, ($x2 - $rectsize), ($y2 - $rectsize), $x2, $y2, $light);
 			imagefilledrectangle($this->image, ($x2 - $rectsize), ($y2 - $rectsize), $x2, $y2, $light);
 		}
 		}
 
 
-		if($neighbours & (1 << 1)){ // neighbour top
+		if(($neighbours & (1 << 1))){ // neighbour top
 			// top left
 			// top left
 			imagefilledrectangle($this->image, $x1, $y1, ($x1 + $rectsize), ($y1 + $rectsize), $light);
 			imagefilledrectangle($this->image, $x1, $y1, ($x1 + $rectsize), ($y1 + $rectsize), $light);
 			// top right
 			// top right
 			imagefilledrectangle($this->image, ($x2 - $rectsize), $y1, $x2, ($y1 + $rectsize), $light);
 			imagefilledrectangle($this->image, ($x2 - $rectsize), $y1, $x2, ($y1 + $rectsize), $light);
 		}
 		}
 
 
-		if($neighbours & (1 << 5)){ // neighbour bottom
+		if(($neighbours & (1 << 5))){ // neighbour bottom
 			// bottom left
 			// bottom left
 			imagefilledrectangle($this->image, $x1, ($y2 - $rectsize), ($x1 + $rectsize), $y2, $light);
 			imagefilledrectangle($this->image, $x1, ($y2 - $rectsize), ($x1 + $rectsize), $y2, $light);
 			// bottom right
 			// bottom right

+ 0 - 2
examples/imagickImageAsBackground.php

@@ -112,5 +112,3 @@ if(PHP_SAPI !== 'cli'){
 }
 }
 
 
 exit;
 exit;
-
-

+ 1 - 1
examples/text.php

@@ -44,6 +44,6 @@ $options->moduleValues  = [
 $out  = (new QRCode($options))->render('https://www.youtube.com/watch?v=dQw4w9WgXcQ');
 $out  = (new QRCode($options))->render('https://www.youtube.com/watch?v=dQw4w9WgXcQ');
 
 
 
 
-echo "\n\n\n$out\n\n\n";
+printf("\n\n\n%s\n\n\n", $out);
 
 
 exit;
 exit;