How to display axis edge labels fully in WinForms Chart?
By default, chart axis labels at the edges may display only partially. To ensure the labels are fully visible, you can customize the display settings using EdgeLabelsDrawingMode options in WinForms Charts. This setting is specified as an enum type and includes the following options:
- Shift- Shifts and places the labels inside the chart area.
- Center- Places the labels at the center of the ticks.
- ClippingProtection- Avoids the overlapping of labels at the edge of the axis.
The following code snippet illustrates this.
// to show the partial x axis labels
chart.ChartArea.PrimaryXAxis.HidePartialLabels = false;
// to shift the x axis edge labels
chart.PrimaryXAxis.EdgeLabelsDrawingMode = ChartAxisEdgeLabelsDrawingMode.Shift;'to show the partial x axis labels
Me.ChartArea.PrimaryXAxis.HidePartialLabels = false;
'to shift the x axis edge labels
Me.PrimaryXAxis.EdgeLabelsDrawingMode = ChartAxisEdgeLabelsDrawingMode.Shift;Output:
When disable the HidePartialLabel property.
When set EdgeLabelsDrawingMode to Shift.
Conclusion
I hope you enjoyed learning about how to display axis edge labels fully in WinForms Chart.
You can refer to our WinForms Chart feature tour page to know about its other groundbreaking feature representations and documentation, and how to quickly get started with configuration specifications. You can also explore our WinForms Chart examples to understand how to create and manipulate data.
For current customers, you can check out our components from the License and Downloads page. If you are new to Syncfusion®, you can try our 30-day free trial to check out our other controls.
If you have any queries or require clarifications, please let us know in the comments section below. You can also contact us through our support forums, Direct-Trac, or feedback portal. We are always happy to assist you!