I am currently working with the HighCharts Javascript library and trying to embed some charts in a SmartGWT-based application.
HighCharts works by taking in a div element and rendering to that element; this makes it fairly simple to create a class that extends GWT's Widget, simply creating a class that extends widget and doing the following:
Also overriding onAttach() allows any post-creation methods to be called.
I was wondering if a similar approach could be used to make this class extend Canvas (or some other SmartGWT widget) as currently I am having serious problems with resizing when this Widget is included in my layout. Every time I've tried to create a custom Canvas widget in the past it generally didn't show up at all..
Thanks.
HighCharts works by taking in a div element and rendering to that element; this makes it fairly simple to create a class that extends GWT's Widget, simply creating a class that extends widget and doing the following:
Code:
element = DOM.createDiv(); element.setId(id); setElement(element);
I was wondering if a similar approach could be used to make this class extend Canvas (or some other SmartGWT widget) as currently I am having serious problems with resizing when this Widget is included in my layout. Every time I've tried to create a custom Canvas widget in the past it generally didn't show up at all..
Thanks.
Comment