I have two gauges side by side. (See pictures).
Two questions:
1. The first and last labels on both gauges get chopped off. How do I prevent that from happening?
2. How do set number format of the gauge labels (ex. 2.5 3.5 etc) ?
Hello Aleksandr,
Thank you for contacting Infragistics.
To resolve the issue described in your first question, set CenterX to be 0.9 instead of 1.0 or 0.1 instead of 0.
To change the format of the scale labels, you need to implement the IGGaugeViewDelegate protocol as described in the documentation I've linked below.
http://help.infragistics.com/iOS/2014.2/chartapi/Protocols/IGGaugeViewDelegate.html#//api/name/gaugeView:formatStringForValue:
Please let me know if I may be of further assistance.
This does not really help since it pushes everything to the right including the scale.
All I need is to have the labels for the first and last values to display properly or not at all. The workaround I have is to set these to blank but that does not seem like the right way to do this since there is no easy way to know if the value displayed is exactly the maximum or minimum value of the scale.
I tried this in the delegate:
public override string ResolveFormatString (IGGaugeView gaugeView, double labelValue) { if (labelValue.Equals (gaugeView.MinimumValue)) { return ""; } if (labelValue.Equals (gaugeView.MaximumValue)) { return ""; } return labelValue.ToString ("0.0"); }
but it's 100% effective
Ok. I figured it out but not using CenterX property which clearly would not help. All that is necessary is to adjust ScaleOversweep property and start and end angles of the scale