Marking up poetry in (x)html

Jim Adcock wrote on Fri Feb 17 (somewhat precised by me):
... the common PG/DP approach which I think is being generated by guiguts is not bad: ... ... <style type="text/css"> ... .poem span.i0 {display: block; margin-left: 0em; padding-left: 3em; text-indent: -3em;} ... .poem span.i2 {display: block; margin-left: 1em; padding-left: 3em; text-indent: -3em;} ... .poem span.i4 {display: block; margin-left: 2em; padding-left: 3em; text-indent: -3em;} ... </style> ... ... <div class="poem"> ... <div class="stanza"> ... <span class="i0">There was a young man of St. Kitts,<br /></span> ... <span class="i0">Who was very much troubled with fits;<br /></span> ... <span class="i2"> The eclipse of the moon<br /></span> ... <span class="i2"> Threw him into a swoon;<br /></span> ... <span class="i0">Where he tumbed and broke into bits.<br /></span> ... </div> ... </div>
The abstraction of a "line" which would ideally be displayed on one line of a small device, but with extra wrap-indent when it cannot, seems extremely useful (for those machines on which it works). A couple of questions though: 1. Is there an obvious reason not to use: div.i0 {margin-left: 0em; padding-left: 3em; text-indent: -3em;}, etc and <div class="i0">There was a young man...</div>, etc? Somehow using a tag which is inherently a block seems more simple and obvious than using a span with {display: block;} 2. Is there an unstated reason/convention for describing an indent of 1em as class=i2, 2em as class=i4, etc? This is not a trick question, I ask from curiosity/ignorance. Bob Gibbins

On Feb 27, 2012, at 11:45, Robert Gibbins wrote:
1. Is there an obvious reason not to use: div.i0 {margin-left: 0em; padding-left: 3em; text-indent: -3em;}, etc and <div class="i0">There was a young man...</div>, etc? Somehow using a tag which is inherently a block seems more simple and obvious than using a span with {display: block;}
None that I know of. Some of us do just that, for the reason you state. (;
2. Is there an unstated reason/convention for describing an indent of 1em as class=i2, 2em as class=i4, etc? This is not a trick question, I ask from curiosity/ignorance.
I think it's supposed to be the approximate number of letters/spaces the text is indented. 1em is equivalent to about two spaces in the text version. (Which doesn't mean you can't name your classes after the number of ems instead, if you prefer.) Jana

Bob>A couple of questions though: 1. Is there an obvious reason not to use: div.i0 {margin-left: 0em; padding-left: 3em; text-indent: -3em;}, etc and <div class="i0">There was a young man...</div>, etc? Somehow using a tag which is inherently a block seems more simple and obvious than using a span with {display: block;} 2. Is there an unstated reason/convention for describing an indent of 1em as class=i2, 2em as class=i4, etc? This is not a trick question, I ask from curiosity/ignorance. If I remember right I think I tried it both ways and found it did not help generate better results on mobi devices, in which case there is not a practical reason to prefer one to the other. Most people (who write poetry examples on the web) seem to be more comfortable labeling "sentence-like or less" structures as being "spans" and "paragraph-sized" structures as being "divs" -- whether or not each of those is best rendered "block" vs. "inline." I assume "i0" might mean "indent 0" and "i2" might mean "indent 2" where if one actually tries it one finds that a size of 1em corresponds to a width of approx 2 lower case letters. A em unit corresponding [approximately?] to the width of a font's em-dash, which is about two lower chars wide. Trying to dig into this more, I think W3C is taking an "em" to mean an em-square, i.e. the vertical size and horizontal size of an em are identical (say square pixel) units. So a tall skinning font effectively indents more on a "1 em" specification that an short fat font, since an "em" is the height of a capital 'M' in a given font. [1 em being literally the "font-size" of a particular font, but then I can't find a W3C definition of "font-size" presumably because that was considered too obvious.] And then you have the problem that the reported "font-sizes" of different fonts on different machines or even within one machine goes all over the place, such that mixing fonts of "the same font size" clearly doesn't work if one actually tries this on different machines! PS: Scream: how can it be that font designers cannot even agree on what a "font-size" such as "pts" mean??? PPS: Mobi machines getting all this font size specification "1 em" etc. stuff *way wrong* in any case! PPPS: Some "poetry experts" who want to get this stuff to look right on Kindle hard-wire the indents using which does work on the Klassic Kindles (as opposed to the guiguts approach suggested previously which is fail-soft on the Kindles) but that approach is so ugly I am assuming PG'ers would throw a hissy fit if told to take that approach.

