Fix extraneous paragraphs when parsing text for API docs.

Review Request #8771 — Created Feb. 20, 2017 and submitted

Information

Review Board
release-2.5.x
a498ed3...

Reviewers

When feeding a multi-line string to parse_text(), the resulting nodes
were a paragraph of paragraphs, which doesn't properly convert to HTML.
It ends up resulting in some extra blank paragraphs, messing with
spacing.

This changes parse_text() to default to returning the child elements
that were created, rather than the containing node. For those uses where
we do want a containing node returned, we can still do so, but it's now
optional.

This fixes some odd spacing issues I've noticed for a while in our API
docs in field descriptions.

Browsed through the docs. Paragraphs were still intact, as were the
nodes that needed the specific wrapping element. Field definitions that
had extra empty paragraphs were fixed.

reviewbot
  1. Tool: Pyflakes
    Processed Files:
        docs/manual/_ext/webapidocs.py
    
    
    
    Tool: PEP8 Style Checker
    Processed Files:
        docs/manual/_ext/webapidocs.py
    
    
  2. 
      
david
  1. Ship It!
  2. 
      
chipx86
Review request changed
Status:
Completed
Change Summary:
Pushed to release-2.0.x (9787e09)