Import Styles (W)

Modified on Mon, 5 Oct at 1:54 PM

With BaseExtensions, we can import new style sets from another document. The feature includes a filter which targets the name of the styles to import.

CMD

<cmd case="BaseExtensions:apply-styles" path="x" filter="x"/>

Parameters

Path

Define the path where the document that contains the styles is located. If the file is located in BaseExtensions in the Content folder, just type in the file name, e.g.: test.docx

Filter

Define the styles that should be imported using a style name. This is a string value, e.g. Heading will only import the heading styles.

Example of usage

Using the cmd below, all styles with the name TOC (....) will be imported from the SourceStyles.docx file into the active document. This feature is handy if the client has several style sets and we only wish to import one type of their styles.

XML
<button label="Get styles">
    <cmd case="BaseExtensions:apply-styles" path="SourceStyles.docx" filter="TOC"/>
</button>

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article