Jason Posted May 4, 2009 Report Share Posted May 4, 2009 I am creating a Pie chart and one of the legend labels is wrapping. I do not want the legend labels to wrapped so I made the width of the chart wider but when I did that the height of the chart grew which is not what I asked it to do. How can I make the legend labels not wrap? Quote Link to comment Share on other sites More sharing options...
pmadrigal Posted May 13, 2009 Report Share Posted May 13, 2009 Hello Jason, There's no property to make the marker labels not to wrap but you have several options: For a Pie Chart I would recommend to set the legends in the Legend Box instead of marker labels to increase the chart's readability. If you want you can create a separate Legend Box with an specific Width and Height to prevent the text wrapping. You could also create short labels and use the keyleg property. Another option would be to change the font of the label to a smaller one using setPointLabelFont(java.awt.Font value) When setting a font in Chart FX, you must create a new font object with the desired attributes and assign that object to the desired chart element every time you want to change the font. I hope this helps, Priscilla Quote Link to comment Share on other sites More sharing options...
rolandbmi Posted January 28, 2011 Report Share Posted January 28, 2011 We are having real issues with the formatting on our legend boxes, especially preventing the legends from stacking. Can you explain how you woudl create a separate Legend Box with an specific Width and Height to prevent the text wrapping# We are usign the java edition Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.