These are snippets of XML matched to Bookcove’s TEI converter. It is
a restricted subset. The ppxml program converts
BookCove/TEI XML to text, HTML, and EPUB3. These are tested examples of
typical markup used in BookCove XML source code. Note: all indentataion
is optional in these examples.
Here are clickable links to the major sections of this document.
<front>
<div type='titlepage'>
<figure rend="center">
<graphic url="images/illus-fpc.jpg" width="75%"/>
<figDesc>A dog holding a cougar by the neck.</figDesc>
</figure>
<lg>
<l rend='fs14 tac'>BILL OF THE WILD STREAK</l>
<l rend='tac mt05'>BY</l>
<l rend='fs12 mb10 tac'>Howard E. Morgan</l>
</lg>
</div>
</front>
This has a frontispiece illustration and a three-line title block.
Set the desired width on the illustration on the
<graphic...> line.
There are several user-defined CSS rules in use here, such as
fs14. Define these in the styles.css file.
Here is an example:
.fs12 { font-size: 1.2em; }
.fs14 { font-size: 1.4em; }
.mt05 { margin-top: 0.5em }
.mb10 { margin-bottom: 1.0em; }
.tac { text-align: center; }
If these are in style.css when the output formats are
generated, they will become part of the iinline CSS in the header.
<div type='frontispiece'>
<figure rend="center">
<graphic url="images/img-fpc.jpg"/>
<head><quote>She took up her verse where William had interrupted.</quote></head>
<figDesc>Emmy Lou holding her poetry book.</figDesc>
</figure>
</div>
<div type='titlepage'>
<lg>
<l rend='fs14'>EMMY LOU</l>
<l rend='fs14'>HER BOOK & HEART</l>
<l rend='mt10'>BY</l>
<l rend='fs12'>GEORGE MADDEN MARTIN</l>
<l rend='mt10 fs09'>AND ILLUSTRATED BY</l>
<l>CHARLES LOUIS HINTON</l>
</lg>
<lg>
<l>My Book and Heart</l>
<l>Must Never Part.</l>
<l>New England Primer</l>
</lg>
<lg>
<l>GROSSET & DUNLAP</l>
<l>Publishers New York</l>
</lg>
</div>
<div type='original_copyright'>
<lg>
<l>Copyright, 1901, 1902, by S. S. McClure Co.</l>
<l>Copyright, 1902, by</l>
<l>McCLURE, PHILLIPS & CO.</l>
<l>Fifteenth Impression</l>
</lg>
</div>
<div type='dedication'>
<lg>
<l>To My Sister</l>
<l>THE AUNT CORDELIA</l>
<l>of these stories, this</l>
<l>book is</l>
<l>affectionately inscribed</l>
</lg>
</div>
<div type='toc'>
<lg>
<l>CONTENTS</l>
</lg>
<list>
<item><ref target="ch1">The Right Promethean Fire</ref></item>
<item><ref target="ch2">A Little Feminine Casabianca</ref></item>
<item><ref target="ch3">Hare-And-Tortoise or the Bliss of Ignorance</ref></item>
<item><ref target="ch4">I Sing of Honor and the Faithful Heart</ref></item>
<item><ref target="ch5">The Play’s the Thing</ref></item>
<item><ref target="ch6">The Shadow of a Tragedy</ref></item>
<item><ref target="ch7">All the Winds of Doctrine</ref></item>
<item><ref target="ch8">The Confines of Consistency</ref></item>
<item><ref target="ch9">A Ballad in Print o’ Life</ref></item>
<item><ref target="ch10">Venus or Minerva?</ref></item>
</list>
</div>
</front>
This titlepage can be styled nicely with this in
styles.css:
.titlepage, .original_copyright, .dedication
{ text-align: center; margin: 2em 0; }
.titlepage p, .original_copyright p, .dedication p
{ margin: 0.5em 0; }
/* front page separators */
.titlepage, .dedication, .original_copyright, .toc {
border-bottom: 1px solid #999;
padding-bottom: 2em;
}
This goes in the <front>...</front>
section:
<div type='toc'>
<lg>
<l>CONTENTS</l>
</lg>
<list>
<item><ref target="chI">CHAPTER I</ref></item>
<item><ref target="chII">CHAPTER II</ref></item>
<item><ref target="chIII">CHAPTER III</ref></item>
<item><ref target="chIV">CHAPTER IV</ref></item>
<item><ref target="chV">CHAPTER V</ref></item>
</list>
</div>
For that to work, the Chapters need to have the targets shown. Example Chapter:
<div type="chapter" n="III" xml:id="chIII">
<head>CHAPTER III</head>
<text of the chapters>
</div>
<back>
<div type="notes">
<div type="transcriber">
<p>Transcriber’s note: This story appeared in the April 18, 1925 issue
of <hi rend="italic">Argosy-Allstory Weekly</hi> magazine.</p>
</div>
</div>
</back>
At the back of a typical magazine short story project, include a TN
as shown. Styleing can be simple or complicated. Here is a slightly more
complex CSS definition to style the TN. This goes in
styles.css also.
/* transcriber's note */
.transcriber {
font-size: 0.9em;
border: 1px solid silver;
margin: 1.8em 8% 0;
padding: 0.3em 2%;
background-color: #DDDDEE;
}
.transcriber p { text-indent: 0; margin: 0; }
Each book will have skightly different CSS depending on the post-processor’s ideas of how things should be presented. There is a lot of power in the CSS to change how something looks. It cannot change what something is, which is a building block of BookCove’s XML approach.
Here is a style.css example file:
body { margin-left: 11%; margin-right: 10%; line-height: 1.25; }
h1 { margin-bottom: 2em; font-weight: normal; text-align: center;
font-size: 1.4em; margin-bottom: 0; }
h2 { text-align: center; font-weight: normal; page-break-before: always;
font-size: 1.25em; margin-top: 3em; margin-bottom: 1em;
margin-left: auto; margin-right: auto; }
p { text-indent: 1.15em; margin-top: 0.1em; margin-bottom: 0.1em;
text-align: justify; }
p.no-indent { text-indent: 0; }
/* title page styling */
.mb10 { margin-bottom: 1.0em; }
.mt05 { margin-top: 0.5em; }
.fs12 { font-size: 1.2em; }
.fs14 { font-size: 1.4em; }
.tac { text-align: center; }
/* centering */
.titlepage
{ text-align: center; margin: 2em 0; }
.titlepage p
{ margin: 0.5em 0; }
/* front page separators */
.titlepage {
border-bottom: 1px solid #999;
padding-bottom: 2em;
}
/* transcriber's note */
.transcriber {
font-size: 0.9em;
border: 1px solid silver;
margin: 1.8em 8% 0;
padding: 0.3em 2%;
background-color: #DDDDEE;
}
.transcriber p { text-indent: 0; margin: 0; }
<figure rend="center">
<graphic url="images/img-009.jpg"/>
<head><quote>Emmy Lou winked bravely and smiled.</quote></head>
<figDesc>Emmy Lou smiling.</figDesc>
</figure>
<figure rend="left">
<graphic url="images/img-003.jpg"/>
<figDesc>children in a classroom</figDesc>
</figure>
<figure rend="right">
<graphic url="images/img-053.jpg"/>
<head><quote>Kitty McKoeghany.</quote></head>
<figDesc>Kitty McKoeghany standing</figDesc>
</figure>
Here is the CSS used for floated images:
/* override defaults for this book */
figure { width: 60%; }
figure.left { width: 30%; max-width: 30%; }
figure.right { width: 30%; max-width: 30%; }
<lg>
<l>How old are you, Sue?</l>
<l>I am as old as my cat.</l>
<l>And how old is your cat?</l>
<l>My cat is as old as my dog.</l>
<l>And how old is your dog?</l>
<l>My dog is as old as I am.</l>
</lg>
another, this one with some lines indented. Choices for indentation are “indent, indent2, indent3”.
<lg>
<l>“True friendship is a golden knot</l>
<l rend='indent'>Which angles’ hands have tied,</l>
<l>By heavenly skill its textures wrought</l>
<l rend='indent'>Who shall its folds divide?”</l>
</lg>
CSS to indent the poetry block:
/* poetry */
div.poem { margin-left: 2em; }
<milestone rend='stars'/>
<table>
<row><cell>18</cell></row>
<row><cell>100</cell></row>
<row><cell>9</cell></row>
</table>
CSS to indent the table:
/* table */
table { margin-left: 2em; }
<quote>
<p rend='ni'>Dere boys:</p>
<p>Well, you ok horsethieves, I thot I wood rite you a few lines to let
you no thet I had bin elekted head judge of the San Dominick Rodeo.
Maybe you thot I had fergit about the time you got me out of jak in
Berryville for chawin the cherifs ear off ha ha! Well, ole Clay Hinkle
is a man which does not terkit past favors. If yore intrested in splitin
1st and 2d mony in the bronk ridin I beg to state thet I will be only
too glad to give it to you. You understand I wood not go around offerin
this propozichon to every Tom, Dick and Harry, but you boys bein spechel
trends of mine I thot I wood give you 1st krak at it at the reguler
rates 50-50. This is a bargin on akount the competichon will be very
keen and I feel shure I coud git better terms only ole Clay Hinkle is a
man which does not fergit past favors.</p>
<p>I beg to remain as ever yores sincarly and Korjaly yores.</p>
<signed>Clay Hinkle.</signed>
</quote>
Notes: In TEI, <quote> can mark spoken words, as
in:
<quote>I would like some tea and cookies.</quote>.
The <quote> tag is also used as shown here to mark a
block quote.
The <signed> XML is standard TEI. It will float
signatures to the right.
The <rend='ni'> matches
.ni { text-indent: 0; } in CSS.