The new milestone! Support Harfbuzz Shaper plug! Java version of Aspose.Words v19.11 debut!

Aspose.Words are delighted to share the latest version v19.11 Java platform and we achieved another milestone, this version supports Harfbuzz Shaper plug-in on Unix-based operating system, and developers to expand the use of Web, custom level formatting rules shape. Next, we come together to talk about the new features of the new version.

Aspose.Words for Java is a feature-rich Word processing API, allows developers to embed without using Microsoft Word to generate their own Java applications, modify, convert, render and print documents function.

main feature

  • Unix-based operating system support Harfbuzz Shaper plug.
  • Web extensions and provides functions for use with the new class allows custom elements and attributes, Office add-ins to extend representation of XML vocabularies.
  • Added the ability to form custom-shaped foot level.
  • When "Use printer metrics" option, improved character spacing calculations.
  • Improved macro support.

If you have any questions or requests, please feel free to join Aspose technical exchange group (642 018 183) .


Web extension support elements

Aspose.Words API provides WebExtensions namespace, the namespace provides classes to customize elements and attributes of these elements and attributes extend the XML vocabulary to express Office add-ins. Now, you can use Aspose.Words for Java for use with Office add-ins and Web Extensions in the task pane. To this end, the new version provides a new class TaskPane, TaskPaneCollection class, TaskPaneDockState enumeration, Document.WebExtensionTaskPanes attributes.

The following code example shows how to create a task pane have basic properties and add it to expand Web task pane.

Document doc = new Document();

TaskPane taskPane = new TaskPane();
doc.getWebExtensionTaskPanes().add(taskPane);

taskPane.setDockState(TaskPaneDockState.RIGHT);
taskPane.isVisible(true);
taskPane.setWidth(300);

taskPane.getWebExtension().getReference().setId("wa102923726");
taskPane.getWebExtension().getReference().setVersion("1.0.0.0");
taskPane.getWebExtension().getReference().setStoreType(WebExtensionStoreType.OMEX);
taskPane.getWebExtension().getReference().setStore("th-TH");
taskPane.getWebExtension().getProperties().add(new WebExtensionProperty("mailchimpCampaign", "mailchimpCampaign"));
taskPane.getWebExtension().getBindings().add(new WebExtensionBinding("UnnamedBinding_0_1506535429545", WebExtensionBindingType.TEXT, "194740422"));
        
doc.save(dataDir + "output.docx", SaveFormat.DOCX);

Custom irregularly shaped horizontal format

Aspose.Words for Java API now provides Shape.HorizontalRuleFormat properties to access the level of regular shape properties. This class exposes HorizontalRuleFormat, basic properties such as height, color, etc. noshade following code example demonstrates how to set HorizontalRuleFormat horizontal format.

DocumentBuilder builder = new DocumentBuilder();

Shape shape = builder.insertHorizontalRule();
HorizontalRuleFormat horizontalRuleFormat = shape.getHorizontalRuleFormat();

horizontalRuleFormat.setAlignment(HorizontalRuleAlignment.CENTER);
horizontalRuleFormat.setWidthPercent(70);
horizontalRuleFormat.setHeight(3);
horizontalRuleFormat.setColor(Color.BLUE);
horizontalRuleFormat.setNoShade(true);

builder.getDocument().save("HorizontalRuleFormat.docx");

Guess you like

Origin www.cnblogs.com/mnrssj-Aspsoe/p/11888937.html