Add centered graph as first element.

This commit is contained in:
Sergio Martínez Portela 2023-06-26 23:56:32 +02:00
parent 9784f78f1c
commit 661a5e0cf8

View File

@ -726,10 +726,11 @@ def render(headline, doc, graph, headlineLevel, doc_to_headline_remapping):
print_tree(dom, indentation=2, headline=headline)
content = []
render_tree(dom, content, headline, graph)
if headline.id and headlineLevel == 0:
render_connections(headline.id, content, graph, doc_to_headline_remapping=doc_to_headline_remapping)
render_tree(dom, content, headline, graph)
for child in headline.children:
content.append(render(child, doc, headlineLevel=headlineLevel+1, graph=graph,
doc_to_headline_remapping=doc_to_headline_remapping))