Prado\Web\UI\WebControls\TTableStyle::mergeWith PHP Method

mergeWith() public method

If a style field is not set in this style, it will be overwritten by the new one.
public mergeWith ( $style )
    public function mergeWith($style)
    {
        parent::mergeWith($style);
        if ($style instanceof TTableStyle) {
            if ($this->_backImageUrl === null && $style->_backImageUrl !== null) {
                $this->_backImageUrl = $style->_backImageUrl;
            }
            if ($this->_horizontalAlign === null && $style->_horizontalAlign !== null) {
                $this->_horizontalAlign = $style->_horizontalAlign;
            }
            if ($this->_cellPadding === null && $style->_cellPadding !== null) {
                $this->_cellPadding = $style->_cellPadding;
            }
            if ($this->_cellSpacing === null && $style->_cellSpacing !== null) {
                $this->_cellSpacing = $style->_cellSpacing;
            }
            if ($this->_gridLines === null && $style->_gridLines !== null) {
                $this->_gridLines = $style->_gridLines;
            }
            if ($this->_borderCollapse === null && $style->_borderCollapse !== null) {
                $this->_borderCollapse = $style->_borderCollapse;
            }
        }
    }