Skip to content

Getting stuck in while loop #148

@nilstr

Description

@nilstr

There are still a problem where the code gets stuck in a never ending loop in the current version. Probably related to the text length and column width. When using the eztable function the code can get stuck in a loop. I narrowed it down to the ezText function getting run with the following parameters:

$pdf->ezText("<b>Konto</b>", 10, [ "aleft" => 55.14, "aright" => 59.477, "justification" => "left"], 0);

Which make this line never return an empty string. So the while loop continues forever.

$line = $this->addText($left, $this->y, $size, $line, $right - $left, $just, 0, 0, $test);

Can be reproduced with this code:

<?php

include 'src/Cezpdf.php';

$pdf = new Cezpdf();

$pdf->ezText("<b>Konto</b>", 10, [ "aleft" => 55.14, "aright" => 59.477, "justification" => "left"], 0);

$pdf->ezStream();

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions