Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/gwt/3.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Gwt 如何删除Sencha GXT网格上的标题空间?_Gwt_Extjs_Gxt - Fatal编程技术网

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;
}
}