schrodinger.application.desmond.rl_helper module

schrodinger.application.desmond.rl_helper.new_page(Elements)

insert page break

schrodinger.application.desmond.rl_helper.add_vtable(Elements, table, style, width_list)

add table, where header is in the first column

schrodinger.application.desmond.rl_helper.add_table(Elements, table, style, col_width)

horizontal table, where the header is on the first row

schrodinger.application.desmond.rl_helper.add_and_parse_SMILES(smiles_str)

parse SMILES string such that it fits on the page

schrodinger.application.desmond.rl_helper.add_spacer(Elements)
schrodinger.application.desmond.rl_helper.get_image(fn, height, width)
schrodinger.application.desmond.rl_helper.header(Elements, txt, style=<ParagraphStyle 'Heading1'>, klass=<class 'reportlab.platypus.paragraph.Paragraph'>, sep=0.3)
schrodinger.application.desmond.rl_helper.get_pargph(txt, fixed=False, fontsize=11, color='black', hAlign='left')
schrodinger.application.desmond.rl_helper.pargph(Elements, txt, fixed=False, fontsize=11, color='black', leading=None)

Add a paragraph to the report

Parameters
  • Elements (list) – Report elements to add the paragraph to

  • txt (str) – The paragraph text

  • fontsize (int) – The size of the paragraph font

  • color (str) – Font color

  • leading (int or None) – Spacing between paragraph lines, the default will be used if nothing is passed

schrodinger.application.desmond.rl_helper.aspectScale(ix, iy, bx, by)

Scale image to fit into box (bx,by) keeping aspect ratio

class schrodinger.application.desmond.rl_helper.NumberedCanvas(*args, **kwargs)

Bases: reportlab.pdfgen.canvas.Canvas

__init__(*args, **kwargs)

Create a canvas of a given size. etc.

You may pass a file-like object to filename as an alternative to a string. For more information about the encrypt parameter refer to the setEncrypt method.

Most of the attributes are private - we will use set/get methods as the preferred interface. Default page size is A4. cropMarks may be True/False or an object with parameters borderWidth, markColor, markWidth and markLength

if enforceColorSpace is in (‘cmyk’, ‘rgb’, ‘sep’,’sep_black’,’sep_cmyk’) then one of the standard _PDFColorSetter callables will be used to enforce appropriate color settings. If it is a callable then that will be used.

showPage()

Close the current page and possibly start on a new page.

save()

add page info to each page (page x of y)

drawFixedContents(page_count)

Draw nonflowables such as footers, headers and fixed graphics

Parameters

page_count (int) – Total number of pages