|
@@ -1708,7 +1708,7 @@ public class BarLineChartViewBase: ChartViewBase, BarLineScatterCandleBubbleChar
|
|
{
|
|
{
|
|
var pt = CGPoint(x: viewPortHandler.contentLeft, y: viewPortHandler.contentBottom)
|
|
var pt = CGPoint(x: viewPortHandler.contentLeft, y: viewPortHandler.contentBottom)
|
|
getTransformer(.Left).pixelToValue(&pt)
|
|
getTransformer(.Left).pixelToValue(&pt)
|
|
- return (pt.x <= 0.0) ? 0 : Int(pt.x + 1.0)
|
|
|
|
|
|
+ return (pt.x <= 0.0) ? 0 : Int(round(pt.x + 1.0))
|
|
}
|
|
}
|
|
|
|
|
|
/// - returns: the highest x-index (value on the x-axis) that is still visible on the chart.
|
|
/// - returns: the highest x-index (value on the x-axis) that is still visible on the chart.
|
|
@@ -1716,7 +1716,7 @@ public class BarLineChartViewBase: ChartViewBase, BarLineScatterCandleBubbleChar
|
|
{
|
|
{
|
|
var pt = CGPoint(x: viewPortHandler.contentRight, y: viewPortHandler.contentBottom)
|
|
var pt = CGPoint(x: viewPortHandler.contentRight, y: viewPortHandler.contentBottom)
|
|
getTransformer(.Left).pixelToValue(&pt)
|
|
getTransformer(.Left).pixelToValue(&pt)
|
|
- return (_data != nil && Int(pt.x) >= _data.xValCount) ? _data.xValCount - 1 : Int(pt.x)
|
|
|
|
|
|
+ return (_data != nil && Int(round(pt.x)) >= _data.xValCount) ? _data.xValCount - 1 : Int(round(pt.x))
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|