Hi,
I'm trying to create a Horizontal Bar Chart where both ends (right and left axis) are aligned to the left and right side of the screen, with some offset. I've used the following code to remove both axises and set the axis minimum to zero.
self.leftAxis.enabled = false
self.leftAxis.axisMinimum = 0
self.rightAxis.enabled = false
self.rightAxis.axisMinimum = 0
The leftAxis is aligned the way is expecting it. However, the rightAxis is still showing some blank space. I can check this size with:
self.rightAxis.getRequiredHeightSpace()
Is there a way to remove or set this required space? I've tried to set spaceTop without success.
Here is an image as an example:

xAxis is Green
leftAxis is Blue
rightAxis is Red
Do you agree ??
Agree. I've updated the question above. When i enable the xAxis it will show the following:
Maybe i wasn't clear before, but i want to remove the white space on the right side of the chart. I've added the current situation without the xAxis enabled in the Question above.
I know i can set a AxisMaximum to 100 and change the values of the bar so together they will always be 100. But is there a way to set the AxisMaximum to the total of the values, without displaying the white space?
ok i have understand

and now it's ok

Thanks, didn't know I had to set both the leftAxis and rightAxis Spaces
After a few tests
In fact there is only the left side that walks
The right side has no effect
//: ### LeftAxis
let leftAxis = chartView.leftAxis
leftAxis.labelFont = NSUIFont.systemFont(ofSize: CGFloat(12.0))
leftAxis.drawAxisLineEnabled = true
leftAxis.drawGridLinesEnabled = true
leftAxis.axisMinimum = 0.0
leftAxis.enabled = true
leftAxis.spaceTop = 0.0
leftAxis.spaceBottom = 0.0
//: ### RightAxis
let rightAxis = chartView.rightAxis
rightAxis.labelFont = NSUIFont.systemFont(ofSize: CGFloat(12.0))
rightAxis.drawAxisLineEnabled = true
rightAxis.drawGridLinesEnabled = false
rightAxis.axisMinimum = 0.0
rightAxis.enabled = true
rightAxis.spaceTop = 0.5
rightAxis.spaceBottom = 0.5
Most helpful comment
After a few tests
In fact there is only the left side that walks
The right side has no effect