Presentation presentation = new Presentation();
presentation.loadFromFile("F:\\圆角矩形.pptx");
ShapeCollection shapes = presentation.getSlides().get(0).getShapes();
for (Object shape : shapes) {
if (shape instanceof IAutoShape) {
IAutoShape autoShape = (IAutoShape) shape;
if (autoShape.getShapeType() == ShapeType.ROUND_CORNER_RECTANGLE) {
//设置圆角矩形角度
autoShape.setRoundRadius(45);
}
}
}
presentation.saveToFile("F:\\result.pptx", FileFormat.PPTX_2013);