You found a bug! We've classified it as
We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
I have found a "bug" in your Info class : Your method "display" is expecting two Strings, but it's not written anywhere (nothing in the Javadoc) that these strings are supposed to be HTML constants.
If I do this :
The application crashes, because in the method "render" of "DefaultInfoConfigDefaultAppearance", you assume, for some reason, that these Strings are HTML constants, which is not enforced anywhere.
Instead, I really think that you should change the header of your "display" method to : "public static void display(SafeHtml title, SafeHtml text)".
Have a good day
Thanks for the report. I agree that we should be more explicit in what this method does, through documentation, better method names, or different types in those methods.
Renaming display(String, String) to follow other methods like ContentPanel.setHeadingHtml/setHeadingText would be a breaking change, so cannot be done before 3.1. Likewise, changing its behavior to now escape strings where it used to allow them normally, so instead we'll better document them in the short term, and add a SafeHtml variant to make it easier to use safely. And just as we support ContentPanel.setHeadingHtml(String), we will probably continue to support strings, as Info.displayHtml(String, String) or the like.