This module uses ReportLab to produce all the needed printouts.
Personal badges.
Cache for one year prized tourneys, no cache otherwise.
Abstract base class used to implement the printouts.
This class implements the logic used by most printouts, producing a PDF document in the output filename.
The document has a front page with an header, a body splitted into columns frames and a footer. Succeding pages do not have the header frame.
The width of the bottom margin, by default 1cm
Compute the cache control max age, in seconds.
Create the base Platypus document.
Add standard decorations to the current page.
Create and build the document.
Extract needed arguments for the constructor from the request.
Parameters: |
|
---|---|
Return type: | a sequence of arguments |
The bottom center text, current page number by default.
The top center text.
Return a list or an iterator of all the elements.
The bottom left text, SoL description and version by default.
The top left text.
The bottom right text, current time by default.
The top right text.
The subtitle of the document.
The title of the document.
The width of the left margin, by default 1cm
The page size, by default A4 in portrait orientation
The width of the right margin, by default 1cm
The width of the top margin, by default 1cm
Championship ranking.
Cache for one year closed championships, no cache otherwise.
General doubles ranking.
Next turn matches.
Current ranking of a tourney by nationality.
List of partecipants of a tourney.
Current ranking of a tourney.
Results of the last turn.
Score cards, where match results are written by the competitors.
Cache for one year blank score cards, no cache otherwise.
Add crop-marks to the page.
General singles ranking.
Basic tourney printout, to be further specialized.
Cache for one year prized tourneys, no cache otherwise.
Return location and date of the event.
Yield basic elements for the title frame in the first page.
Return championship description.
Return championship’s club description.
Return tourney description.
General women ranking.
The style used for the player name on the badges
The base style used to build the document
The style used for the caption of the table’s columns
The style used for the additional info on the score cards
The style used for the player name on the score cards
The style used for most of the text on the score cards
The style used for the title of the score cards
The style used for the heading paragraphs of the document
The style used for most of the paragraphs of the document
The width of the prizes columns
The width of the rank columns
Reduce the font size of the given styles to fit a max width.
Parameters: |
|
---|---|
Returns: | a list of (copies of) the styles with the adapted font size |
The width of the scores columns
The style used for the subtitle of the document
The style used for the title of the document