The service_ppt is an application generating PowerPoint slides for the Church's service.
It produces Bible Verse, lyric and announcement slides based on template with find and replace text.
The find and replace text can be applied to a text template file and can be saved as a text file for other purposes.
It also can insert slides that are pre-made such as song slides.
After it generates slide, it can export slides into images or shapes in slides into transparent images.
All these operations are done using Windows Powerpoint COM service and that means you need to have PowerPoint installed on your machine.
For OS X, it is using AppleScript but the feature is less mature than that of Windows.
This document describes how to set up the environment for the service_ppt application.
Install Python 3.9 from https://www.python.org/downloads/.
Add python3 to the PATH environment.
All the below packages can be install by following commands. Or each package can be installed one by one.
pip install -r requirement.txt # For Python 3.9
pip install -r requirement-3.10.txt # For Python 3.10
Install wxPython that is used for main GUI application.
pip install wxpython
These are common to Windows and Mac OS.
pip install iso639-lang
pip install langdetect
pip install numpy
pip install Pillow
pip install pysword
Install GNU gettext package and add the bin directory to the PATH environment.
The 'xgettext', 'msgfmt' and 'msgmerge' will be used for translation strings.
For Windows you can get the installer from http://gnuwin32.sourceforge.net/packages/gettext.htm.
Windows specific packages.
pip install pywin32
OS X specific packages.
pip install py-applescript
The Bible text can be retrieved from MyBible(Application's proprietary format),
MySword(https://www.mysword.info/modules-format),
Sword(https://pypi.org/project/pysword/0),
and Zefania(https://sourceforge.net/projects/zefania-sharp/files/Bibles/) format.
After installing required bible package and Bible text,
you need to set up the Active Bible from Application's preference.
The supported Hymn and lyric format is OpenLyric(https://docs.openlyrics.org/en/latest/).
But, it can be extended easily.
applescript - Test AppleScript files for OS X PowerPoint
bible - Bible text data structure and format reader.
hymn - Hymn and lyric data structure and reader.
image24, image32 - Icons/Images for Toolbar and command.
locale - Language translation.
sample - The sample service.sdf, service definition file that contains command instructions to generate slides file.
You need to update the pathnames in the file to be full path names before run it.
service_ppt.pyw - main application start up code.
mainframe.py - main window UI class.
command.py - The several **Command** classes to generate slides.
command_ui.py - The **CommandUI** classes that display UI for each Command classes.
powerpoint_base.py - The PresentationBase and PPTAppBase base classes that contain the common platform independent PowerPoint automation code
powerpoint_osx.py - The OS X specific classes using AppleScript to automate PowerPoint.
powerpoint_win32.py - The Windows specific classes using COM to automate PowerPoint.
The .sdf
file contains the command instructions saved from each Command.
It is a JSON file format internally.
Use pyinstaller==5.13.2
to make an executable.
pyinstaller service_ppt.spec