FAQ
Where can I find any documentation?Javadocs API can be found on-line here -> http://extjs.com/deploy/gxtdocs/
A beginers guide to Ext GWT can be found here -> http://extjs.com/helpcenter/index.jsp
How to refresh a tree?Use TreeStore.add(M parent, M item, boolean addChildren), TreeLoader.loadChildren(parent) or TreeLoader.load()
Why cannot I only add Fields to a FormPanel?FormPanel has a FormLayout which only renders Fields. If you want to use other widgets, use AdapterField
How to handle selection events on a Tree?Use TreeBinder.addSelectionChangedListener(..)
How to build a simple Tree with strings?Just manually add the items, using TreeItem.add(TreeItem), starting with tree.getRootItem().
I have different behaviours in Internet Explorer and Firefox, is it a Ext GWT bug?First, check that you have the good doctype declaration in your HTML main file : <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Final//EN">
Second, make sure no other stylesheets are loaded that might conflict with Ext GWT - ie only have css/ext-all.css
How do I explicitly listen for mouse clicks on a widget? widget.el().addEventsSunk(Event.ONCLICK);
widget.addListener(Events.OnClick, new Listener<DomEvent>() {
public void handleEvent(DomEvent be) {
System.out.println("Clicked!");
}
});
In some cases, you can add a selection listener to a widget instead of listening for mouse clicks.
How can I stop an event from continuing (ie beforeXXXX event)?event.doit=false;
How do I stop a window from closing and ask "Are you sure"?Use the event.doit=false in a window listener and then add/remove that listener depending on the answer.
Can I use GWT widgets in GXT?Yes you can.
I've add widgets to a panel, but they don't show up - why?Call layout() on the panel.
How to create custom components?You can extend Component, BoxComponent for a sized component, Container for a "layouted" component when you don't want to expose the layout and LayoutContainer for a "layouted" component when you want to expose the layout.