Raymond Bosman | 1 Jun 2006 15:19
Picon
Favicon

2978 - in trunk/Template: . src src/parsers/tst_to_tst/implementations src/syntax_trees/tst/nodes tests/regression_tests tests/regression_tests/escape_variables tests/regression_tests/foreach/correct tests/regression_tests/if/correct tests/regression_tests/include/correct tests/regression_tests/typehints [eZComponents: Trunk]

Author: Raymond Bosman
Date: 2006-06-01 15:19:52 +0200 (Thu, 01 Jun 2006)
New Revision: 2978

Log:
- Fixed a bug that some indentations were not removed.
- Fixed a bug that the newlines after a non output block were not removed.
- Added whitespace test cases.

Added:
   trunk/Template/tests/regression_tests/typehints/functions.in
   trunk/Template/tests/regression_tests/typehints/functions.out
   trunk/Template/tests/regression_tests/whitespace.in
   trunk/Template/tests/regression_tests/whitespace.out
   trunk/Template/tests/regression_tests/whitespace2.in
   trunk/Template/tests/regression_tests/whitespace2.out
Modified:
   trunk/Template/ChangeLog
   trunk/Template/src/parser.php
   trunk/Template/src/parsers/tst_to_tst/implementations/whitespace_removal.php
   trunk/Template/src/syntax_trees/tst/nodes/if_condition.php
   trunk/Template/tests/regression_tests/escape_variables/recursion.out
   trunk/Template/tests/regression_tests/foreach/correct/delimiter.out
   trunk/Template/tests/regression_tests/foreach/correct/delimiter_in_delimiter.in
   trunk/Template/tests/regression_tests/foreach/correct/delimiter_in_delimiter.out
   trunk/Template/tests/regression_tests/foreach/correct/limit.in
   trunk/Template/tests/regression_tests/foreach/correct/limit.out
   trunk/Template/tests/regression_tests/if/correct/if.out
   trunk/Template/tests/regression_tests/if/correct/if_else.in
   trunk/Template/tests/regression_tests/if/correct/if_else.out
(Continue reading)

Kristian Hole | 1 Jun 2006 21:32
Picon
Favicon

2979 - docs/examples/applications/Photon/trunk/include/tests [eZComponents: Docs]

Author: Kristian Hole
Date: 2006-06-01 21:32:47 +0200 (Thu, 01 Jun 2006)
New Revision: 2979

Log:
- Fixed wrong methodname
- Changed error text

Modified:
   docs/examples/applications/Photon/trunk/include/tests/ModelsTest.php

Modified: docs/examples/applications/Photon/trunk/include/tests/ModelsTest.php
===================================================================
--- docs/examples/applications/Photon/trunk/include/tests/ModelsTest.php	2006-06-01 13:19:52
UTC (rev 2978)
+++ docs/examples/applications/Photon/trunk/include/tests/ModelsTest.php	2006-06-01 19:32:47
UTC (rev 2979)
 <at>  <at>  -13,7 +13,7  <at>  <at> 

 // Call imageTest::main() if this source file is executed directly.
 if (!defined("PHPUnit2_MAIN_METHOD")) {
-    define("PHPUnit2_MAIN_METHOD", "imageTest::main");
+    define("PHPUnit2_MAIN_METHOD", "ModelsTest::main");
 }

 require_once "PHPUnit2/Framework/TestCase.php";
 <at>  <at>  -226,7 +226,7  <at>  <at> 
         $this->assertEquals( 1, count($rows), "Wrong number of keywords assigned to image " );

         // Test assigning when assignment exists
(Continue reading)

Kore Nordmann | 2 Jun 2006 10:07
Picon
Favicon

2980 - in trunk/Graph: src/axis src/charts src/driver src/element tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 10:07:37 +0200 (Fri, 02 Jun 2006)
New Revision: 2980

Log:
- Added tests for axis labels
- Implemented axis labels

Modified:
   trunk/Graph/src/axis/labeled.php
   trunk/Graph/src/charts/line.php
   trunk/Graph/src/driver/gd.php
   trunk/Graph/src/element/axis.php
   trunk/Graph/tests/labeled_axis_test.php
   trunk/Graph/tests/legend_test.php
   trunk/Graph/tests/line_test.php
   trunk/Graph/tests/numeric_axis_test.php

Modified: trunk/Graph/src/axis/labeled.php
===================================================================
--- trunk/Graph/src/axis/labeled.php	2006-06-01 19:32:47 UTC (rev 2979)
+++ trunk/Graph/src/axis/labeled.php	2006-06-02 08:07:37 UTC (rev 2980)
 <at>  <at>  -149,7 +149,7  <at>  <at> 
      */
     protected function getMajorStepCount()
     {
-        return count( $this->labels );
+        return count( $this->labels ) - 1;
     }

