Creates a filled rectangle.

@access private
@return void
500617
private function createRectangle($color)
    {
        imagefilledrectangle(
            $this->resource,
            0,
            0,
            $this->width,
            $this->height,
            $color
        );
    }
523750
public function fill()
    {
        $totalColumn = $this->db->getTotalColumns();
        $rows = array();
        for ($n = 0; $n < $this->num; $n++) {
            $fakeRow = new DbRowEntity();
            for ($i = 0; $i < $totalColumn; $i++) {
                if ($this->db->isColumnAutoincrement($i)) {
                    continue;
                }
                $fieldName = $this->db->getColumnName($i);
                $fakeType = $this->db->getColumnType($i);
                $dataLength = $this->db->getColumnLength($i);
                $fakeData = $this->fakeColumn($fieldName, $fakeType, $dataLength);

                $fakeRow->setFields(new DbFieldEntity($fieldName, $fakeData[0], $fakeType, $dataLength));
            }
            $this->db->insert($fakeRow);

            $rows[] = $fakeRow->toArray();
        }

        return $rows;
    }
226857
public void fillEllipse(Rectangle rect, Color color) {
		template.saveState();
		setFill(color);
		template.ellipse(origX + rect.getLeft(), origY + rect.getBottom(), origX + rect.getRight(),
				origY + rect.getTop());
		template.fill();
		template.restoreState();
	}
1294657
function filledRectangle($x1, $y1, $width, $height) {
    $this->objects[$this->currentContents]['c'].=  sprintf("\n%.3F %.3F %.3F %.3F re f", $x1, $y1, $width, $height);
  }
541721
public function create()
    {
        $content = '';
        $pageNumber = $this->getPageNumber();

        if ($pageNumber === 0) {
            $pageNumber = 1;
        }

        if ($this->lastPage > 1) {
            $content .= "<div class='pagination'>";

            $content .= $this->renderPreviousLink($pageNumber);

            //not enough pages to bother breaking it up
            if ($this->lastPage < 7 + ($this->adjacent * 2)) {
                for ($counter = 1; $counter <= $this->lastPage; $counter++) {
                    $content .= $this->createCurrentActiveLink($pageNumber, $counter);
                }
            } elseif ($this->lastPage > 5 + ($this->adjacent * 2)) {
                //close to beginning; only hide later pages
                if ($pageNumber < 1 + ($this->adjacent * 2)) {
                    for ($counter = 1; $counter < 4 + ($this->adjacent * 2); $counter++) {
                        $content .= $this->createCurrentActiveLink($pageNumber, $counter);
                    }
                    $content .= '...';
                    $content .= $this->createSecondLink();
                } elseif (
                    $this->lastPage - ($this->adjacent * 2) > $pageNumber
                    && $pageNumber > ($this->adjacent * 2)
                ) {
                    $content .= $this->createPrimaryLink();
                    $content .= '...';

                    for (
                        $counter = $pageNumber - $this->adjacent;
                        $counter <= $pageNumber + $this->adjacent;
                        $counter++
                    ) {
                        $content .= $this->createCurrentActiveLink($pageNumber, $counter);
                    }

                    $content .= '...';
                    $content .= $this->createPrimaryLink();
                    $content .= $this->createSecondLink();
                } else {
                    //close to end; only hide early pages

                    $content .= $this->createPrimaryLink();

                    $content .= '...';
                    for (
                        $counter = $this->lastPage - (2 + ($this->adjacent * 2));
                        $counter <= $this->lastPage;
                        $counter++
                    ) {
                        $content .= $this->createCurrentActiveLink($pageNumber, $counter);
                    }
                }
            }

            $content .= $this->renderNextLink($counter, $pageNumber);
        }

        $this->paginationLinks = $content;
    }
1136180
public function fill()
    {
        // Write the position value to the pivot table
        if (isset($this->pivot->position)) {
            $this->pivot->position = request('position');
            $this->pivot->save();

        // Write position value to the item
        } elseif (isset($this->item->position)) {

            // Visiblity may be set at the same time and would be ignored otherwise
            if (Request::has('public')) {
                $this->item->public = request('public');
            }

            // Do position
            $this->item->position = request('position');
        }
    }
