Andrew required swift code so I attach the code.
Please answer my question again.
https://www.scichart.com/questions/question/customize-chart-designwith-pic
https://www.scichart.com/questions/question/cannnot-remove-weird-square-areas
Andrew answered second question, but it didn’t work.
There is no drawAxisBands.
- Minsub Kim asked 5 years ago
- You must login to post comments
Hello, Minsub Kim.
Thank you for a providing examples.
1) As for this question:
The weird squares areas the parts of your renderable series area background, and the white squares are the axis bands (which, as I see aren’t needed by your design). So in order to have a white background without using Theme Manager I would suggest you to define also a brush style for surface.renderableSeriesFill (and if you need a border to divide rendering area from the axes you can define also a pen style for surface.renderableSeriesAreaBorder)
2) Now regarding another question: Lines after scrolling are caused by overlapping renderable series area border by axis bands (axis band has the same color as a background, so looks like some bug, which will investigate in fix in future). For now I would suggest you just to disable drawing of axes bands (as I understand they are not required by your design) to do this just set false value to drawMajorBands property of your axis style.
As an example, giving you an updated implementation of customColor method from your source code. Please, try this code on your side (without using theme manager), this should fix both of the issues.
private func customColor() {
for surface in [priceSurface, volumeSurface] {
surface.backgroundColor = .white
surface.renderableSeriesAreaFill.color = SCISolidBrushStyle(color: .white)
surface.renderableSeriesAreaBorder = SCISolidPenStyle(color: .lightGray, withThickness: 1)
for axis in [surface.xAxes.defaultAxis(), surface.yAxes.defaultAxis()] {
axis?.style.labelStyle.color = .black
axis?.style.majorGridLineBrush.color = #colorLiteral(red: 0.8823529412, green: 0.9254901961, blue: 0.9490196078, alpha: 1) //225 236 242
axis?.style.drawMajorTicks = false
axis?.style.drawMinorGridLines = false
axis?.style.drawMinorTicks = false
axis?.style.drawMajorBands = false
}
}
Regards,
Andriy.
- Andriy Shkinder answered 5 years ago
- last edited 5 years ago
- You must login to post comments
Please login first to submit.