(Continue reading)

Raymond Bosman | 2 Jun 2006 10:29
Picon
Favicon

2981 - in trunk/Template: . src/syntax_trees/ast/nodes/operators tests/regression_tests/typehints [eZComponents: Trunk]

Author: Raymond Bosman
Date: 2006-06-02 10:29:19 +0200 (Fri, 02 Jun 2006)
New Revision: 2981

Log:
- As Kristian (KH) pointed out, fetching an array element was never considered as a
  possible sub array. E.g. {var $a = array( array("a") )} {foreach $a[0] as $i}
  gave an error.

Added:
   trunk/Template/tests/regression_tests/typehints/sub_array.in
   trunk/Template/tests/regression_tests/typehints/sub_array.out
Modified:
   trunk/Template/ChangeLog
   trunk/Template/src/syntax_trees/ast/nodes/operators/array_fetch_operator.php

Modified: trunk/Template/ChangeLog
===================================================================
--- trunk/Template/ChangeLog	2006-06-02 08:07:37 UTC (rev 2980)
+++ trunk/Template/ChangeLog	2006-06-02 08:29:19 UTC (rev 2981)
 <at>  <at>  -1,6 +1,10  <at>  <at> 
 - Fixed a bug that some indentations were not removed.
 - Fixed a bug that the newlines after a non output block were not removed. 
+- Fixed a bug that fetching an array element was never considered as a
+  possible sub array. E.g. {var $a = array( array("a") )} {foreach $a[0] as $i}
+  gave an error.

+
 1.0rc1 - [RELEASEDATE]
 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
(Continue reading)

Kore Nordmann | 2 Jun 2006 10:43
Picon
Favicon

2982 - in trunk/Graph: src/charts tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 10:43:45 +0200 (Fri, 02 Jun 2006)
New Revision: 2982

Log:
- Added tests for line chart rendering

Modified:
   trunk/Graph/src/charts/line.php
   trunk/Graph/tests/line_test.php
   trunk/Graph/tests/numeric_axis_test.php

Modified: trunk/Graph/src/charts/line.php
===================================================================
--- trunk/Graph/src/charts/line.php	2006-06-02 08:29:19 UTC (rev 2981)
+++ trunk/Graph/src/charts/line.php	2006-06-02 08:43:45 UTC (rev 2982)
 <at>  <at>  -33,8 +33,8  <at>  <at> 
             foreach ( $data as $key => $value )
             {
                 $point = new ezcGraphCoordinate( 
-                    $this->elements['X_axis']->getCoordinate( $boundings, $key ),
-                    $this->elements['Y_axis']->getCoordinate( $boundings, $value )
+                    (int) round( $this->elements['X_axis']->getCoordinate( $boundings, $key ) ),
+                    (int) round( $this->elements['Y_axis']->getCoordinate( $boundings, $value ) )
                 );

                 // Draw line

Modified: trunk/Graph/tests/line_test.php
===================================================================
(Continue reading)

Kore Nordmann | 2 Jun 2006 11:34
Picon
Favicon

2983 - in trunk/Graph: src/axis tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 11:34:33 +0200 (Fri, 02 Jun 2006)
New Revision: 2983

Log:
- Fixed bug in determining null position for numeric axis

Modified:
   trunk/Graph/src/axis/numeric.php
   trunk/Graph/tests/line_test.php
   trunk/Graph/tests/numeric_axis_test.php

Modified: trunk/Graph/src/axis/numeric.php
===================================================================
--- trunk/Graph/src/axis/numeric.php	2006-06-02 08:43:45 UTC (rev 2982)
+++ trunk/Graph/src/axis/numeric.php	2006-06-02 09:34:33 UTC (rev 2983)
 <at>  <at>  -225,7 +225,10  <at>  <at> 
      */
     public function getCoordinate( ezcGraphBoundings $boundings, $value )
     {
-        if ( ( $value === false ) || ( $value === null ) )
+        // Force typecast, because ( false < -100 ) results in (bool) true
+        $floatValue = (float) $value;
+        if ( ( $value === false ) &&
+             ( ( $floatValue < $this->min ) || ( $floatValue > $this->max ) ) )
         {
             switch ( $this->position )
             {

Modified: trunk/Graph/tests/line_test.php
(Continue reading)

Kore Nordmann | 2 Jun 2006 12:04
Picon
Favicon

2984 - in trunk/Graph: src src/driver tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 12:04:10 +0200 (Fri, 02 Jun 2006)
New Revision: 2984

Log:
- Added tests for vertical alignement
- Added support for vertical alignement to GD driver

Modified:
   trunk/Graph/src/driver/gd.php
   trunk/Graph/src/graph.php
   trunk/Graph/tests/driver_gd_test.php

Modified: trunk/Graph/src/driver/gd.php
===================================================================
--- trunk/Graph/src/driver/gd.php	2006-06-02 09:34:33 UTC (rev 2983)
+++ trunk/Graph/src/driver/gd.php	2006-06-02 10:04:10 UTC (rev 2984)
 <at>  <at>  -219,6 +219,23  <at>  <at> 

         if ( is_array( $result ) )
         {
+            $completeHeight = count( $result ) * $size + ( count( $result ) - 1 ) * $this->options->lineSpacing;
+
+            // Calculate y offset for vertical alignement
+            switch ( true )
+            {
+                case ( $align & ezcGraph::BOTTOM ):
+                    $yOffset = $height - $completeHeight;
+                    break;
+                case ( $align & ezcGraph::MIDDLE ):
(Continue reading)

Kore Nordmann | 2 Jun 2006 12:08
Picon
Favicon

2985 - in trunk/Graph: src/element tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 12:08:51 +0200 (Fri, 02 Jun 2006)
New Revision: 2985

Log:
- Use vertical alignement middle for legends texts

Modified:
   trunk/Graph/src/element/legend.php
   trunk/Graph/tests/legend_test.php

Modified: trunk/Graph/src/element/legend.php
===================================================================
--- trunk/Graph/src/element/legend.php	2006-06-02 10:04:10 UTC (rev 2984)
+++ trunk/Graph/src/element/legend.php	2006-06-02 10:08:51 UTC (rev 2985)
 <at>  <at>  -209,7 +209,8  <at>  <at> 
                         ),
                         $label['label'],
                         $this->boundings->x1 - $this->boundings->x0 - $symbolSize - $this->padding,
-                        $symbolSize - 2 * $this->padding
+                        $symbolSize - 2 * $this->padding,
+                        ezcGraph::LEFT | ezcGraph::MIDDLE
                     );
                 }
                 break;
 <at>  <at>  -240,7 +241,8  <at>  <at> 
                         ),
                         $label['label'],
                         $width - $this->padding - $symbolSize,
-                        $symbolSize - 2 * $this->padding
(Continue reading)

Kore Nordmann | 2 Jun 2006 14:25
Picon
Favicon

2986 - in trunk/Graph: src src/charts src/driver src/exceptions src/interfaces src/options tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 14:25:08 +0200 (Fri, 02 Jun 2006)
New Revision: 2986

Log:
- Moved font configuration to elements

Added:
   trunk/Graph/src/exceptions/invalid_font.php
Modified:
   trunk/Graph/src/charts/line.php
   trunk/Graph/src/driver/gd.php
   trunk/Graph/src/graph_autoload.php
   trunk/Graph/src/interfaces/chart.php
   trunk/Graph/src/interfaces/element.php
   trunk/Graph/src/options/chart.php
   trunk/Graph/src/options/driver.php
   trunk/Graph/tests/driver_gd_test.php
   trunk/Graph/tests/line_test.php

Modified: trunk/Graph/src/charts/line.php
===================================================================
--- trunk/Graph/src/charts/line.php	2006-06-02 10:08:51 UTC (rev 2985)
+++ trunk/Graph/src/charts/line.php	2006-06-02 12:25:08 UTC (rev 2986)
 <at>  <at>  -88,7 +88,9  <at>  <at> 

         // Calculate axis scaling and labeling
         $this->elements['X_axis']->calculateFromDataset( $this->data );
+        $this->elements['X_axis']->font = $this->options->font;
         $this->elements['Y_axis']->calculateFromDataset( $this->data );
(Continue reading)

Kore Nordmann | 2 Jun 2006 14:59
Picon
Favicon

2987 - in trunk/Graph: src/interfaces tests [eZComponents: Trunk]

Author: Kore Nordmann
Date: 2006-06-02 14:59:15 +0200 (Fri, 02 Jun 2006)
New Revision: 2987

Log:
- Added tests for element based font configuration

Added:
   trunk/Graph/tests/font_test.php
Modified:
   trunk/Graph/src/interfaces/element.php
   trunk/Graph/tests/suite.php

Modified: trunk/Graph/src/interfaces/element.php
===================================================================
--- trunk/Graph/src/interfaces/element.php	2006-06-02 12:25:08 UTC (rev 2986)
+++ trunk/Graph/src/interfaces/element.php	2006-06-02 12:59:15 UTC (rev 2987)
 <at>  <at>  -87,6 +87,14  <at>  <at> 
      */
     protected $font;

+    /**
+     * Indicates if font configuration was already cloned for this specific
+     * element.
+     * 
+     *  <at> var boolean
+     */
+    protected $fontCloned = false;
+
     public function __construct( array $options = array() )
(Continue reading)


Gmane