How do I get next paragraph (without a 10pt space between lines)?
Lorem ipsum dolor sit amet
consectetur adipisicing elit
sed do eiusmod
I wrote each line in AddText call but it always starts a new paragraph. Any way of changing this?
Regards
An easy fix for this is to use importStyles() to load the styles from an existing Word document in which you have set the desired line spacing.
$docx = new CreateDocx();
$docx->importStyles('./default_styles.docx', 'replace');
You may control the line spacing with the lineSpacing option in the $paragraphOptions parameter.
The way Word handles it is a little bizarre: a value of 240 corresponds to single spacing and 480 to double spacing and so long so forth.
We decided to keep that notation although it could have been clearer to use a float with 1 corresponding to single spacing.