<dependency>
    <groupId>com.aspose</groupId>
    <artifactId>aspose-slides</artifactId>
    <version>20.10</version>
    <classifier>jdk16</classifier>
</dependency>
copied!  
                                                
                                                  compile(group: 'com.aspose', name: 'aspose-slides', version: '20.10', classifier: 'jdk16')
                                                
                                              
copied!  
<dependency org="com.aspose" name="aspose-slides" rev="20.10">
    <artifact name="aspose-slides" m:classifier="jdk16" ext="jar"/>
</dependency>
copied!  
libraryDependencies += "com.aspose" % "aspose-slides" % "20.10"
copied!  

Java PowerPoint API

banner

产品页面 | 文档 | 演示 | API参考 | 例子 | 博客 | 搜索 | 免费支持 | 临时许可

Aspose.Slides用于演示操作和管理的Java PowerPoint API。它允许开发人员在Java应用程序中读取,编写,转换和操纵PowerPoint演示文稿,并能够操纵所有文档元素,例如幻灯片,表,文本,图表,形状,图像和SmartArt图等。

PowerPoint文件通过Java操作

检查产品概述以了解所有有关aspose的信息。

  • 加载并将演示文稿转换为其他格式。
  • 从头开始​​创建演示文稿。
  • 通过直观对象模型来操纵所有演示元素。
  • 创建或嵌入图表。
  • 创建或操纵形状。

读写演示文稿

** Microsoft PowerPoint:** PPT,PPTX,PPS,POT,PPSX,PPTM,PPSM,PPSM,POTX,POTM
** OpenOffice:** ODP,OTP

将演示文稿保存为

固定布局: pdf,pdf/a,xps 图像: JPEG,PNG,BMP,TIFF,GIF,SVG 网络: html,SWF

支持环境

  • ** Microsoft Windows:** Windows Desktop&Server(X86,X64)
  • ** macOS:** Mac OS X
  • ** Linux:** Ubuntu,Opensuse,Centos等
  • ** java版本:**```J2SE 6.0(1.6)`或更高版本

开始

aspose.spose java API托管在Aspose存储库。您可以在Maven项目中直接使用Aspose.spose.spose。有关详细说明,请访问Installing Aspose.Slides for Java from Maven Repository文档页面。

将演示文稿转换为PDF

// instantiate a Presentation object that represents a presentation file
Presentation pres = new Presentation("demo.pptx");
try {
    // save the presentation to PDF with default options
    pres.save("output.pdf", SaveFormat.Pdf);
} finally {
    if (pres != null) pres.dispose();
}

Create Presentation from Scratch

// instantiate Presentation
Presentation pres = new Presentation();
try {
    // get the first slide
    ISlide sld = (ISlide) pres.getSlides().get_Item(0);
    
    // add an AutoShape of Rectangle type
    IAutoShape ashp = sld.getShapes().addAutoShape(ShapeType.Rectangle, 150, 75, 150, 50);
    
    // add ITextFrame to the Rectangle
    ashp.addTextFrame("Hello World");
    
    // change the text color to Black (which is White by default)
    ashp.getTextFrame().getParagraphs().get_Item(0).getPortions().get_Item(0).getPortionFormat().getFillFormat()
            .setFillType(FillType.Solid);
    ashp.getTextFrame().getParagraphs().get_Item(0).getPortions().get_Item(0).getPortionFormat().getFillFormat()
            .getSolidFillColor().setColor(java.awt.Color.BLACK);
    
    // change the line color of the rectangle to White
    ashp.getShapeStyle().getLineColor().setColor(java.awt.Color.WHITE);
    
    // remove any fill formatting in the shape
    ashp.getFillFormat().setFillType(FillType.NoFill);
    
    // save the presentation to disk
    pres.save("output.pptx", SaveFormat.Pptx);
} finally {
    if (pres != null) pres.dispose();
}

产品页面 | 文档 | 演示 | API参考 | 例子 | 博客 | 搜索 | 免费支持 | 临时许可

VersionRelease Date
22.112022年11月23日
22.102022年10月19日
22.92022年9月22日
22.82022年8月18日
22.72022年7月19日
22.62022年6月27日
22.52022年5月19日
22.42022年4月18日
22.32022年3月24日
22.22022年2月16日
22.12022年1月12日
21.122021年12月17日
21.112021年11月25日
21.102021年10月14日
21.92021年9月21日
21.82021年8月17日
21.72021年7月16日
21.62021年6月18日
21.52021年5月19日
21.42021年4月19日
21.32021年3月23日
21.22021年2月19日
21.12021年1月25日
20.122020年12月22日
20.112020年11月23日
20.102020年10月16日
20.92020年9月24日
20.82020年8月25日
20.72020年7月22日
20.62020年6月24日
20.52020年5月25日
20.42020年4月28日
20.32020年3月24日
20.22020年2月20日
20.12020年1月21日
19.122019年12月18日
19.112019年11月26日
19.102019年10月28日
19.92019年9月17日
19.82019年8月29日
19.72019年7月26日
19.62019年6月25日
19.52019年5月30日
19.42019年4月26日
19.32019年4月4日
19.22019年2月28日
19.12019年1月30日
18.122018年12月27日
18.112018年12月1日
18.102018年10月31日
18.92018年9月30日
18.82018年8月29日
18.72018年7月27日
18.62018年7月1日
18.52018年5月30日
18.42018年5月7日
18.32018年4月3日
18.2.12018年3月9日
18.22018年2月28日
18.12018年1月31日
17.12.12017年12月26日
17.122017年12月16日
17.112017年11月30日
17.102017年11月1日
17.10.02017年11月1日
17.9.12017年10月12日
17.92017年10月2日
17.82017年8月31日
17.72017年7月31日
17.62017年7月1日
17.52017年5月31日
17.42017年4月28日
17.32017年4月3日
17.22017年3月1日
17.12017年1月31日
16.12.02016年12月27日
16.11.02016年11月30日
16.10.02016年11月4日
16.9.02016年10月12日
16.8.02016年9月27日
16.7.02016年8月23日
16.6.02016年7月22日
16.5.02016年6月16日
16.4.02016年5月17日
16.3.02016年4月21日
16.2.02016年3月18日
16.1.02016年2月4日
15.11.02016年1月11日