Title: QEL History Content-type: text/x-rst My quotation collections have a long history. The oldest is `my commonplace book `_, which began around 1989 or 1990. It was originally maintained as a PC-Write document, PC-Write being a shareware word processor that I ran on a Tandy 4MHz PC-compatible. In my second year at McGill, around 1993, I discovered Linux and began transferring all my computing activity away from MS-DOS. PC-Write wasn't (and still isn't) available for Linux, so I briefly converted the quotes to plain text format. In this brief interval, I started to post weekly excerpts from it to `alt.quotations `_; it took about 30 weeks to post the entire file. Fairly soon after that I shifted to TeX with a few macros, and wrote a Python program to convert the quotations to ASCII by stripping out the TeX macros. With the rise of the Web, I began to maintain some new collections in HTML format around 1996. Maintaining one set of TeX files and another set of HTML files quickly became a real pain, so I moved everything into HTML with a stylesheet to specify some additional formatting. For example, a quotation would look like::

A book of quotations... can never be complete.

Robert M. Hamilton

Preface, Canadian Quotations and Phrases: Literary and Historical (1952) In 1998, I began wanting to get more use out of my collections, most notably by adding a randomly-selected quotation to my e-mail messages and Usenet postings. This seem to require writing yet more formatting software, this time to parse HTML and convert it to an ASCII version that obeyed Usenet conventions, using \*asterisks\* for boldface and \_underscores\_ for citations, for example. The natural approach would be to parse the HTML, construct a data structure representing each quotation, and use the data to produce the various output formats. At about this time, XML was attracting a lot of attention for such purposes, and it was a technology I wanted to learn more about, so I decided to shift to an XML-based format. (Why use XML? To explain this for people unfamiliar with XML: XML was preferable to HTML for this purpose because it's a meta-language, allowing me to create a specialized markup language instead of assigning arbitrary meanings to HTML elements. XML parsers are also less forgiving than HTML ones; that's an advantage because it enforces more constraints on what input is considered legal, which simplifies writing software to process that input. It's much easier to deal with a few simple XML elements than the larger number of all potential HTML elements.) This XML-based format was never named anything at the time, but in retrospect this was QEL 1.0. In February 2001, I wanted to polish up the format, generalize it a bit by adding a few more formatting elements, and then publish the Document Type Declaration to encourage other people to use it. I also began writing the quotation-tools, a software package for processing QEL files; it's available from `the QEL Software page `_. So, my quotation collection has now settled down in an XML-based format, presumably for good. Here's a QEL 2.0 file::

First things first, but not necessarily in that order.

The Doctor In John Flanagan and Andrew McCulloch's Meglos

Part of season 18 of Doctor Who

This is a tiny quotation collection. The root element of a QEL file is the ``quotations`` element, which contains zero or more ``quotation`` elements. A ``quotation`` element contains the text of the quotation, along with optional ``author``, ``source``, and ``note`` elements. There are also various forms of textual emphasis available, mostly derived from HTML; for example, there's ``em``, ``cite``, and ``foreign``. QEL is specified using the `RELAX NG `_ schema language, in its compact syntax. Versions before QEL 2.0 were specified by a Document Type Declaration, or DTD. (`The QEL 2.01 DTD `_, the last version of the DTD, is still available, but will no longer be developed.) In September 2002, I converted the specification from a DTD into RELAX NG because RELAX NG is more powerful, and will simplify the job of adding indexing and metadata to QEL. The collections are maintained in XML, and converted into HTML, Unix ``fortune(6)`` format, and plain text by a set of Python scripts, part of the quotation-tools. You can download them from the `QEL Software page `_. Feel free to grab the code and play with it, or use it to maintain your own collection of quotations. For historical reference, here's what a document looked like in QEL 1.0:: First things first, but not necessarily in that order. The Doctor In John Flanagan and Andrew McCulloch's Meglos You can look at `the QEL 1.0 DTD `_ if you like, but there's little reason to bother.) QEL 1.0 is a bit simpler than 2.0, but not by much; QEL 2.0 is still a fairly straightforward DTD.

[Contact me]