View Single Post
Old 02-13-2010, 05:03 PM   #35
KNotTed is on a distinguished road
Posts: 19
Karma: 62
Join Date: Feb 2010
Device: PRS-505, PRS-600
Originally Posted by GeoffC View Post
I note, by accident this morning, there is an xml tag of <poem></poem>; has anyone had any success with this and its associated tags <verse><stanza> etc ..... I've found a few examples but none of them 'work' in my browser, nor can I find a definitive reference to their use ....
This interested me so I decided to check it out. CSS2 + XHTML is fairly flexible. Obviously, you can define styles for tags like p, i, em, etc. However, with this flexibility, you can also define new tags, e.g. a poem tag. I created the following style.css file:
poem {
  text-align: center; 
  font-style: italic;
  margin-top: 2.0ex;
  margin-bottom: 2.0ex;
  display: block;
p {
  text-indent: 1.1em; 
  margin: 0;
I created a test HTML file using this stylesheet, converted it to EPUB with Calibre, and tested it in Calibre's viewer, ADE, and on my Sony Reader. All three displayed the text in the poem tag centered and italics, with the proper top and bottom margins.

Last edited by KNotTed; 02-13-2010 at 05:16 PM.
KNotTed is offline   Reply With Quote