Tum*_*Tum 6 css gwt uibinder gwtp
我需要在GWT中的UiBinder中将许多单独的CSS类应用到1个元素中,但不知道如何操作.
在我的TestView.ui.xml中,我有
<g:Button text="Log Out" ui:field="logoutButton" addStyleNames="{style.gwt-Button}" addStyleNames="{style.paddedRight}" />
Run Code Online (Sandbox Code Playgroud)
但它产生了运行时错误.
然后我试了一下
<g:Button text="Log Out" ui:field="logoutButton" addStyleNames="{style.gwt-Button style.paddedRight}" />
Run Code Online (Sandbox Code Playgroud)
这次我得到编译时错误.
那么,如何在GWT中的UiBinder中将1个元素addStyleNames"Multiple css classes"?
在互联网上找不到信息.
zae*_*dam 14
我认为您必须addStyleNames在单独的括号对中指定属性中的每个样式名称.
像这样的东西:
<g:Button text="Log Out" ui:field="logoutButton" addStyleNames="{style.gwt-Button} {style.paddedRight}" />
Run Code Online (Sandbox Code Playgroud)