spire.office 5.9.6已正式发布。该版本新增了一些功能,例如:spire.presentaion支持对组合图形取消组合和groupshapes方法返回groupshape对象,并新增了getplaceholdershapes方法来通过占位符获取幻灯片母版版式中的形状的功能;spire.xls支持设置透视表域的重复项目标签选项;spire.barcode支持设置条码顶部文本的排列方式以及在条形码底部添加自定义文本。此外,本次更新也修复了一些在转换、操作powerpoint、excel和pdf文档以及扫描barcode时出现的问题。更多新功能及问题修复详情如下。
该版本涵盖了最新版的spire.doc、spire.pdf、spire.xls、spire.presentation、spire.dataexport、spire.barcode、spire.docviewer、spire.pdfviewer、spire.officeviewer、spire.email。
版本信息如下::
- spire.doc.dll v8.9.6
- spire.pdf.dll v6.9.16
- spire.xls.dll v10.9.16
- spire.email.dll v3.9.1
- spire.docviewer.forms.dll v5.1.1
- spire.pdfviewer.forms.dll v5.9.2
- spire.pdfviewer.asp.dll v5.9.2
- spire.presentation.dll v5.9.5
- spire.spreadsheet v4.5.0
- spire.officeviewer.forms.dll v5.9.6
- spire.barcode.dll v4.9.2
- spire.dataexport.dll v4.1.9
- spire.dataexport.resourcemgr.dll v2.1.0
- spire.common.dll v10.9.16
- spire.license.dll v1.3.8
https://www.e-iceblue.cn/downloads/spire-office-net.html
spire.presentation
新功能:
- 支持对组合图形取消组合。
groupshape groupshape = presentation.slides[0].shapes[0] as groupshape;
presentation.slides[0].ungroup(groupshape);
placeholder placeholder = presentation.slides[1].shapes[0].placeholder;
ishape[] shapes = presentation.slides[1].getplaceholdershapes(placeholder);
for (int i = 0; i < shapes.length; i )
{
if (shapes[i] is iautoshape)
{
iautoshape autoshape = shapes[i] as iautoshape;
if (autoshape.textframe != null)
{
console.writeline(autoshape.textframe.text);
}
}
}
arraylist groupshapelist = new arraylist();
groupshapelist.add(shape1);
groupshapelist.add(shape2);
groupshapelist.add(shape3);
groupshape groupshape = ppt.slides[0].groupshapes(groupshapelist);
问题修复:
- 修复了拷贝幻灯片到新文档时抛“documenteditexception”的问题。
- 修复了组合图形后导致图形消失的问题。
- 修复了转换pptx到html抛“nullreferenceexception”的问题。
- 修复了加载pptx文档抛“indexoutofrangeexception”的问题。
- 修复了转换pptx到pdf图表内容不正确的问题。
- 修复了加载受保护的ppt文档抛异常“encrypted presentations are not supported”的问题。
spire.xls
新功能:
- 支持设置透视表域的重复项目标签选项。
pt.pivotfields["onhand"].repeatitemlabels = true;
问题修复:
- 修复了转换xls 到 xlsx,多边形变矩形的问题。
- 修复了由spire创建的矩形的left属性值为0的问题。
- 修复了转换包含透视表的sheet到pdf,内容不正确的问题。
- 修复了在德语环境下添加的数字格式不正确的问题。
- 修复了设置矩形的left和top属性值后,矩形的高度和宽度改变的问题。
- 修复了转换到pdf,fixed公式值不正确的问题。
- 修复了获取分页处的行索引失败的问题。
- 修复了转换excel到pdf,内容不正确的问题。
- 修复了转换excel到pdf,边框不正确的问题。
- 修复了转换xls到ods, 边框丢失的问题。
spire.pdf
问题修复:
- 修复了添加多个按钮表单域后用adobe acrobat reader dc打开报修复表单错误的问题。
- 修复了打印时字符顶部被裁剪的问题。
- 修复了查找到的文本的y值不正确的问题。
- 修复了查找到的文本的width值不正确的问题。
- 修复了替换图片失败的问题。
- 修复了创建的pdfpolygonannotation无法打印的问题。
- 修复了提取特定矩形区域文本的结果不正确的问题。
- 修复了在wpf项目中转换pdf到docx文档失败的问题。
- 修复了pdf到word转换时图章丢失的问题。
- 修复了使用名字为2.16.76.1.4.2.2.1和值为101620创建自定义属性程序抛出“bad xml name”的问题。
- 修复了提取模板页面中的图片时程序抛出异常的问题。
- 修复了模板页面中复选框状态改变的问题。
- 修复了转换pdf到xps,粗体效果丢失的问题。
- 修复了转换pdf到html程序抛argumentoutofrangeexception异常的问题。
- 修复了修改域的名字失败的问题。
- 修复了转换pdf到图片程序抛出argumentoutofrangeexception异常的问题。
spire.barcode
新功能:
- 支持设置条码顶部文本的排列方式。
int width = 399;
int height = 159;
barcodesettings bs = new barcodesettings();
bs.type = barcodetype.upca;
bs.unit = graphicsunit.pixel;
bs.widenarrowratio = 0.5f;
bs.textfont = new font("arial", 20, fontstyle.regular);
string data = "602318275035";
bs.data2d = data;
bs.data = data;
bs.showtextonbottom = true;
bs.toptext = data;
bs.showtoptext = true;
bs.textalignment = stringalignment.center;
bs.toptextaligment = stringalignment.center;
bs.toptextfont = new font("arial", 20, fontstyle.regular);
bs.autoresize = false;
bs.x = 3.0f;
bs.barheight = height * 0.6f;
bs.imagewidth = width;
bs.imageheight = height;
barcodegenerator generator = new barcodegenerator(bs);
image barimage = generator.generateimage();
barimage.save(outputfile_img, imageformat.png);
barcodesettings barsetting = new barcodesettings();
barsetting.type=barcodetype.ean13;
barsetting.backcolor = color.whitesmoke;
string data = "6901234567892";
barsetting.data=data;
barsetting.data2d=data;barsetting.toptext="ean13";
barsetting.toptextfont=new font("arial", 20, fontstyle.regular);
barsetting.toptextcolor=color.red;
barsetting.showtoptext=true;
barsetting.showtextonbottom=true;
barsetting.toptextaligment=stringalignment.center;
barsetting.bottomtext="ean";
barsetting.bottomtextfont=new font("fangsong", 25, fontstyle.bold);
barsetting.bottomtextcolor=color.black;
barsetting.showbottomtext=true;
barsetting.bottomtextaligment=stringalignment.far;
barcodegenerator generator = new barcodegenerator(barsetting);
image barcode = generator.generateimage();
barcode.save(outputfile_img);
问题修复:
- 修复了扫描条形码得到的数据不正确的问题。
- 修复了扫描条形码失败的问题。
- 修复了扫描条形码程序抛“nullpointerexception”的问题。
- 修复了添加自定义文本不生效的问题。
- 修复了扫描含特殊字符的qr码,得到的数据错误的问题。