563028
private function createIm() {
        $w1 = imagesx($this->image1);
        $w2 = imagesx($this->image2);
        $h1 = imagesy($this->image1);
        $h2 = imagesy($this->image2);

        if ($this->position === self::POSITION_LEFT || $this->position === self::POSITION_RIGHT) {
            $w = $w1 + $w2 + $this->space;
            $h = max($h1, $h2);
        } else {
            $w = max($w1, $w2);
            $h = $h1 + $h2 + $this->space;
        }

        $this->im = imagecreatetruecolor($w, $h);
        imagefill($this->im, 0, 0, $this->background->allocate($this->im));

        // We start defining position of images
        if ($this->position === self::POSITION_TOP) {
            if ($w1 > $w2) {
                $posX1 = 0;
                $posX2 = $this->findPosition($w1, $w2, $this->alignment);
            } else {
                $a = $this->changeAlignment($this->alignment);
                $posX1 = $this->findPosition($w1, $w2, $a);
                $posX2 = 0;
            }

            $posY2 = 0;
            $posY1 = $h2 + $this->space;
        } elseif ($this->position === self::POSITION_LEFT) {
            if ($w1 > $w2) {
                $posY1 = 0;
                $posY2 = $this->findPosition($h1, $h2, $this->alignment);
            } else {
                $a = $this->changeAlignment($this->alignment);
                $posY2 = 0;
                $posY1 = $this->findPosition($h1, $h2, $a);
            }

            $posX2 = 0;
            $posX1 = $w2 + $this->space;
        } elseif ($this->position === self::POSITION_BOTTOM) {
            if ($w1 > $w2) {
                $posX2 = $this->findPosition($w1, $w2, $this->alignment);
                $posX1 = 0;
            } else {
                $a = $this->changeAlignment($this->alignment);
                $posX2 = 0;
                $posX1 = $this->findPosition($w1, $w2, $a);
            }

            $posY1 = 0;
            $posY2 = $h1 + $this->space;
        } else { // defaults to RIGHT
            if ($w1 > $w2) {
                $posY2 = $this->findPosition($h1, $h2, $this->alignment);
                $posY1 = 0;
            } else {
                $a = $this->changeAlignment($this->alignment);
                $posY2 = 0;
                $posY1 = $this->findPosition($h1, $h2, $a);
            }

            $posX1 = 0;
            $posX2 = $w1 + $this->space;
        }

        imagecopy($this->im, $this->image1, $posX1, $posY1, 0, 0, $w1, $h1);
        imagecopy($this->im, $this->image2, $posX2, $posY2, 0, 0, $w2, $h2);
    }
1221847
public function fill()
    {
        $params          = array_merge($this->attributes, [
            'id'            => $this->id,
            'widget'        => $this->model,
            'name'          => $this->name,
            'title'         => strlen($this->title) > 0 ? $this->title : $this->name,
            'description'   => $this->description,
            'editable'      => $this->editable(),
            'widgets'       => $this->widgets,
            'template'      => $this->template,
            'only_template' => $this->renderOnlyWithTemplate
        ]);
        $reflectionClass = new ReflectionClass(get_called_class());
        if ($reflectionClass->getParentClass()->getName() === "Antares\UI\UIComponents\Templates\Datatables") {
            array_set($params, 'datatable', true);
        }
        array_set($params, 'content', $this->templateAdapter->share($params)->decorate($this->render()));
        return $params;
    }
310361
protected function _construct() {
		parent::_construct();
		$this
			->_prop(self::$P__CONTENTS, DF_V_ARRAY)
			->_prop(self::$P__TAG, DF_V_STRING_NE)
			->_prop(self::P__1251, DF_V_BOOL, false)
			->_prop(self::P__ATTRIBUTES, DF_V_ARRAY, false)
			->_prop(self::P__DOC_TYPE, DF_V_STRING, false)
			->_prop(self::P__DECODE_ENTITIES, DF_V_BOOL, false)
			->_prop(self::P__PRETTY, DF_V_BOOL, false)
			->_prop(self::P__REMOVE_LINE_BREAKS, DF_V_BOOL, false)
			->_prop(self::P__SKIP_HEADER, DF_V_BOOL, false)
			->_prop(self::P__WRAP_IN_CDATA, DF_V_BOOL, false)
		;
	}
