Remove paragraph deduplication. Apparently it's not necessary after all..?
continuous-integration/drone/push Build is failing Details

This commit is contained in:
Dan Helfman 2023-02-03 11:56:43 -08:00
parent 5789f9b188
commit 3d2bb6f5be
1 changed files with 0 additions and 6 deletions

View File

@ -70,7 +70,6 @@ def right_align_header(document):
def double_space_and_indent(paragraphs):
this_paragraph_plaintext = False
previous_paragraph_plaintext = False
previous_paragraph_style = None
for paragraph in paragraphs:
paragraph.paragraph_format.line_spacing = 2
@ -89,12 +88,7 @@ def double_space_and_indent(paragraphs):
if this_paragraph_plaintext and previous_paragraph_plaintext:
paragraph.paragraph_format.first_line_indent = docx.shared.Inches(0.5)
# Remove duplicate empty paragraphs to cut down on vertical whitespace.
if paragraph.style == previous_paragraph_style and not paragraph.text:
paragraph._element.getparent().remove(paragraph._element)
previous_paragraph_plaintext = this_paragraph_plaintext
previous_paragraph_style = paragraph.style
def parse_arguments(unparsed_arguments):