Print

Print


On Wed, 12 Aug 2015 16:28:47 +0200, Frederik Elwert <[log in to unmask]> wrote:
Hi  James, Frederik, and others.
Thanks a lot for participation.

>> If this is a list, then it is a list of items. That some of those items
>> contain one or more paragraphs should not be an issue.  You can do:
>> 
>> <list>
>>    <item>This is item #1, just some phrase level text</item>
>>    <item>This is item #2, just some phrase level text</item>
>>    <item>
>>        <p>This is item #3 which is made up of multiple paragraphs</p>
>>        <p>And here is a paragraph explaining that in more detail.</p>
>>   </item>
>>   <item> Oh and here is item # 3</item>
>> </list>
>
>I think the issue was something like this:
>
>  <p>There are three kinds of things:</p>
>  <list>
>    <item>There is thing #1.</item>
>    <item>There is thing #2.</item>
>    <p>Some argue that #1 and #2 are actually the same thing.</p>
>    <item>Then there is thing3.</item>
>  </list>
>
>This is forbidden, but it would be semantically unsound to add the
>paragraph to one of the list items.
>
I agree with Frederik and the case that James propose seems to be different.

>I think one way to solve this would be to use multiple lists. The
>problem is then expressing that the two lists are actually one list. I
>*think* one might go with @next/@prev, but I would be curious to hear
>oppinions on that:
>
>  <p>There are three kinds of things:</p>
>  <list xml:id="list1-part1" next="#list1-part2">
>    <item>There is thing #1.</item>
>    <item>There is thing #2.</item>
>  </list>
>  <p>Some argue that #1 and #2 are actually the same thing.</p>
>  <list xml:id="list1-part2" prev="#list1-part1">
>    <item>Then there is thing3.</item>
>  </list>
>
Although using the multiple lists sounds logical but it seems to be somewhat missusing and I think if it's logically true then it sould be valid without such tricks!
>>> 2- As I can understand from the GuideLines, we can't put any <p>
>>> element after some <div> elements within a <div>, but in some cases we
>>> may face with a case in which a division may apear after some <p>
>>> elements and then we have some <p> elements. How we can resolve such a
>>> case in TEI?
>> 
>> If I'm understanding you correctly what you are encountering is the need
>> for the tessellation of div elements once one has been used.
>> 
>> You may have:
>> <body>
>>    <p>para 1</p>
>>    <p>para2</p>
>>    <div>
>>        <head>Section 1</head>
>>      <p>para 1 of section 1</p>
>>      <p>para 2 of section 1</p>
>>    </div>
>>     <!-- at this point you are not allowed any more bare paragraphs
>> because once you are dividing your document into divisions, everything
>> else is just considered a division.  It may be a division without a
>> *heading*. However, ask yourself what causes you to believe it is a
>> division (usually headings) or not part of the previous division. -->
>>   <div>
>>        <head> Section 2</head>
>>    <p>Para 1 of section 2</p>
>>    </div>
>>    <div rend="shaded">
>>       <p> This is a third division that has no heading. Let's say I can
>> tell it is because in print it was background-shaded differently.</p>
>>     </div>
>> </body>
>
>I think there are good reasons to assume that such a structure might exist:
>
>  <div>
>    <head>Chapter 1</head>
>    <p>The grandfather told his grandchildren a story.</p>
>    <div>
>      <p>A prince and a princess met.</p>
>      <p>And they lived happily ever after.</p>
>    </div>
>    <p>The grandchildren had already fallen asleep.</p>
>  </div>
>
>Semantically, this makes perfect sense. (Okay, one might argue for some
>quote-like encoding for the story, but I think there are also cases
>where that does not apply.) There are many cases where we do have
>semantic markers, such as a specific formula, that denote the ending of
>a division, even without headings or the like. (We did in fact encounter
>this within Buddhist scriptures.)
>
>One can solve this in the way you suggest, but I think it is more of a
>workaround than a coherent content model. The TEI guidelines do in fact
>allow <p> and <div> on the same level, but only with <p> *before* <div>,
>not after. But given this example, why would I have to encapsulate the
>last <p> into a (superfluous) <div>, while I don’t have to do that for
>the first <p>?

Of course, we face with some cases that we have only one paragraph. Although treating it as another division is acceptable, but why we should do so when we can treat it the same as the leadi ng paragraphs? As I noted earlier, I'm trying to learn the philosophy behind the content model and then applying it in practice.
Best wishes, Saeed