main-title-box
Coding Techniques used for The Lord's PrayersThe Lord's Prayers web page was written
partly to test the programming interface described in the
Page Notes manual. Page Notes Manual and Reference Significant aspects of this
effort include dynamically modified style rules, the use of page notes to build
specialized Changing the style rules for lexical annotationsEach entry in the lexicon consists of a couple of adjacent spans enclosed in a paragraph. The left span is of class term and the right is of class dfn. The enclosing paragraph is of type lexical-entry and has its own id. eisenegkhV lead, bring, carry Each word in each prayer (e.g., e.g., lead) is regarded as a translation of a corresponding Greek word, is annotated with the Greek word's corresponding lexical entry, and has class ple (for plain English).
Using page notes to build drop-down menusEach of the five menus is annotated with a variable-free skin with buttons. When the mouse pauses on a menu, the corresponding button list is displayed. Each text label on each gold text button is further annotated with relevant historical information, and the active style for the text is darker. Annotations without destination links are used to darken highlighted text on the gray buttons. Each of the five main menus is also given a brighter active style. Each button has an associated selected and unselected style that responds to the onclick event in a manner that is entirely analogous to the active and inactive styles associated with onmousepause events. Which list a button belongs to is determined by its onclick handler. For example, buttons other than the lexical annotation buttons all lbelong to the same list and are handled by the SetPrayer function (so logically, the notes buttons also represent "prayers"). The SetPrayer function first changes the currently selected button. This involves obtaining the name of the clicked-on button from its visible button text and changing the global variable currentPrayerBtn accordingly; it also involves changing the button syntax of the two buttons to visibly reflect their changed status. Finally, SetPrayer changes the currently selected prayer by setting the innerHTML of the currentPrayerGoesHere object to that of the current prayer. Onload eventsThe Lords Prayers page contains an onload event handler that
Use of background imagesSome of the note boxes use finely textured background images to enliven their color. It's basically the same principle as expressionist paintings:
|