如题:
使用 float 数组初始化 table,导出的pdf列宽不生效
1
2
|
float [] columnWidths = { 20 , 30 , 50 }; Table table = new Table(columnWidths); |
使用 unitvalue初始化 table,导出的pdf列宽才生效
1
2
3
4
5
|
UnitValue[] unitValue = new UnitValue[]{ UnitValue.createPercentValue(( float ) 20 ), UnitValue.createPercentValue(( float ) 30 ), UnitValue.createPercentValue(( float ) 50 )}; Table table = new Table(unitValue ); |
为什么会出现这种情况,是iText7.0.2版本