Source
<?php
/*
** Zabbix
** Copyright (C) 2001-2023 Zabbix SIA
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License as published by
** the Free Software Foundation; either version 2 of the License, or
** (at your option) any later version.
**
** This program is distributed in the hope that it will be useful,
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not, write to the Free Software
** Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
**/
/**
* Draws a table containing text or images.
*/
class CImageTextTable {
public $image;
public $fontsize;
public $color;
public $align;
public $x;
public $y;
/**
* Minimal row height. If the height of some row is bigger then given, the $rowheight will be set to this height.
*
* @var int
*/
public $rowheight;
private $table;
private $numrows;
public function __construct($image, $x, $y) {
$this->image = $image;
$this->fontsize = 8;
$this->rowheight = 0;
$this->color = 0;
$this->align = 0;
$this->x = $x;
$this->y = $y;
$this->table = [];
$this->numrows = 0;
}
public function getNumRows() {
return $this->numrows;
}
/**
* Adds a new table cell.
*
* Supported $cell options: