summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog2
-rw-r--r--src/renderer/axis_label_exact.php15
2 files changed, 12 insertions, 5 deletions
diff --git a/ChangeLog b/ChangeLog
index 626370f..a88d551 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,8 @@
- Fixed issue #10741: Make ezcGraphOutOfLogithmicalBoundingsException more
descriptive
+- Fixed issue #10744: ExactAxisLabelRenderer shows last value at position of
+ second last value if showLastValue is disabled
1.1beta1 - [RELEASEDATE]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
diff --git a/src/renderer/axis_label_exact.php b/src/renderer/axis_label_exact.php
index 43ef219..27ec112 100644
--- a/src/renderer/axis_label_exact.php
+++ b/src/renderer/axis_label_exact.php
@@ -171,10 +171,12 @@ class ezcGraphAxisExactLabelRenderer extends ezcGraphAxisLabelRenderer
break;
}
+ $showLabel = true;
switch ( true )
{
case ( !$this->showLastValue && $step->isLast ):
// Skip last step if showLastValue is false
+ $showLabel = false;
break;
// Draw label at top left of step
case ( ( $axis->position === ezcGraph::BOTTOM ) &&
@@ -221,11 +223,14 @@ class ezcGraphAxisExactLabelRenderer extends ezcGraphAxisLabelRenderer
break;
}
- $renderer->drawText(
- $labelBoundings,
- $step->label,
- $alignement
- );
+ if ( $showLabel )
+ {
+ $renderer->drawText(
+ $labelBoundings,
+ $step->label,
+ $alignement
+ );
+ }
}
if ( !$step->isLast )
OpenPOWER on IntegriCloud