问题
I have a GridPanel, but, as you can see, the first column(which is locked) is not aligned like the other ones.
Is it a bug, or am I doing something wrong?
EDIT: Here are some snippets regarding the columns:
initComponent: function(){
this.renderTo = this.divId;
this.status = "normal";
Ext.Array.insert(this.columns,0,this.cols);
this.columns = this.cols;
this.callParent();
}
and the cols object looks like this:
for(var i in params){
if(i != config.staticColumn)
cols.push({header: headers[i], dataIndex: i});
else{
cols.push({header: headers[i], dataIndex: i, locked: true});
}
}
That space is actually:
<div id="gridview-1323-spacer" style="height: 17px"></div>
I don't know what this means or why it gets created in the first place.
回答1:
This was an issue with ExtJS(like a few others). I have asked for support on their forum, but no answer was provided fast enough to be useful(the last time I checked - maybe a year or so ago there was still no answer).
In the meantime I have stopped working with this framework and have not checked for another fix.
来源:https://stackoverflow.com/questions/11223169/extjs-4-1-gridpanel-missplaced-column