Loading generateBaseline/postprocessing.py +6 Changes for generateBaseline/postprocessing.py: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -2509,6 +2509,12 @@ def update_references(docx_input, docx_output): if parent is not None: ref_index = list(parent).index(reference_run) parent.insert(ref_index + 1, tab_run) # Trim any space in the next w:r/w:t element after the tab run next_elem = parent[ref_index + 2] if next_elem.tag.endswith('}r') and next_elem.xpath('.//w:t', namespaces=ns): next_text = next_elem.xpath('.//w:t', namespaces=ns)[0].text if next_text: next_elem.xpath('.//w:t', namespaces=ns)[0].text = next_text.lstrip() counter += 1 Loading Loading
generateBaseline/postprocessing.py +6 Changes for generateBaseline/postprocessing.py: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -2509,6 +2509,12 @@ def update_references(docx_input, docx_output): if parent is not None: ref_index = list(parent).index(reference_run) parent.insert(ref_index + 1, tab_run) # Trim any space in the next w:r/w:t element after the tab run next_elem = parent[ref_index + 2] if next_elem.tag.endswith('}r') and next_elem.xpath('.//w:t', namespaces=ns): next_text = next_elem.xpath('.//w:t', namespaces=ns)[0].text if next_text: next_elem.xpath('.//w:t', namespaces=ns)[0].text = next_text.lstrip() counter += 1 Loading