2

I want to try and build a UI using this GWT designer tool I read about. I have GWT tools installed, created a "Google -> Web Application Project" but I don't see any means to build a UI except via code. I tried installing the plugin http://dl.google.com/eclipse/inst/d2gwt/latest/3.7 but it fails ( Not sure if I need this or not )

This is the tutorial I was looking at ..... How do I get this UI design view? https://developers.google.com/web-toolkit/tools/gwtdesigner/quick_start

Splaktar
  • 5,506
  • 5
  • 43
  • 74
MayoMan
  • 4,757
  • 10
  • 53
  • 85

2 Answers2

1

Another alternative to using the GWT Designer, if you don't want to use UiBinder, is

  1. In Eclipse, right-click view class in Package Explorer
  2. Open With
  3. GWT Designer
  4. Select the Designer tab at the bottom of the class window.

enter image description here

Display name
  • 1,109
  • 1
  • 15
  • 31
  • 1
    If you don't use UiBinder, then your class needs to extend `com.google.gwt.user.client.ui.Composite` before you can edit it with GWT Designer. (Which is unfortunate, because it's often preferable to implement `IsWidget` instead.) – Chris Lercher Dec 22 '12 at 09:59
  • 2
    That's not true. You are able to extend your class to any subclass of Widget and still use GWT Designer, though, I suppose it only makes sense to extend Panel, or any subclass of Panel. – Display name Dec 22 '12 at 14:20
  • 1
    What I had tried was opening GWT designer on a view class that extends `Widget` directly - and that fails with "Graphical editing is not provided for Widget". But I stand corrected, your class doesn't have to be a subclass of Composite, it can be any *sub-sub* class of Widget (quite strange actually). Many people, maybe including the OP, probably wonder, why the Designer doesn't open for their view classes which might only implement `IsWidget` without extending a subclass of `Widget`. – Chris Lercher Dec 23 '12 at 00:00
0

First from new file dialogue ( Ctrl + N ) create a UiBinder file (xxx.ui.xml):

enter image description here

Then select "Design" from left bottom of opened file in eclipse.

enter image description here

Saeed Zarinfam
  • 9,818
  • 7
  • 59
  • 72