XML API - pdx:createCharacterStyle


Creates a new Word character style.


You are reading the XML API documentation. For the API method please go to createCharacterStyle.


Element definition

This element allows the generation of custom character styles that may be later used in combination with, for example, the addText element.

Attributes and sub-elements


A string with the name of the Word style that you are creating.


Key Description
bold Bold text: 'on' or 'off'.
caps Displays text in capital letters: 'on' or 'off'.
characterBorder Adds a border to the character. Attributes and values: 'type' => none, single, double, dashed..., 'color' => ffffff, ff0000, 'spacing'=> 0, 1, 2..., 'width' => in eights of a point.
color Hexadecimal color value: 'FF0000', '000000'...
doubleStrikeThrough If true displays text in doubleStrikeThrough.
em Emphasis mark type: 'none', 'dot', 'circle', 'comma', 'underDot'.
font Font family: 'Arial', Calibri'...
fontSize Text size in points: 8, 9, 10...
italic Italics: 'on' or 'off'.
position Position value. Positive value for raised and negative value for lowered.
strikeThrough If true displays text in strikethrough.
subscript If true displays text in subscript.
superscript If true displays text in superscript.
underline Underlines text. Possible values are: 'single', 'words', 'double', 'dotted', 'dash' and 'wave'.
vanish Uses a vanish style.
Code samples

Example #1




PHP code

The resulting Word document looks like: