Closed SuperDaveOsbourne closed 1 year ago
Yes this is maybe not clear enough in the docs, I will keep an eye on that.
The Axis class has the Visible
property, I think setting this property to false will be enough in your case, but it will also make separators invisible.
An alternative is to use the Axis.LabelFormatter
property to return an empty label.
I will close this issue for know, thanks again for the report, feel free to re-open or reply if you require it.
That doesn't solve it for me but maybe I am dense. Can you show me in the above example how to affect only one of the combined charts x axis labels on the axis while not affecting both? This is a shared axis. Everything I did try affects both but I cant toggle them independently. Should I reopen this?
I think this would be a valuable example as I have spent many hours going through the source code trying to figure out how to address dual axis properties when they are shared.
Oh, I got it, you are right.
So you only need to share the axis view (max and min limits) but not the style, this makes a lot of sense, and I think this is currently not supported.
I will keep this issue open to think on how to solve this.
Was this fixed in the new version?
This is already fixed, for more info see https://github.com/beto-rodriguez/LiveCharts2/issues/174
I have gone through the demos and don't find a clear way of stating if the charts X Y axis labels should be displayed. The examples do show that you can do it but I did spend considerable time looking and didn't find an answer. In this example I just want the Candlestick control to have Y Axis labels and the Volume bars to have both X and Y.
Winforms .Net 6 with LiveCharts 2.0.0-beta.90
Code
` //Begin example private void BtnDrawAllCharts(object sender, EventArgs e) { CandleStickChart.Series = FinData; CandleStickChart.ZoomMode = ZoomAndPanMode.X; CandleStickChart.XAxes = SharedXAxis; CandleStickChart.BackColor = Color.White; VolumeBarsChart.Series = VolumeBars; VolumeBarsChart.ZoomMode = ZoomAndPanMode.X; VolumeBarsChart.XAxes = SharedXAxis; VolumeBarsChart.BackColor = Color.White; CandleStickChart.Update(); VolumeBarsChart.Update(); } private Axis[] SharedXAxis { get; set; } = new[] { new Axis { LabelsRotation = 90, Labeler = value => new DateTime((long)value).ToString("M/d"), //set the unit width of the axis to "days" //since our X axis is of type date time and //the interval between our points is in days UnitWidth = TimeSpan.FromDays(1).Ticks, } }; private IEnumerableChart Image
![PutCall](https://user-images.githubusercontent.com/4176416/145251064-b29c75f9-f522-4bcb-836f-9df24babfe54.png)