Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Formats > Workshop

Notices

Reply
 
Thread Tools Search this Thread
Old 06-09-2009, 02:18 PM   #16
ahi
Wizard
ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.
 
Posts: 1,790
Karma: 507333
Join Date: May 2009
Device: none
Quote:
Originally Posted by kovidgoyal View Post
@Jellby: The correct way to do poetry in XHTML would be

Code:
<div class="poem">
<div class="stanza">
<div class="line">
...
</div>
.
.
.
</div>
.
.
.
</div>
---

Or...

Code:
<div class="verse">
<div class="stanza">
<div class="line">
...
</div>
.
.
.
</div>
.
.
.
</div>
... since "verse" is preferred by LaTeX (and presumably other systems also) as more generic than poem.

---

or...

Code:
<div class="poem">
<div class="line">
...
</div>
.
.
.
</div>
If you have only one a single poem that does not have multiple stanzas.

---

Or...

Code:
<div class="quote">
<div class="line">
...
</div>
.
.
.
</div>
If you are quoting just a few excerpted lines from a particular poems certain stanza.

I write this post to further illustrate my point in the preceding post, without meaning to disagree with your suggestion, Kovid.

- Ahi
ahi is offline   Reply With Quote
Old 06-09-2009, 02:18 PM   #17
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,544
Karma: 19001583
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Quote:
Originally Posted by kovidgoyal View Post
@Jellby: The correct way to do poetry in XHTML would be
[...]
Set the text-indent property in CSS to have the div mimic the behavior of a <p>
Fine, but what if <div class="poem"> belongs logically inside a <p>, like when a character quotes a couple of lines from a poem and then continues speaking? I have to either use <div> instead of <p> and "fake" it, or split the <p> into two <p>'s and "fake" the second being a continuation of the first.