213624
function create()
    {
        $content = $this->loadContentTypes();
        $templates = $this->loadTemplates();
        restoreRequest();
        $form = array (
            'name' => 'createPage',
            'caption' => strAdd,
            'width' => '600px',
            'fields' => array (
                array ('type' => 'hidden','name'=>'owner','value'=>arg('owner', 'int')),
                array ('type' => 'hidden','name'=>'action', 'value'=>'insert'),
                array ('type' => 'edit','name' => 'name','label' => admPagesName,'width' => '150px',
                    'maxlength' => '32', 'pattern'=>'/^[a-z0-9_]+$/i', 'errormsg'=>admPagesNameInvalid),
                array ('type' => 'edit','name' => 'title','label' => admPagesTitle,'width' => '100%',
                    'pattern'=>'/.+/', 'errormsg'=>admPagesTitleInvalid),
                array ('type' => 'edit','name' => 'caption','label' => admPagesCaption,'width' => '100%',
                    'maxlength' => '64', 'pattern'=>'/.+/', 'errormsg'=>admPagesCaptionInvalid),
                array ('type' => 'edit','name' => 'hint','label' => admPagesHint,'width' => '100%'),
                array ('type' => 'edit','name' => 'description','label' => admPagesDescription,
                    'width' => '100%'),
                array ('type' => 'edit','name' => 'keywords','label' => admPagesKeywords,'width' => '100%'),
                array ('type' => 'select','name' => 'template','label' => admPagesTemplate,
                    'items' => $templates[0], 'values' => $templates[1], 'default'=>pageTemplateDefault),
                array ('type' => 'select','name' => 'type','label' => admPagesContentType,
                    'items' => $content[0], 'values' => $content[1], 'default'=>contentTypeDefault),
                array ('type' => 'checkbox','name' => 'active','label' => admPagesActive, 'default'=>true),
                array ('type' => 'checkbox','name' => 'visible','label' => admPagesVisible,
                    'default'=>true),
                array ('type' => 'select','name' => 'access','label' => admAccessLevel,'access' => ADMIN,
                    'values'=>array(ADMIN,EDITOR,USER,GUEST),
                    'items' => array (ACCESSLEVEL2,ACCESSLEVEL3,ACCESSLEVEL4,ACCESSLEVEL5),
                    'default' => GUEST),
                array ('type' => 'edit','name' => 'position','label' => admPosition,'access' => ADMIN,
                    'width' => '4em','maxlength' => '5'),
                array ('type' => 'memo','name' => 'options','label' => admPagesOptions,'height' => '5')
            ),
            'buttons' => array('ok', 'cancel'),
        );

        /** @var TAdminUI $page */
        $page = Eresus_Kernel::app()->getPage();
        $result = $page->renderForm($form, Eresus_CMS::getLegacyKernel()->request['arg']);
        return $result;
    }
691874
protected function createPdoInstance()
    {
        //Empty attributes property cases exception in Yajra\Pdo\Oci8::__construct() method
        if (!is_array($this->attributes))
            $this->attributes = [];

        try {
            return parent::createPdoInstance();
        } catch(PDOException $e) {
            throw $e;
        }
    }
423465
public function createConst() {

		$properties = get_object_vars($this);

		if(isset($properties['db'])) {
			foreach($properties['db'] as $k => $v) {
				if(is_scalar($v)) {
					$k = strtoupper($k);
					if(!defined("DB$k")) { define("DB$k", $v); }
				}
			}
		}

		if(isset($properties['site'])) {
			foreach($properties['site'] as $k => $v) {
				if(is_scalar($v)) {
					$k = strtoupper($k);
					if(!defined($k)) { define($k, $v); }
				}
			}
		}

		if(isset($properties['paths'])) {
			foreach($properties['paths'] as $k => $v) {
				$k = strtoupper($k);
				if(!defined($k)) { define($k, $v['subdir']); }
			}
		}

		$locale = localeconv();

		foreach($locale as $k => $v) {
			$k = strtoupper($k);
			if(!defined($k) && !is_array($v)) { define($k, $v); }
		}
	}
