开发者

output of ext gwt label rootpanel,get.add?

开发者 https://www.devze.com 2022-12-26 09:46 出处:网络
i have <div id=\"abc\"></div> I executed RootPanel.get(\"abc\").add(new Label(\"aaaaaaaaaaaaa\")); from GWT.

i have <div id="abc"></div> I executed RootPanel.get("abc").add(new Label("aaaaaaaaaaaaa")); from GWT.

then acutually GWT generates what kind of html tag?? is it like <font>aaaaaaaaaaaa开发者_StackOverflow</font>????

which i mean the output will be <div id="abc"><font aaaaaaaaaaaa></font></div> ??


GWT doesn't generate any <font> tags as far as I know; the tag is deprecated in the HTML spec. Labels are based on a div element, so the output from your example code will be <div id='abc'><div>aaaaaaaaaaaaa</div></div>

The standard replacement these days for the <font> tag is the <span> tag, which works the same way and does everything the font tag can do via css. To get one of these instead, try RootPanel.get("abc").add(new InlineLabel("aaaaaaaaaaa"));

0

精彩评论

暂无评论...
验证码 换一张
取 消