On Mon, February 27, 2012 3:45 am, Robert Gibbins wrote:
Jim Adcock wrote on Fri Feb 17 (somewhat precised by me):
... the common PG/DP approach which I think is being generated by guiguts is not bad: ... ... <style type="text/css"> ... .poem span.i0 {display: block; margin-left: 0em; padding-left: 3em; text-indent: -3em;} ... .poem span.i2 {display: block; margin-left: 1em; padding-left: 3em; text-indent: -3em;} ... .poem span.i4 {display: block; margin-left: 2em; padding-left: 3em; text-indent: -3em;} ... </style> ... ... <div class="poem"> ... <div class="stanza"> ... <span class="i0">There was a young man of St. Kitts,<br /></span> ... <span class="i0">Who was very much troubled with fits;<br /></span> ... <span class="i2"> The eclipse of the moon<br /></span> ... <span class="i2"> Threw him into a swoon;<br /></span> ... <span class="i0">Where he tumbed and broke into bits.<br /></span> ... </div> ... </div>
The abstraction of a "line" which would ideally be displayed on one line of a small device, but with extra wrap-indent when it cannot, seems extremely useful (for those machines on which it works). A couple of questions though: 1. Is there an obvious reason not to use: div.i0 {margin-left: 0em; padding-left: 3em; text-indent: -3em;}, etc and <div class="i0">There was a young man...</div>, etc?
No. According to the HTML spec, "[The <DIV> and <SPAN>] elements define content to be inline (SPAN) or block-level (DIV) but impose no other presentational idioms on the content." Other than hiding a section of text ("display:none") there is no reason to set the display attribute of either element; just use the correct one to begin with.
Somehow using a tag which is inherently a block seems more simple and obvious than using a span with {display: block;}
True.
2. Is there an unstated reason/convention for describing an indent of 1em as class=i2, 2em as class=i4, etc? This is not a trick question, I ask from curiosity/ignorance.
While clearly ugly, the use of non-breaking spaces to offset lines is more flexible that using CSS. I tend to avoid CSS for styling in those instances where the presentation /must not/ vary.

Of course you realize that all this is way beyond what should be expected of a person who is proofing and marking up text. On Mon, Feb 27, 2012 at 11:06 AM, Lee Passey <lee@novomail.net> wrote:
On Mon, February 27, 2012 3:45 am, Robert Gibbins wrote:
Jim Adcock wrote on Fri Feb 17 (somewhat precised by me):
... the common PG/DP approach which I think is being generated by guiguts is not bad: ... ... <style type="text/css"> ... .poem span.i0 {display: block; margin-left: 0em; padding-left: 3em; text-indent: -3em;} ... .poem span.i2 {display: block; margin-left: 1em; padding-left: 3em; text-indent: -3em;} ... .poem span.i4 {display: block; margin-left: 2em; padding-left: 3em; text-indent: -3em;} ... </style> ... ... <div class="poem"> ... <div class="stanza"> ... <span class="i0">There was a young man of St. Kitts,<br /></span> ... <span class="i0">Who was very much troubled with fits;<br /></span> ... <span class="i2"> The eclipse of the moon<br /></span> ... <span class="i2"> Threw him into a swoon;<br /></span> ... <span class="i0">Where he tumbed and broke into bits.<br /></span> ... </div> ... </div>
The abstraction of a "line" which would ideally be displayed on one line of a small device, but with extra wrap-indent when it cannot, seems extremely useful (for those machines on which it works). A couple of questions though: 1. Is there an obvious reason not to use: div.i0 {margin-left: 0em; padding-left: 3em; text-indent: -3em;}, etc and <div class="i0">There was a young man...</div>, etc?
No. According to the HTML spec, "[The <DIV> and <SPAN>] elements define content to be inline (SPAN) or block-level (DIV) but impose no other presentational idioms on the content." Other than hiding a section of text ("display:none") there is no reason to set the display attribute of either element; just use the correct one to begin with.
Somehow using a tag which is inherently a block seems more simple and obvious than using a span with {display: block;}
True.
2. Is there an unstated reason/convention for describing an indent of 1em as class=i2, 2em as class=i4, etc? This is not a trick question, I ask from curiosity/ignorance.
While clearly ugly, the use of non-breaking spaces to offset lines is more flexible that using CSS. I tend to avoid CSS for styling in those instances where the presentation /must not/ vary. _______________________________________________ gutvol-d mailing list gutvol-d@lists.pglaf.org http://lists.pglaf.org/mailman/listinfo/gutvol-d

On 2/27/2012 1:28 PM, don kretz wrote:
Of course you realize that all this is way beyond what should be expected of a person who is proofing and marking up text.
No, I don't realize that at all. I believe that these kind of markup rules can easily be reduced to a set of simple instructions, and I'm quite confident that your average volunteer is completely capable of following simple instructions. In any case, it's not my problem. /My/ problem is developing a simple, effective, and powerful way of marking text for use as a master format. /You/ are the one that want's to build a proofing system. That's a great goal. Good luck with it.

