I have a legend whereby the legend items are stacked vertically. I want to lay them out horizontally. When I use Snoop, I can identify a StackPanel and change the orientation to horizontal to achieve the look I want.
But I cannot find that StackPanel in code anywhere.
How can I change this StackPanel layout in code?
Hello Carol,
Thank you for contacting Infragistics.
I have been looking into your case. What I could suggest you here is setting the Orientation property of the Legend to “Horizontal” to achieve the look you want instead of using StackPanel control.
<ig:XamDataChart Legend="{Binding ElementName=Legend}">
…
<ig:Legend Orientation="Horizontal" x:Name="Legend"/>
Please do not hesitate to contact me if you have any other questions or concerns.
Hello,
I am checking if my last reply was helpful for you.
If you require any further assistance please do not hesitate to ask.
I am just checking if you require any further assistance on the matter.
What I can suggest you here is:
I attached a sample project that represents my suggestions.
Please let me know if it helps you resolve your issue.
Hi,
Yes, that answer was what I was looking for. I have two questions related to the horizontal layout:
1. How can I add spacing between the legend items. In horizontal layout, they run together as one long row.
2. I want to set a maximum width for the legend box. Is there a way to wrap the legend items to go down to the next line? Currently a horizontal scrollbar appears.
Thank you for your time.