mergeWith() public method

If a style field is not set in this style, it will be overwritten by the new one.
public mergeWith ( $style )
 /**
  * Merges the style with a new one.
  * If a style field is not set in this style, it will be overwritten by
  * the new one.
  * @param TStyle the new style
  */
 public function mergeWith($style)
 {
     parent::mergeWith($style);
     if ($style instanceof TWizardNavigationButtonStyle) {
         if ($style->_imageUrl !== null) {
             $this->_imageUrl = $style->_imageUrl;
         }
         if ($style->_buttonText !== null) {
             $this->_buttonText = $style->_buttonText;
         }
         if ($style->_buttonType !== null) {
             $this->_buttonType = $style->_buttonType;
         }
     }
 }
Exemplo n.º 2
0
 /**
  * Merges the style with a new one.
  * If a style field is not set in this style, it will be overwritten by
  * the new one.
  * @param TStyle the new style
  */
 public function mergeWith($style)
 {
     parent::mergeWith($style);
     if ($style instanceof TPanelStyle) {
         if ($this->_backImageUrl === null && $style->_backImageUrl !== null) {
             $this->_backImageUrl = $style->_backImageUrl;
         }
         if ($this->_direction === null && $style->_direction !== null) {
             $this->_direction = $style->_direction;
         }
         if ($this->_horizontalAlign === null && $style->_horizontalAlign !== null) {
             $this->_horizontalAlign = $style->_horizontalAlign;
         }
         if ($this->_scrollBars === null && $style->_scrollBars !== null) {
             $this->_scrollBars = $style->_scrollBars;
         }
         if ($this->_wrap === null && $style->_wrap !== null) {
             $this->_wrap = $style->_wrap;
         }
     }
 }
Exemplo n.º 3
0
 /**
  * Merges the style with a new one.
  * If a style field is not set in this style, it will be overwritten by
  * the new one.
  * @param TStyle the new style
  */
 public function mergeWith($style)
 {
     parent::mergeWith($style);
     if ($style instanceof TTableItemStyle) {
         if ($style->_verticalAlign !== null) {
             $this->_verticalAlign = $style->_verticalAlign;
         }
         if ($style->_horizontalAlign !== null) {
             $this->_horizontalAlign = $style->_horizontalAlign;
         }
         if ($style->_wrap !== null) {
             $this->_wrap = $style->_wrap;
         }
     }
 }
Exemplo n.º 4
0
 /**
  * Merges the style with a new one.
  * If a style field is not set in this style, it will be overwritten by
  * the new one.
  * @param TStyle the new 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;
         }
     }
 }