Assuming the proofers are the ones who are supposed to provide the text encoded in the master format, we may have more to talk about. If your position is only that a master format can be provided with sufficient coverage and precision to generate multiple final formats, I'm sure that's true. That leaves one important gap in the process, however. On Tue, Feb 28, 2012 at 5:10 PM, Lee Passey <lee@novomail.net> wrote:
On 2/27/2012 1:28 PM, don kretz wrote:
Of course you realize that all this is way beyond what should be
expected of a person who is proofing and marking up text.
No, I don't realize that at all.
I believe that these kind of markup rules can easily be reduced to a set of simple instructions, and I'm quite confident that your average volunteer is completely capable of following simple instructions.
In any case, it's not my problem. /My/ problem is developing a simple, effective, and powerful way of marking text for use as a master format. /You/ are the one that want's to build a proofing system.
That's a great goal. Good luck with it.
______________________________**_________________ gutvol-d mailing list gutvol-d@lists.pglaf.org http://lists.pglaf.org/**mailman/listinfo/gutvol-d<http://lists.pglaf.org/mailman/listinfo/gutvol-d>

Can you show me some credible specific examples? I can't think of anything in guiguts that I know of that helps answer the question. But I'm only a novice. On Tue, Feb 28, 2012 at 6:32 PM, James Adcock <jimad@msn.com> wrote:
*>*Of course you realize that all this is way beyond what should be****
expected of a person who is proofing and marking up text.****
I believe it is built into guiguts, and thus PP’ers only need to see it used in some other book and ape what they see there.****
** **
_______________________________________________ gutvol-d mailing list gutvol-d@lists.pglaf.org http://lists.pglaf.org/mailman/listinfo/gutvol-d

Can you show me some credible specific examples? I can't think
of anything in guiguts that I know of that helps answer the question. Well, I'm no guiguts expert, but the poem CSS coding keeps showing up in PG books which do not even *have* poems, and I cannot imagine why that would be the case unless it is guiguts which is emitting the CSS? For example: http://www.gutenberg.org/files/38992/38992-h/38992-h.htm I would think that *some* program must be generating the CSS because humans typically will not write code that they do not use. And I do not know of a program commonly used for this kind of stuff in DP land other than guiguts?

Hi Don, A very true and sad statement. That is why decent guidelines are needed, inorder to lead the blind. regards Keith. Am 27.02.2012 um 21:28 schrieb don kretz:
Of course you realize that all this is way beyond what should be expected of a person who is proofing and marking up text.
On Mon, Feb 27, 2012 at 11:06 AM, Lee Passey <lee@novomail.net> wrote: On Mon, February 27, 2012 3:45 am, Robert Gibbins wrote:
Jim Adcock wrote on Fri Feb 17 (somewhat precised by me):
... the common PG/DP approach which I think is being generated by guiguts is not bad: ... ... <style type="text/css"> ... .poem span.i0 {display: block; margin-left: 0em; padding-left: 3em; text-indent: -3em;} ... .poem span.i2 {display: block; margin-left: 1em; padding-left: 3em; text-indent: -3em;} ... .poem span.i4 {display: block; margin-left: 2em; padding-left: 3em; text-indent: -3em;} ... </style> ... ... <div class="poem"> ... <div class="stanza"> ... <span class="i0">There was a young man of St. Kitts,<br /></span> ... <span class="i0">Who was very much troubled with fits;<br /></span> ... <span class="i2"> The eclipse of the moon<br /></span> ... <span class="i2"> Threw him into a swoon;<br /></span> ... <span class="i0">Where he tumbed and broke into bits.<br /></span> ... </div> ... </div>
The abstraction of a "line" which would ideally be displayed on one line of a small device, but with extra wrap-indent when it cannot, seems extremely useful (for those machines on which it works). A couple of questions though: 1. Is there an obvious reason not to use: div.i0 {margin-left: 0em; padding-left: 3em; text-indent: -3em;}, etc and <div class="i0">There was a young man...</div>, etc?
No. According to the HTML spec, "[The <DIV> and <SPAN>] elements define content to be inline (SPAN) or block-level (DIV) but impose no other presentational idioms on the content." Other than hiding a section of text ("display:none") there is no reason to set the display attribute of either element; just use the correct one to begin with.
Somehow using a tag which is inherently a block seems more simple and obvious than using a span with {display: block;}
True.
2. Is there an unstated reason/convention for describing an indent of 1em as class=i2, 2em as class=i4, etc? This is not a trick question, I ask from curiosity/ignorance.
While clearly ugly, the use of non-breaking spaces to offset lines is more flexible that using CSS. I tend to avoid CSS for styling in those instances where the presentation /must not/ vary. _______________________________________________ gutvol-d mailing list gutvol-d@lists.pglaf.org http://lists.pglaf.org/mailman/listinfo/gutvol-d
_______________________________________________ gutvol-d mailing list gutvol-d@lists.pglaf.org http://lists.pglaf.org/mailman/listinfo/gutvol-d
participants (7)
-
don kretz
-
James Adcock
-
Jana Srna
-
Jim Adcock
-
Keith J. Schultz
-
Lee Passey
-
Robert Gibbins