Cleanup: Combine context managers and get it out of function

There is no need to have three separate context managers here. Also
putting it out of the function will allow further reuse and shortens
the function incresing code readability.
WORKING ON IT: Add IDML converter
idml2po: Parse just the Content tags and skip CDATA

From our initial researchs the translatable string are only within
Content tags.
idml2po: Actually convert to PO instead of XLIFF
WORKING ON IT:    Trying to get roundtrip conversion working
po2idml: Skip first unit when retrieving translated units

This doesn't apply on XLIFF because all units have a source, but in PO
the first unit parsed is the one in the PO header, which has blank source.
idml2po: Record in unit location the file within the IDML it was extracted from

This records a second location on each unit, besides the other location
used to keep the xpath.

This is necessary because the files we are extracting from the IDML packages
have the same root tag, where the ODF packages have a different root tag
for each of the translatable files we extract.

This change doesn't require any alterations in the ODF converters.
po2idml: Open the template IDML sooner to list translatable files

This will allow to add code in next commit for listing the translatable
files in the IDML package.
This is necessary to be able to group the translated units per translatable
file, and thus build the XPathTree objects for each of them.
po2idml: Call build_unit_tree for each translatable file

This is necessary because the previous code were used for ODF, where each
of the three translatable files had a different root tag, where all the
translatable files in IDML use the same root tag, so the code was unable
to create a separate unit tree for each translatable file within the IDML
package.
po2idml: Correctly handle tags without namespace
po2idml: Export CDATA as is
po2idml: Output standalone="yes" on XML declaration
po2idml: Add function to retrieve DOM objects for pounit source and target

Since we want to reuse as much as possible the previous code for ODF, it
is necessary to provide DOM objects for pounit source and target, like
the ones present in xliffunit.source_dom and xliffunit.target_dom.

This change doesn't affect the ODF converters.
COMMENTS

REMOVE WHEN IT WORKS
UNDO   REMOVE THESE COMMENTS
WORKING:   modify idml2po to extract special characters.

We are talking about special characters recorded as XML processing
instructions, like for example <?ACE 7?>.
WORKING on  getting processing instructions roundtripped
WORKING:   ADD IDML roundtrip tests
UNDO
UNDO