> Does anyone know if it is possible in UIBinder to set an id for
> resulting DOM element?

I wanted to do this as well when I started working with UIBinder, but
the feedback I got was that the GWT team thinks that setting ids inside
of ui.xml files is an anti-pattern.

Their reasoning is that, technically, foo.ui.xml could be inserted into
the page several times, and so the DOM ids would no longer unique.

I see their point, but it is also a pain for exactly what you're doing,
working with labels. If you look at CheckBox, it manages both the
<input/> and the <label/> and keeps the label for in sync with the
input's id. You could potentially make your own text box that mimicks
that.

- Stephen


-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to