Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

# Dead and broken bar chart removed.

  • Loading branch information...
commit acfc0ff20e2d7af22ef68b5146040ad55ef96464 1 parent bda030d
Manuel Pichler authored June 01, 2010
142  src/Graph/BarChart.php
... ...
@@ -1,142 +0,0 @@
1  
-<?php
2  
-/**
3  
- * This file is part of phpUnderControl.
4  
- *
5  
- * PHP Version 5.2.0
6  
- *
7  
- * Copyright (c) 2007-2010, Manuel Pichler <mapi@phpundercontrol.org>.
8  
- * All rights reserved.
9  
- *
10  
- * Redistribution and use in source and binary forms, with or without
11  
- * modification, are permitted provided that the following conditions
12  
- * are met:
13  
- *
14  
- *   * Redistributions of source code must retain the above copyright
15  
- *     notice, this list of conditions and the following disclaimer.
16  
- *
17  
- *   * Redistributions in binary form must reproduce the above copyright
18  
- *     notice, this list of conditions and the following disclaimer in
19  
- *     the documentation and/or other materials provided with the
20  
- *     distribution.
21  
- *
22  
- *   * Neither the name of Manuel Pichler nor the names of his
23  
- *     contributors may be used to endorse or promote products derived
24  
- *     from this software without specific prior written permission.
25  
- *
26  
- * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
27  
- * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
28  
- * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
29  
- * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
30  
- * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
31  
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
32  
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
33  
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
34  
- * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
35  
- * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
36  
- * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
37  
- * POSSIBILITY OF SUCH DAMAGE.
38  
- *
39  
- * @category  QualityAssurance
40  
- * @package   Graph
41  
- * @author    Manuel Pichler <mapi@phpundercontrol.org>
42  
- * @copyright 2007-2010 Manuel Pichler. All rights reserved.
43  
- * @license   http://www.opensource.org/licenses/bsd-license.php  BSD License
44  
- * @version   SVN: $Id$
45  
- * @link      http://www.phpundercontrol.org/
46  
- */
47  
-
48  
-/**
49  
- * phpUnderControl extension for bar charts.
50  
- *
51  
- * @category  QualityAssurance
52  
- * @package   Graph
53  
- * @author    Manuel Pichler <mapi@phpundercontrol.org>
54  
- * @copyright 2007-2010 Manuel Pichler. All rights reserved.
55  
- * @license   http://www.opensource.org/licenses/bsd-license.php  BSD License
56  
- * @version   Release: @package_version@
57  
- * @link      http://www.phpundercontrol.org/
58  
- *
59  
- * @property phpucAbstractInput $input The input data source.
60  
- */
61  
-class phpucBarChart extends ezcGraphBarChart implements phpucThumbChartI
62  
-{
63  
-    /**
64  
-     * Constructs a new line chart object.
65  
-     */
66  
-    public function __construct()
67  
-    {
68  
-        parent::__construct();
69  
-
70  
-        $this->init();
71  
-    }
72  
-
73  
-    /**
74  
-     * Sets the input instance for the next rendering process.
75  
-     *
76  
-     * @param phpucAbstractInput $input The input object.
77  
-     *
78  
-     * @return void
79  
-     */
80  
-    public function setInput( phpucAbstractInput $input )
81  
-    {
82  
-        $this->yAxis->label = $input->yAxisLabel;
83  
-        $this->xAxis->label = $input->xAxisLabel;
84  
-
85  
-        $this->data = new ezcGraphChartDataContainer( $this );
86  
-
87  
-        $inputData = $input->data;
88  
-        foreach ( $inputData as $label => $data )
89  
-        {
90  
-            $this->data[$label] = new ezcGraphArrayDataSet( $data );
91  
-        }
92  
-
93  
-        $this->xAxis->labelCount = count( reset( $inputData ) );
94  
-    }
95  
-
96  
-    /**
97  
-     * Initializes the chart properties.
98  
-     *
99  
-     * @return void
100  
-     */
101  
-    protected function init()
102  
-    {
103  
-        $this->palette  = new phpucGraphPalette();
104  
-        $this->renderer = new ezcGraphRenderer3d();
105  
-
106  
-        $this->renderer->options->legendSymbolGleam = .5;
107  
-        $this->renderer->options->barChartGleam     = .5;
108  
-
109  
-        $this->renderer->options->fillAxis   = .95;
110  
-        $this->renderer->options->barMargin  = .2;
111  
-        $this->renderer->options->barPadding = .1;
112  
-
113  
-        $this->initAxis();
114  
-        $this->initLegend();
115  
-    }
116  
-
117  
-    /**
118  
-     * Init's some common legend properties.
119  
-     *
120  
-     * @return void
121  
-     */
122  
-    protected function initLegend()
123  
-    {
124  
-        $this->legend = false;
125  
-    }
126  
-
127  
-    /**
128  
-     * Init's the default chart axis.
129  
-     *
130  
-     * @return void
131  
-     */
132  
-    protected function initAxis()
133  
-    {
134  
-        $this->yAxis                    = new ezcGraphChartElementNumericAxis();
135  
-        $this->yAxis->font->minFontSize = 7;
136  
-        $this->yAxis->font->maxFontSize = 8;
137  
-
138  
-        $this->xAxis                    = new ezcGraphChartElementLabeledAxis();
139  
-        $this->xAxis->font->minFontSize = 7;
140  
-        $this->xAxis->font->maxFontSize = 8;
141  
-    }
142  
-}
4  src/Graph/ChartFactory.php
@@ -84,10 +84,6 @@ public function createChart( phpucAbstractInput $input )
84 84
             case phpucChartI::TYPE_TIME:
85 85
                 $chart = new phpucTimeChart();
86 86
                 break;
87  
-
88  
-            case phpucChartI::TYPE_BAR:
89  
-                $chart = new phpucBarChart();
90  
-                break;
91 87
         }
92 88
 
93 89
         $chart->setInput( $input );
7  src/Graph/ChartI.php
@@ -82,11 +82,6 @@
82 82
     const TYPE_TIME = 3;
83 83
 
84 84
     /**
85  
-     * Identifies an input implementation for bar charts.
86  
-     */
87  
-    const TYPE_BAR = 4;
88  
-
89  
-    /**
90 85
      * Sets the input instance for the next rendering process.
91 86
      *
92 87
      * @param phpucAbstractInput $input The input object.
@@ -94,4 +89,6 @@
94 89
      * @return void
95 90
      */
96 91
     function setInput( phpucAbstractInput $input );
  92
+
  93
+    function setNumberOfEntries( $numberOfEntries );
97 94
 }

0 notes on commit acfc0ff

Please sign in to comment.
Something went wrong with that request. Please try again.