Gwt 如何删除Sencha GXT网格上的标题空间?

Gwt 如何删除Sencha GXT网格上的标题空间?,gwt,extjs,gxt,Gwt,Extjs,Gxt,网格应该有一个垂直滚动条,但它是隐藏的。 但是,表标题上还有一个空格 如何删除空白空格头?< /P> 解决方案是覆盖GridView,将空间设置为0 public class CustomGxtGridView<M> extends GridView<M> { private static int SCROLL_OFFSET = 1; public CustomGxtGridView(...) { super(viewMediator)

网格应该有一个垂直滚动条,但它是隐藏的。 但是,表标题上还有一个空格

如何删除空白空格头?< /P>


解决方案是覆盖GridView,将空间设置为0

public class CustomGxtGridView<M> extends GridView<M> {

    private static int SCROLL_OFFSET = 1;

    public CustomGxtGridView(...) {
        super(viewMediator);
        this.scrollOffset = SCROLL_OFFSET;
        this.vbar = false;
        this.setAdjustForHScroll(false);
    }

    @Override
    protected int getScrollAdjust() {
        return 0;
    }

}
public类CustomGxtGridView扩展了GridView{
专用静态整数滚动_偏移=1;
公共CustomGxtGridView(…){
超级(viewMediator);
this.scrollOffset=滚动偏移量;
this.vbar=false;
此.setAdjustForHScroll(false);
}
@凌驾
受保护的int getScrollAdjust(){
返回0;
}
}