Package: pibooth-picture-template
pibooth-picture-templateis a plugin for thepiboothapplication.It permits to define the captures/texts positions and sizes using a template. The template file
(XML based onmxGraphModel definition)
can be easily created/edited using the free online diagram softwareFlowchart Maker.A set of templates can be found onGitHub.Thefancy.xmltemplate is automatically installed by this plugin in~/.config/pibooth/picture_template.xml.Below are the pictures generated with this one (learn here how toCreate a template):Install$ pip3 install pibooth-picture-templateConfigurationHere below the new configuration options available in thepiboothconfiguration.The keys and their default values are automatically added to your configuration after firstpiboothrestart.[PICTURE]# Pictures template path, it should contain 8 pages (4 capture numbers and 2 orientations)template=picture_template.xmlNoteEdit the configuration by running the commandpibooth--config.Picture orientationATemplateParserErroris raised if the requested orientation for the selected
captures number can not be found in the template file.If[PICTURE][orientation]= autothe best orientation is chosen following these
rules:find a template with the correct number of captures and placeholders with same orientation
than the captures.find a template with the correct number of captures.find a template with portrait orientationCreate a templateThe steps below will show how to create a basic template file from scratch using
theFlowchart Makerapplication.This file may contain several templates to define the picture layout for1/2/3/4captures andportrait/landscapeorientations.Step 1: create a new fileClick onCreate New Diagram.Choose a blank diagram. Modify the name of the diagram, it will be
the name of the exported file. Click onCreate.Select the appropriated paper size. A custom one can be defined ininches.NoteIt could be easier to start from an existing file. Click onOpen Existing Diagramto load the default template file located in~/.config/pibooth/picture_template.xmlStep 2: placeholder for capturesChoose a rectangle to define a capture placeholder. Other shapes
have no effect and will be considered as rectangles.Resize the rectangle to fit the desired size. The rectangle can
overflow the border of the page to make design effects. Up to 4
rectangles can be drawn.The captures placeholders shall be numbered (1to4) to
define the captures to be placed inside. Colored shapes give a
better overview of the layout but they are not rendered on the
final picture.NoteImages can also be inserted in the template. Use the optionTo backorTo Frontto chose the displayed order (PNG and JPG format accepted).Step 3: placeholder for textsChoose a text box to represent a text placeholder.Resize the text box to fit the desired size. Up to 2 text boxes
can be drawn depending on thepiboothconfiguration.The text placeholders shall be numbered (1,2,footer_text1orfooter_text2) to define the text to be
placed inside.Step 4: picture resolutionExtra properties can be set to the template. Click on the buttonEdit Data(close to the paper size settings). Typedpiin
the entry box and click onAdd Property.By default a resolution of600DPI is used. It means that the
picture size will be 2400x3600 pixels for a resolution of 4x6
inches. Set it to the desired value and click onApply.Step 5: add new a templateOnce the template is created. A new one can be defined for an
other captures number or other orientation. Click on+to add
a new page.The same picture can be used several times in the template to
allows a symmetric template for example (one copy for you, one for
your guests).Step 6: save the template fileGenerate the XML file by clickingFile,Export as,XML....Click onExport(unselectCompressedif you want to edit
the file manually later).NoteInstead of runningpibootheach time you want to test the result of
your template, use the commandpibooth-regen. It will regenerate
the existing pictures present in~/Pictures/piboothusing the new
template.