The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Document::OOXML::Document::Wordprocessor - Wordprocessor file (".docx")

VERSION

version 0.181410

DESCRIPTION

This class represents a "wordprocessor" file in OOXML format (usually, these have the extension .docx).

It will be returned by Document::OOXML when reading a document with a WordprocessingML main document part.

METHODS

remove_spellcheck_markers

Remove spellcheck markers (<w:proofErr>) from the document.

merge_runs

Merge the content of identical adjacent runs (<w:r> elements).

This is done internally to make finding and replacing text easy/possible.

find_text_nodes(qr/text/)

Finds w:t nodes matching a specified regular expression, splits the run around the match, and returns the matching parts.

The regular expression should not contain capture groups, as this will mess with the text run splitting.

replace_text($search, $replace)

Finds all occurrences of $search in the text of the document, and replaces them with $replace.

SEE ALSO

AUTHOR

Martijn van de Streek <martijn@vandestreek.net>

COPYRIGHT AND LICENSE

This software is copyright (c) 2018 by Martijn van de Streek.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.