b374k
m1n1 1.01
Apache/2.4.41 (Ubuntu)
Linux vmi616275.contaboserver.net 5.4.0-84-generic #94-Ubuntu SMP Thu Aug 26 20:27:37 UTC 2021 x86_64
uid=33(www-data) gid=33(www-data) groups=33(www-data)
server ip : 62.171.164.128 | your ip : 127.0.0.1
safemode OFF
 >  / home / dev2.destoffenstraat.com / vendor / dompdf / dompdf / src / FrameReflower /
Filename/home/dev2.destoffenstraat.com/vendor/dompdf/dompdf/src/FrameReflower/TableRow.php
Size2.14 kb
Permissionrw-r--r--
Ownerroot : root
Create time17-Aug-2025 10:26
Last modified15-Jan-2025 15:09
Last accessed23-Aug-2025 03:56
Actionsedit | rename | delete | download (gzip)
Viewtext | code | image
<?php
/**
* @package dompdf
* @link https://github.com/dompdf/dompdf
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
*/
namespace Dompdf\FrameReflower;

use Dompdf\FrameDecorator\Block as BlockFrameDecorator;
use Dompdf\FrameDecorator\Table as TableFrameDecorator;
use Dompdf\FrameDecorator\TableRow as TableRowFrameDecorator;
use Dompdf\Exception;

/**
* Reflows table rows
*
* @package dompdf
*/
class TableRow extends AbstractFrameReflower
{
/**
* TableRow constructor.
* @param TableRowFrameDecorator $frame
*/
function __construct(TableRowFrameDecorator $frame)
{
parent::__construct($frame);
}

/**
* @param BlockFrameDecorator|null $block
*/
function reflow(?BlockFrameDecorator $block = null)
{
/** @var TableRowFrameDecorator */
$frame = $this->_frame;

// Check if a page break is forced
$page = $frame->get_root();
$page->check_forced_page_break($frame);

// Bail if the page is full
if ($page->is_full()) {
return;
}

// Counters and generated content
$this->_set_content();

$frame->position();
$style = $frame->get_style();
$cb = $frame->get_containing_block();

foreach ($frame->get_children() as $child) {
$child->set_containing_block($cb);
$child->reflow();

if ($page->is_full()) {
break;
}
}

if ($page->is_full()) {
return;
}

$table = TableFrameDecorator::find_parent_table($frame);
if ($table === null) {
throw new Exception("Parent table not found for table row");
}
$cellmap = $table->get_cellmap();

$style->set_used("width", $cellmap->get_frame_width($frame));
$style->set_used("height", $cellmap->get_frame_height($frame));

$frame->set_position($cellmap->get_frame_position($frame));
}

/**
* @throws Exception
*/
public function get_min_max_width(): array
{
throw new Exception("Min/max width is undefined for table rows");
}
}