ListView 在代码里设置margin
ListView在代码里设置layout_marginTop、layout_marginLeft、layout_marginRight、layout_marginBottom
ListView lst=getListView();
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.FILL_PARENT);
params.setMargins(0, 0, 0, 0);
//left,top,right,bottom
lst.setLayoutParams(params);