@ Ahi: I see what you mean, and it's good to have some standardization, but I don't believe it is possible to consider all possible variations that could be found in real books. No matter how many pre-specified semantic tags you may invent, there will always be an author and a book who will demand a new one for "this particular piece of information which does not fit any of the above" (but I can't say I know anything about TEI-MEK, for instance).
Jellby is offline   Reply With Quote
Advert
Old 06-09-2009, 02:24 PM   #18
ahi
Wizard
ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.
 
Posts: 1,790
Karma: 507333
Join Date: May 2009
Device: none
Quote:
Originally Posted by Jellby View Post
@ Ahi: I see what you mean, and it's good to have some standardization, but I don't believe it is possible to consider all possible variations that could be found in real books. No matter how many pre-specified semantic tags you may invent, there will always be an author and a book who will demand a new one for "this particular piece of information which does not fit any of the above" (but I can't say I know anything about TEI-MEK, for instance).
The best one can do is to be aware what the given XML dialect will be used for, and cover as much ground as possible, while providing sufficiently usable primitive elements that can be used in combination to make up for a missing (and hopefully hardly never necessary) tag. (In other words, if you cannot describe in a standard and expected way precisely and accurately what something is; do your best to explain what should be done with it/how it should be displayed correctly. Ideally though, 9 out of 10 documents, in fact 99 out of a 100 documents should not need to resort to fallbacks.)

I am not intimately familiar with TEI-MEK yet either... but note that they have several dialects:

- One for academic writing (complex layouts, I believe)
- One for articles--handled fundamentally differently in some ways than books
- One for mixed documents (that, I believe, maximize the available tags/techniques by drawing upon multiple sources)
- One for prose.
- One for drama (i.e.: plays).
- One for verse.

Given this sort of foreplanning, and thoughtful XML dialect design, they ought only rarely come upon material that requires an unusual approach for encoding some piece of it.

- Ahi

Last edited by ahi; 06-09-2009 at 02:26 PM. Reason: added further clarification
ahi is offline   Reply With Quote
Old 06-09-2009, 02:36 PM   #19
ahi
Wizard
ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.
 
Posts: 1,790
Karma: 507333
Join Date: May 2009
Device: none
Quote:
Originally Posted by Jellby View Post
Fine, but what if <div class="poem"> belongs logically inside a <p>, like when a character quotes a couple of lines from a poem and then continues speaking? I have to either use <div> instead of <p> and "fake" it, or split the <p> into two <p>'s and "fake" the second being a continuation of the first.
Let me briefly address your specific issue--quite apart from the general discussion:

Are you sure the quoted lines need be separated out of the body of the paragraph? Sometimes they can be left embedded therein, like so:

Quote:
After defeating the monstrously evil Sugar Fairy, the wise little Hedgehog became thoughtful, remembering the words, "Here lies a toppled God/his fall was not a small one./We did but build his pedestal,/a narrow and a tall one" and sighed wistfully.
Take a look at this page:
http://tinablue.homestead.com/poetryguidesheet.html

It's mostly horrible, but under "3. IN-TEXT and OFFSET STYLES." it explains the sort of quotation I mean.

- Ahi
ahi is offline   Reply With Quote
Old 06-10-2009, 05:23 AM   #20
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,544
Karma: 19001583
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Quote:
Originally Posted by ahi View Post
Are you sure the quoted lines need be separated out of the body of the paragraph?
Yes, it's like that a few times in Don Quixote.
Jellby is offline   Reply With Quote
Advert
Old 06-10-2009, 09:46 AM   #21
ahi
Wizard
ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.
 
Posts: 1,790
Karma: 507333
Join Date: May 2009
Device: none
Quote:
Originally Posted by Jellby View Post
Yes, it's like that a few times in Don Quixote.
How about this then:

Quote:
<p>
The fine gentleman sat down to the table. Seeing that supper was not yet served, he began to sing:
</p>

<p class="poem">
<div class="stanza">
Volt idö mikor még nem voltál,
S nem éreztem, hogy fájna majd ha nem volnál;
és most látod, féltelek, őrízlek, védelek;
Mert lesz idö meglehet, hogy nem leszel már.
</div>

<div class="stanza">
Változnak az évszakok, rossz idők, szép napok;
Bujj hozzám, ne hagyj el;
Ha én mennék, ne engedj el.
Változnak az évszakok jó idők, rossz napok;
Bujj hozzám, ne hagyj el;
Ha én mennék, ne engedj el!
</div>
</p>

<p class="continued">
Until he was rudely interrupted by an altogether too jolly servant plonking a big slab of meat onto his plate.
</p>
Have the p.continued class simply displayed in a way that visually suggests the continuation of the paragraph in the way the book in question requires.

- Ahi

P.s.: A lack of definitively correct way to do things means that you might as well get creative.
ahi is offline   Reply With Quote
Old 06-10-2009, 10:55 AM   #22
Jellby
frumious Bandersnatch
Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.Jellby ought to be getting tired of karma fortunes by now.
 
Jellby's Avatar
 
Posts: 7,544
Karma: 19001583
Join Date: Jan 2008
Location: Spaniard in Sweden
Device: Cybook Orizon, Kobo Aura
Quote:
Originally Posted by ahi View Post
Have the p.continued class simply displayed in a way that visually suggests the continuation of the paragraph in the way the book in question requires.
Yes, that's what I have to do. But it's not logical markup, it does not reflect the text structure correctly, it's more a visual markup, which is what we were trying to avoid
Jellby is offline   Reply With Quote
Old 06-10-2009, 11:20 AM   #23
ahi
Wizard
ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.ahi ought to be getting tired of karma fortunes by now.
 
Posts: 1,790
Karma: 507333
Join Date: May 2009
Device: none
Quote:
Originally Posted by Jellby View Post
Yes, that's what I have to do. But it's not logical markup, it does not reflect the text structure correctly, it's more a visual markup, which is what we were trying to avoid
Very true.

Let me make a confession:

As much as logical markup appeals to me, with some regularly I find that in HTML and XHTML the benefits are too often hypothetical whereas the hindrances all too real.

- Ahi
ahi is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
calibredb list --output-format=xml no longer supported Mekk Library Management 6 06-11-2010 08:13 AM
Epub revision - alignment with broadly-adopted Web standards Nate the great ePub 4 04-08-2010 10:38 PM
Master Format for multi-format eBook Generation? cerement Workshop 43 04-01-2009 12:00 PM
Ebook Library refusing to load on screen when new media.xml file required seajewel Calibre 0 06-29-2008 07:46 PM
IDPF - New digital book standard released: OEBPS (XML format) & OCF (container) CommanderROR News 13 11-04-2006 08:49 AM


All times are GMT -4. The time now is 11:31 AM.


MobileRead.com is a privately owned, operated and funded community.