Is there a good way in GWT to give the functionality of the HTML
<label> tag?  I do not mean the Label widget here.  I want to write
code that produces

<label for="name">Name:</label>
<input type="text" id="name"/>


from a Texbox widget and something else.  I have emulated this by
creating a ClickHandler, assigning it to each of the labels, and
storing the label-to-textbox relation in a HashMap, but that is a lot
of trouble to emulate a basic part of HTML. There should be an easier
way.  Doing that aso forces one to remove the connections so one does
not leak memory.

I know--it's hard to give an arbitrary id to a Widget; the
ensureDebugId method should only be used for debugging, but there
should be something.  The alternative method of using <label> doesn't
really work with GWT being so table-happy:

<label>Name:<input type="text"/></label>

as Grids would put the label and text box in different cells.

Respectfully,
Eric Jablow
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to google-web-toolkit@googlegroups.com
To unsubscribe from this group, send email to 
google-web-toolkit+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to