diff --git a/Abrechnung/module.php b/Abrechnung/module.php index 447f250..195dcda 100644 --- a/Abrechnung/module.php +++ b/Abrechnung/module.php @@ -305,12 +305,22 @@ class Abrechnung extends IPSModule $style = ['border' => false, 'padding' => 0, 'fgcolor' => [0, 0, 0], 'bgcolor' => false]; $pdf->write2DBarcode($qrString, 'QRCODE,M', 67, $yStart + 17, 46, 46, $style, 'N'); - // Schweizer Kreuz über den QR Code zeichnen (7x7mm Block) - $pdf->SetFillColor(0, 0, 0); - $pdf->Rect(67 + 19.5, $yStart + 17 + 19.5, 7, 7, 'F'); +// Schweizer Kreuz über den QR Code zeichnen (Spezifikation: 7x7mm inkl. weissem Rand) + $cX = 67 + 23; // Zentrum X des QR Codes (Position 67 + Hälfte von 46) + $cY = $yStart + 17 + 23; // Zentrum Y des QR Codes (Position 17 + Hälfte von 46) + + // 1. Weisser Hintergrund (Rand) - 7x7 mm $pdf->SetFillColor(255, 255, 255); - $pdf->Rect(67 + 19.5 + 3, $yStart + 17 + 19.5 + 1, 1, 5, 'F'); - $pdf->Rect(67 + 19.5 + 1, $yStart + 17 + 19.5 + 3, 5, 1, 'F'); + $pdf->Rect($cX - 3.5, $cY - 3.5, 7, 7, 'F'); + + // 2. Schwarzes Quadrat - ca. 6x6 mm (ergibt ringsum 0.5mm weissen Rand) + $pdf->SetFillColor(0, 0, 0); + $pdf->Rect($cX - 3, $cY - 3, 6, 6, 'F'); + + // 3. Weisses Schweizer Kreuz (Balkenbreite ca. 1.2mm, Länge ca. 4mm) + $pdf->SetFillColor(255, 255, 255); + $pdf->Rect($cX - 0.6, $cY - 2, 1.2, 4, 'F'); // Vertikaler Balken + $pdf->Rect($cX - 2, $cY - 0.6, 4, 1.2, 'F'); // Horizontaler Balken $pdf->SetFont('dejavusans', 'B', 8); $pdf->SetXY(118, $yStart + 17);