About Prayer Clock
Prayer Clock is a simple application to remind a user to say a certain prayer at a certain time. Prayer Clock also shows the prayers to the user so that the user can read the prayers from the application.
Frequently, I use a computer for the whole day. For my good health, I would like to rest for a while. During the moment of resting, for my spiritual health, I would like to say a prayer. Catholics have a prayer, called “Angelus”, which we will recite at 6 am, 12 pm, and 6 pm, three times a day. Besides that, Angelus will be replaced by Regina Caeli during Eastertide (Easter Season). In addition, there is a 3 O’clock Prayer in devotion to the Divine Mercy, which will be recited at 3 pm.
Though the prayers are able to be memorised, but in my opinion, this is not a very good practice. This is because when we are too familiar to the prayers, we will say the prayer automatically without meditating the meaning of the prayers. By reading the prayers (with our eyes) and say the prayers (with our mouth), we will focus more on the prayers.
Besides that, there are some novena prayers (nine days devotion) are recited according to the liturgical seasons, such as Novena to the Divine Mercy during the Eastertide and Novena to the Holy Spirit nine days before the Pentecost. Unlike Christmas, Easter Sunday is not fixed with the Gregorian calendar. A user might need a reminder and a booklet to start a novena.
There is no application to help a user to say prayers at a certain time.
To develop a software application that helps a user to say prayers at a certain time.
Prayer Clock is developed with the following system architecture:
The prayers are stored in XML format. XML allows the users to define their own prayers.
The engine is the core of Prayer Clock. It uses Expat library to parse the XML. The engine was written using “struct” with object-oriented concept. The engine is able to load the XML.
The interface is written using GTK+. interface will call the functions of the engine and display a certain prayer at a certain time.
The XML is designed that, each prayer has attributes: title and easter. Title is the title of a prayer. Easter is a relative day from the Easter Sunday. Such as, if the easter value is 0, then it means the prayer will be recited on Easter Sunday. If the easter value is 1, then the prayer will be recited on the next day of Easter Sunday. Contrarily, if the easter value is -1, then the prayer will be recited a day before the Easter Sunday.
Each prayer has several child nodes for time. A prayer might be recited several time of a day, such as Angelus: 6 am, 12 pm, and 6 pm. A user can add the time to the prayer so that the prayer will be shown.
Finally, the text node of a prayer is the prayer itself.
The Expat library is used to parse the XML. The data is stored in the “struct” accordingly. Therefore, the user can access the data using the struct. The “struct” is used so that it is compatible to C language and easier for studying. However, the object-oriented paradigm is adopted so that the code can be managed easily.
Besides that, there are several functions written for the calculation of the Easter Sunday. The calculation is taken from the Internet (please refers to the source code for the actual web address). However, the calculation of the Easter Sunday uses some functions of GLib (date and time). Therefore, the engine is depend on GLib. The dependency can be reduced in future.
The GUI (graphical user interface) is written using GTK+. It is chosen because it is written in C language and cross-platform. Since the engine and interface is separated, other GUI widget is also possible to be used, such as Qt, wxWidget, etc.
Prayer Clock is written in C++, and uses both procedural and object-oriented paradigm. It is able to be built on several platform, such as Linux (tested on Ubuntu) and Windows.
The design of the XML and the engine allows Prayer Clock to be ported to the higher language, such as Java. The Java version Prayer Clock is also built, namely JPrayer Clock. JPrayer Clock is developed according to the data structure design and the algorithm of Prayer Clock. They both use same XML file.
Prayer Clock is released as an open source software (currently adopting New BSD License). This is to contribute in the Catholic community. Besides that, the developers can use the source code freely.