[ PHPXref.com ] [ Generated: Sun Jul 20 18:08:07 2008 ] [ html2ps 1.9.4 ]
[ Index ]     [ Variables ]     [ Functions ]     [ Classes ]     [ Constants ]     [ Statistics ]

title

Body

[close]

/ -> css.pseudo.cellspacing.inc.php (source)

   1  <?php
   2  // $Header: /cvsroot/html2ps/css.pseudo.cellspacing.inc.php,v 1.4 2005/09/25 16:21:44 Konstantin Exp $

   3  
   4  class CSSCellSpacing extends CSSProperty {
   5    function CSSCellSpacing() { $this->CSSProperty(false, false); }
   6  
   7    // this pseudo value should be inherited only by the table cells/rows; nested tables 

   8    // should get a default value

   9    //

  10    function inherit() { 
  11      // Determine parent 'display' value

  12      $handler =& get_css_handler('display');
  13  
  14      // 'display' CSS property processed AFTER this; so parent display value will be

  15      // on the top of the stack

  16      //

  17      $parent_display = $handler->get();
  18  
  19      // Inherit vertical-align from table-rows 

  20      if ($parent_display === "table-row" || $parent_display === "table") {
  21        $this->push($this->get());
  22        return;
  23      }
  24  
  25      $this->push(is_inline_element($parent_display) ? $this->get() : $this->default_value());
  26    }
  27  
  28    function default_value() { return "1px"; }
  29    function parse($value) { return $value; }
  30  }
  31  
  32  register_css_property('-cellspacing', new CSSCellSpacing);
  33  
  34  ?>


[ Powered by PHPXref - Served by Debian GNU/Linux ]