在哪里下载GWT-bootstrap.jar最新稳定版?
我从here下载了gwt-bootstrap 2.3.2.jar的副本。并创建一个示例项目,但每次出现以下错误。
Compiling module com.test.Bootstrap
Scanning for additional dependencies: file:/F:/desk/bootstrap/src/com/test/client/Testing.java
Computing all possible rebind results for 'com.test.client.Testing.TestingUiBinder'
Rebinding com.test.client.Testing.TestingUiBinder
Invoking generator com.google.gwt.uibinder.rebind.UiBinderGenerator
[ERROR] <b:Heading> missing required attribute(s): size Element <b:Heading> (:4)
[ERROR] Errors in 'file:/F:/desk/bootstrap/src/com/test/client/Testing.java'
[ERROR] Line 11: Failed to resolve 'com.test.client.Testing.TestingUiBinder' via deferred binding
Scanning for additional dependencies: jar:file:/F:/technology/lib/gwt-2.4.0/gwt-2.4.0/gwt-user.jar!/com/google/gwt/user/client/ui/Composite.java
[WARN] For the following type(s), generated source was never committed (did you forget to call commit()?)
[WARN] com.test.client.Testing_TestingUiBinderImpl
[ERROR] Cannot proceed due to previous errors
我的代码如下BootStrap.gwt.xml
<?xml version="1.0" encoding="UTF-8"?>
<module rename-to='bootstrap'>
<inherits name='com.google.gwt.user.User'/>
<inherits name='com.google.gwt.user.theme.standard.Standard'/>
<inherits name="com.github.gwtbootstrap.Bootstrap"/>
<entry-point class='com.test.client.Bootstrap'/>
<set-property name="bootstrap.responsiveDesign" value="true"/>
<source path='client'/>
<source path='shared'/>
</module>
Testing.ui.xml
<ui:UiBinder xmlns:ui='urn:ui:com.google.gwt.uibinder'
xmlns:g='urn:import:com.google.gwt.user.client.ui' xmlns:b="urn:import:com.github.gwtbootstrap.client.ui">
<g:HTMLPanel>
<b:Heading>Hello bootstrap</b:Heading>
<b:FluidContainer>
<b:FluidRow>
<b:Column size="4">...</b:Column>
<b:Column size="8">...</b:Column>
</b:FluidRow>
</b:FluidContainer>
</g:HTMLPanel>
</ui:UiBinder>
Testing.java
public class Testing extends Composite {
private static TestingUiBinder uiBinder = GWT.create(TestingUiBinder.class);
@UiTemplate("Testing.ui.xml")
interface TestingUiBinder extends UiBinder<Widget, Testing>{
}
public Testing() {
initWidget(uiBinder.createAndBindUi(this));
}
}
答案 0 :(得分:0)
看起来size属性是必需的。在Testing.ui.xml中试试这个
<b:Heading size="2">