536163
public function createDimensionsShorthand() {
		$aPositions = array('top', 'right', 'bottom', 'left');
		$aExpansions = array(
			'margin' => 'margin-%s',
			'padding' => 'padding-%s',
			'border-color' => 'border-%s-color',
			'border-style' => 'border-%s-style',
			'border-width' => 'border-%s-width'
		);
		$aRules = $this->getRulesAssoc();
		foreach ($aExpansions as $sProperty => $sExpanded) {
			$aFoldable = array();
			foreach ($aRules as $sRuleName => $oRule) {
				foreach ($aPositions as $sPosition) {
					if ($sRuleName == sprintf($sExpanded, $sPosition)) {
						$aFoldable[$sRuleName] = $oRule;
					}
				}
			}
			// All four dimensions must be present
			if (count($aFoldable) == 4) {
				$aValues = array();
				foreach ($aPositions as $sPosition) {
					$oRule = $aRules[sprintf($sExpanded, $sPosition)];
					$mRuleValue = $oRule->getValue();
					$aRuleValues = array();
					if (!$mRuleValue instanceof RuleValueList) {
						$aRuleValues[] = $mRuleValue;
					} else {
						$aRuleValues = $mRuleValue->getListComponents();
					}
					$aValues[$sPosition] = $aRuleValues;
				}
				$oNewRule = new Rule($sProperty, $this->iLineNo);
				if ((string) $aValues['left'][0] == (string) $aValues['right'][0]) {
					if ((string) $aValues['top'][0] == (string) $aValues['bottom'][0]) {
						if ((string) $aValues['top'][0] == (string) $aValues['left'][0]) {
							// All 4 sides are equal
							$oNewRule->addValue($aValues['top']);
						} else {
							// Top and bottom are equal, left and right are equal
							$oNewRule->addValue($aValues['top']);
							$oNewRule->addValue($aValues['left']);
						}
					} else {
						// Only left and right are equal
						$oNewRule->addValue($aValues['top']);
						$oNewRule->addValue($aValues['left']);
						$oNewRule->addValue($aValues['bottom']);
					}
				} else {
					// No sides are equal 
					$oNewRule->addValue($aValues['top']);
					$oNewRule->addValue($aValues['left']);
					$oNewRule->addValue($aValues['bottom']);
					$oNewRule->addValue($aValues['right']);
				}
				$this->addRule($oNewRule);
				foreach ($aPositions as $sPosition) {
					$this->removeRule(sprintf($sExpanded, $sPosition));
				}
			}
		}
	}
752626
function filled_rectangle($x1, $y1, $w, $h, $color, $blend = "Normal", $opacity = 1.0) {
		//var_dump($color);
		//Helpers::dompdf_debug("trace", "($x1, $y1, $w, $h, [$color[0], $color[1], $color[2]], $blend, $opacity)");

		//$this->_set_stroke_color($color);
		//$this->_set_fill_color($color);
		//$this->_set_line_style(1, "square", "miter", array());
		$this->_set_line_transparency($blend, $opacity);
		$this->_set_fill_transparency($blend, $opacity);

		$this->_pdf->Rect($x1, $y1, $w, $h, 'F', $this->_make_line_style($color, 1, "square", "miter", array()), $this->_get_rgb($color)); //***

	}
1014001
function rectangle($x1, $y1, $width, $height)
    {
        $this->addContent(sprintf("\n%.3F %.3F %.3F %.3F re S", $x1, $y1, $width, $height));
    }
166135
protected function createCanvas($width, $height)
    {
        // Create the canvas element
        $canvas = imagecreatetruecolor( $width, $height );

        // Check if we should preserve the transparency
        if ( $this->imageType == IMAGETYPE_GIF || $this->imageType == IMAGETYPE_PNG ) {
            imagealphablending( $canvas, false );
            imagesavealpha( $canvas, true );
        }

        // Return the canvas
        return $canvas;
    }
50676
public function draw() {
        $size = $this->barcode->getDimension(0, 0);
        $this->w = max(1, $size[0]);
        $this->h = max(1, $size[1]);
        $this->init();
        $this->barcode->draw($this->im);
    }