TeeChartPHP
[ class tree: TeeChartPHP ] [ index: TeeChartPHP ] [ all elements ]

Source for file MarksItems.php

Documentation is available at MarksItems.php

  1. <?php
  2.  
  3. /**
  4.  * MarksItems class
  5.  *
  6.  * Description:
  7.  *
  8.  * @author
  9.  * @copyright (c) 1995-2008 by Steema Software SL. All Rights Reserved. <info@steema.com>
  10.  * @version 1.0
  11.  * @package TeeChartPHP
  12.  * @subpackage styles
  13.  * @link http://www.steema.com
  14.  */
  15.  
  16. class MarksItems extends ArrayObject
  17. {
  18.  
  19.    public /*protected*/ $iMarks;
  20.  
  21.    // Will be used when saving the items for design time
  22.    public /*protected*/ $iLoadingCustom false;
  23.  
  24.     // Interceptors
  25.     function __get$property {
  26.       $method ="get{$property}";
  27.       if method_exists$this$method ) ) {
  28.         return $this->$method();
  29.       }
  30.     }
  31.  
  32.     function __set $property,$value {
  33.       $method ="set{$property}";
  34.       if method_exists$this$method ) ) {
  35.         return $this->$method($value);
  36.       }
  37.     }
  38.  
  39.    public function __construct($s)
  40.    {
  41.       parent::__construct();
  42.    }
  43.  
  44.    /**
  45.    * Returns the formatting object for the Index'th mark.
  46.    *
  47.    * @param index int
  48.    * @return MarksItem 
  49.    */
  50.    public function getItem($index)
  51.    {
  52.       while($index >= sizeof($this))
  53.       {
  54.          $this->add(null);
  55.       }
  56.  
  57.       if (!isset($this[$index]))
  58.       {
  59.          $tmp new MarksItem($this->iMarks->chart);
  60.  
  61.          //$tmp->getShadow()->setDefaultVisible(true);
  62.          //$tmp->getShadow()->setSize(1);
  63.          $tmpColor new Color(130130130);// GRAY
  64.          $tmp->getShadow()->setColor($tmpColor);
  65.          $this[$index]=$tmp;
  66.       }
  67.  
  68.       return $this[$index];
  69.       //parent::offsetget($index);
  70.    }
  71.  
  72.    public function clear()
  73.    {
  74.       unset($this);
  75. // tODO review      $this->iMarks->invalidate();
  76.    }
  77. }
  78. ?>

Documentation generated on Wed, 16 Jun 2010 12:06:59 +0200 by phpDocumentor 1.4.1