charts icon indicating copy to clipboard operation
charts copied to clipboard

com.vaadin.addon.charts.model.Configuration Title & SubTitle

Open vaadin-bot opened this issue 9 years ago • 0 comments

Originally by @zch


Reported issue in Forum at https://vaadin.com/forum#!/thread/9690924/9690923


I'm having to report a bug in the forum becouse the ticket system is rejecting my issue with "Submission rejected as potential spam"

com.vaadin.addon.charts.model.Configuration Title & SubTitle

Both setTitle & setSubTitle cause the Title & SubTitle objects in Configuration to be recreated.

The approach causes Title & SubTitle objects to lose their Styles.

The implementation approach forces the developer to use Title & SubTitle text in a specific sequence by requiring the text be set first, and then the style operations after words.

Issues: a. The approach is confusing.

b. Styling and setting text should be independent rather then coupled.

c. Developers should be allowed to create a Chart that is styled, and then apply values/text.

Suggest fix: a. The setTitle/setSubTitle should be a delegate method to the actual Title text configuration.getTitle().setText(caption);

b. Or, remove the string methods that set Title & SubTitle text.

vaadin-bot avatar Apr 04 '15 19:04 vaadin-bot