mirror of
https://github.com/iluvcapra/ptulsconv.git
synced 2025-12-31 08:50:48 +00:00
Eh committing the example
This commit is contained in:
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@@ -169,6 +169,7 @@ def create_adr_reports(parsed):
|
|||||||
os.makedirs("Avid Markers", exist_ok=True)
|
os.makedirs("Avid Markers", exist_ok=True)
|
||||||
os.chdir("Avid Markers")
|
os.chdir("Avid Markers")
|
||||||
output_avid_markers(lines)
|
output_avid_markers(lines)
|
||||||
|
os.chdir("..")
|
||||||
|
|
||||||
print_status_style("Creating Scripts directory and reports")
|
print_status_style("Creating Scripts directory and reports")
|
||||||
os.makedirs("Talent Scripts", exist_ok=True)
|
os.makedirs("Talent Scripts", exist_ok=True)
|
||||||
|
|||||||
@@ -50,11 +50,11 @@ class ADRDocTemplate(BaseDocTemplate):
|
|||||||
BaseDocTemplate.build(self, flowables, filename, canvasmaker)
|
BaseDocTemplate.build(self, flowables, filename, canvasmaker)
|
||||||
|
|
||||||
|
|
||||||
def make_doc_template(page_size, filename, document_title, record, document_header=""):
|
def make_doc_template(page_size, filename, document_title, record, document_header="", left_margin=0.5 * inch):
|
||||||
left_margin = right_margin = top_margin = bottom_margin = 0.5 * inch
|
right_margin = top_margin = bottom_margin = 0.5 * inch
|
||||||
page_box = GRect(0., 0., page_size[0], page_size[1])
|
page_box = GRect(0., 0., page_size[0], page_size[1])
|
||||||
_, page_box = page_box.split_x(left_margin, direction='r')
|
_, page_box = page_box.split_x(left_margin, direction='l')
|
||||||
_, page_box = page_box.split_x(right_margin, direction='l')
|
_, page_box = page_box.split_x(right_margin, direction='r')
|
||||||
_, page_box = page_box.split_y(bottom_margin, direction='u')
|
_, page_box = page_box.split_y(bottom_margin, direction='u')
|
||||||
_, page_box = page_box.split_y(top_margin, direction='d')
|
_, page_box = page_box.split_y(top_margin, direction='d')
|
||||||
|
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ def build_story(lines):
|
|||||||
]]
|
]]
|
||||||
|
|
||||||
line_table = Table(data=line_table_data,
|
line_table = Table(data=line_table_data,
|
||||||
colWidths=[inch * 1., inch, inch * 3., 0.5 * inch, inch * 2.],
|
colWidths=[inch * 0.75, inch, inch * 3., 0.5 * inch, inch * 2.],
|
||||||
style=table_style)
|
style=table_style)
|
||||||
|
|
||||||
if line.get('Scene', "[No Scene]") != this_scene:
|
if line.get('Scene', "[No Scene]") != this_scene:
|
||||||
@@ -127,7 +127,8 @@ def generate_report(page_size, lines, character_number=None, include_done=True,
|
|||||||
filename = title + ".pdf"
|
filename = title + ".pdf"
|
||||||
doc = make_doc_template(page_size=page_size,
|
doc = make_doc_template(page_size=page_size,
|
||||||
filename=filename, document_title=title,
|
filename=filename, document_title=title,
|
||||||
record=lines[0], document_header=document_header)
|
record=lines[0], document_header=document_header,
|
||||||
|
left_margin=0.75 * inch)
|
||||||
story = build_story(lines)
|
story = build_story(lines)
|
||||||
doc.build(story)
|
doc.build(story)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user