Hi Troy/Greg,<br><br><div class="gmail_quote">On Mon, Sep 17, 2012 at 11:49 PM, Troy A. Griffitts <span dir="ltr"><<a href="mailto:scribe@crosswire.org" target="_blank">scribe@crosswire.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
3 brief points.<br>
<br>
The HTML filter set is old and no one I know of uses this filter set. HTMLHREF, WEBIF, and XHTML are the 3 filter sets I know which are in use today. I've started to switch SWORDWeb from WEBIF to the XHTML filter set. Once this is done, I wouldn't mind deprecating both the WEBIF and HTML filter sets. Eventually, I'd like to deprecate the HTMLHREF filter set, leaving only one (XHTML) filter set we all use in common, but I know xiphos, and others are still using this as the primary HTML output filter set.<br>
</blockquote><div><br></div><div>I know BPBible uses HTMLHREF, though we derive from it and make many changes to the output accordingly.</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
You should be seeing <!P><br /> output from this <div type="paragraph"> construct, not simply <!P>. Again, let's remove the <!P> if xiphos no longer needs it. <br /> is certainly valid, even if not necessarily the most desirable XHTML output for a paragraph division.<br>
</blockquote><div><br></div><div>BPBible has in several places of the code calls to:</div><div><br></div><div> data.replace("<!P>", "</p><p>")</div><div><br></div><div>That is all the processing we seem to do on it.</div>
<div><br></div><div>Jon</div><div><br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5"><br>
On 09/16/2012 01:54 AM, Greg Hellings wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
On Sat, Sep 15, 2012 at 5:11 PM, Troy A. Griffitts <<a href="mailto:scribe@crosswire.org" target="_blank">scribe@crosswire.org</a>> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Greg,<br>
<br>
Thank you for posting the issue. I'm still really having a tough time<br>
understanding the problem. I know we've been crossing on IRC, so I'm not<br>
sure if you are seeing any of my responses to you there.<br>
<br>
</blockquote>
Anything you say while my Nick is in the channel is saved by ZNC and<br>
bounced to me the next time I login, up until I manually clear the<br>
logs. So yes, I've been getting the messages you've sent.<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
We have code to hand these divs and not pass them through, as shown here:<br>
<br>
<a href="http://crosswire.org/svn/sword/trunk/src/modules/filters/osisxhtml.cpp" target="_blank">http://crosswire.org/svn/<u></u>sword/trunk/src/modules/<u></u>filters/osisxhtml.cpp</a><br>
<br>
search for "paragraph" and it should be like the 2nd or 3rd hit, but there<br>
is a comment which specifically shows your construct of <div eID=""<br>
type="paragraph" /><br>
<br>
The end result is that this get's output as <!P><br /><br>
<br>
If you look below in your ./lookup output, you will see this exact output.<br>
</blockquote>
That output is the result of FMT_WEBIF rendering. I'm not sure exactly<br>
what that is, so I can't speak to that.<br>
<br>
When I rebuild with HTMLHREF and XHTML I get <!/P>. This makes fine<br>
for HTMLHREF according to what Chris has said elsewhere and you state<br>
below as that is intended for use by GS/Xiphos. That does not make for<br>
acceptable XHTML - it is not valid.<br>
<br>
When I rebuild lookup with FMT_HTML I am still seeing the div tag<br>
passed through untouched. That is not valid HTML as discussed earlier<br>
in this thread unless we're hoping to target a very strongly<br>
discouraged construct of an older version of HTML.<br>
<br>
Strangely, I can't get the output of Diatheke and lookup to sync up on<br>
the XHTML results.<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
The <!P> was added for/by gnomesword years ago and can be taken out if you<br>
do a grep through the xiphos code and find it not needed any longer. I'm<br>
not sure why it was added.<br>
<br>
But, the end result is that we do process this construct and should never<br>
pass it through. If Bibletime get's it to passed through, then they are not<br>
using our filters, either because they are using their own filter distinct<br>
filter set, or their filter set overrides this processing and doesn't accept<br>
our default processing.<br>
</blockquote>
The issue in BibleTime has already been taken care of. This only came<br>
to light because the offending <div> tags were in the preverse<br>
material which BibleTime does not pass through any filters but instead<br>
simply strips tags out of the raw text. I can't pretend to know what<br>
that is a good idea, but I'm not interested in that - only in getting<br>
my module looking correct.<br>
<br>
I figured I'd point out the discrepancies between SWORD's usages and<br>
the specs in the meantime. To that point, XHTML and HTML are still<br>
generating invalid output according to lookup.<br>
<br>
--Greg<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
If you point me to an svn or git or whatever link to the Bibletime Render<br>
Filter which processes OSIS, I'd be happy to have a look.<br>
<br>
Troy<br>
<br>
<br>
On 09/15/2012 06:56 PM, Greg Hellings wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
To emphasize that we have an issue here, in the SWORD filters, here is<br>
the output from diatheke with HTML, HTMLHREF and XHTML (which support<br>
I just hacked in now in order to test).<br>
<br>
greg@Gateway08:~/Source/sword/<u></u>build (master)$ !diath<br>
diatheke -b TKE -o h -f HTMLHREF -k Gen 1:2<br>
Genesis 1:2: Elaboya kayawomele naari kayanna dhego. Yaali mahinje<br>
ooddiiha ni owoopiha yahuruwedhiwe ni yiihi. Muneba wa Mulugu<br>
waviravira vadhulu va mahinje, osasanyedhelaga. <!/P><br /><br>
(TKE)<br>
greg@Gateway08:~/Source/sword/<u></u>build (master)$ diatheke -b TKE -o h -f<br>
HTML -k Gen 1:2<br>
<meta http-equiv="content-type" content="text/html;<br>
charset=UTF-8">Genesis 1:2: Elaboya kayawomele naari kayanna dhego.<br>
Yaali mahinje ooddiiha ni owoopiha yahuruwedhiwe ni yiihi. Muneba wa<br>
Mulugu waviravira vadhulu va mahinje, osasanyedhelaga. <div<br>
eID="gen11" type="paragraph"/><br /><br>
(TKE)<br>
greg@Gateway08:~/Source/sword/<u></u>build (master)$ diatheke -b TKE -o h -f<br>
XHTML -k Gen 1:2<br>
Genesis 1:2: Elaboya kayawomele naari kayanna dhego. Yaali mahinje<br>
ooddiiha ni owoopiha yahuruwedhiwe ni yiihi. Muneba wa Mulugu<br>
waviravira vadhulu va mahinje, osasanyedhelaga. <div eID="gen11"<br>
type="paragraph"/><br>
(TKE)<br>
<br>
All three are outputting the same verse from the same module. HTML and<br>
XHTML are outputting <div eID="gen11" type="paragraph"/> which is what<br>
the module has in its rawest form. HTMLHREF outputs <!/P> which is not<br>
valid anything. There are other, odd, differences between the three<br>
but none of those are germane to this discussion, it would seem to me.<br>
<br>
$ ./examples/cmdline/lookup TKE Gen.1.2<br>
==Raw=Entry===============<br>
Genesis 1:2:<br>
Elaboya kayawomele naari kayanna dhego. Yaali mahinje ooddiiha ni<br>
owoopiha yahuruwedhiwe ni yiihi. Muneba wa Mulugu<note n="1">1.2*<br>
<catchWord>Muneba wa Mulugu</catchWord> naari wi «pevo yuulubale.»<br>
Mulugu ohukalana muneba mmohi oneethanihu «Muneba Woweela.» Muneba<br>
Woweela ohukamihedha voopaddusiwa elabo. Mwaana a Mulugu, Yesu<br>
Kirisitu, teto ohukamihedha moopaddusa (Zhuwawu 1.1-3; aKolose 1.16;<br>
aHeberi 1.2.)</note> waviravira vadhulu va mahinje, osasanyedhelaga.<br>
<div eID="gen11" type="paragraph"/><br>
==Render=Entry============<br>
.divineName { font-variant: small-caps;<br>
} .wordsOfJesus {color: red; }<br>
Elaboya kayawomele naari kayanna dhego. Yaali mahinje ooddiiha ni<br>
owoopiha yahuruwedhiwe ni yiihi. Muneba wa Mulugu waviravira vadhulu<br>
va mahinje, osasanyedhelaga. <!/P><br /><br>
==========================<br>
Entry Attributes:<br>
<br>
[ Footnote ]<br>
[ 1 ]<br>
body = 1.2* <catchWord>Muneba wa Mulugu</catchWord> naari<br>
wi «pevo<br>
yuulubale.» Mulugu ohukalana muneba mmohi oneethanihu «Muneba<br>
Woweela.» Muneba Woweela ohukamihedha voopaddusiwa elabo. Mwaana a<br>
Mulugu, Yesu Kirisitu, teto ohukamihedha moopaddusa (Zhuwawu 1.1-3;<br>
aKolose 1.16; aHeberi 1.2.)<br>
n = 1<br>
<br>
On Fri, Sep 14, 2012 at 7:15 PM, Chris Little <<a href="mailto:chrislit@crosswire.org" target="_blank">chrislit@crosswire.org</a>><br>
wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<br>
On 09/14/2012 01:02 PM, Greg Hellings wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
So I've been debugging a module display problem in BibleTime. I<br>
mentioned it on IRC with Troy the other day but we weren't able to<br>
connect at the same time to discuss further. The issue has to do with<br>
paragraph tags - in osis2mod these tags are being converted from <p><br>
to <div sID="someid" type="paragraph" />.<br>
</blockquote>
This is extraordinarily bad. This is a change in semantics, because <p><br>
and<br>
<div type="paragraph"> are not semantically equivalent.<br>
<br>
<p> marks the type of paragraph we all probably think of first:<br>
generally, a<br>
chunk of text with newlines before and after.<br>
<br>
<div type="paragraph"> marks a formal division within a text that happens<br>
to<br>
be identified as a 'paragraph' and may consist of multiple <p>-type<br>
paragraphs. Examples of these divisions are found in many laws and the<br>
Catechism of the Catholic Church (which does exist in OSIS form). Here's<br>
part 1, section 1, chapter 1, article 1, paragraph 1 of the CCC:<br>
<a href="http://www.vatican.va/archive/ENG0015/__P16.HTM" target="_blank">http://www.vatican.va/archive/<u></u>ENG0015/__P16.HTM</a>. As you can see, it<br>
consists<br>
of many <p>-type paragraphs but is a single <div type="paragraph">-type<br>
paragraph.<br>
<br>
Abhorrent though I consider milestoned <p/>, I think I would much prefer<br>
to<br>
see us map <p>...</p> to <p sID=""/>...<p eID=""/> than see us clobber<br>
the<br>
semantics of a defined <div> type.<br>
<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Thus, osis2mod is in violation of the suggested XML best practice by<br>
creating a non-EMPTY tag as self-closing but this is seemingly pretty<br>
common in the OSIS world. Furthermore our filters are producing<br>
invalid (or very strongly discouraged) HTML as per every still-in-use<br>
version of the specs (HTML4, XHTML, HTML5). As such, I'm of the<br>
opinion that this represents a bug in SWORD - at the very least in the<br>
filters that permit empty, self-closing div tags to slip through what<br>
are supposedly HTML outputs. Do others agree or disagree on this?<br>
</blockquote>
I'm of the opinion that our OSIS is generally fine, meaning we should go<br>
ahead and keep allowing self-closing OSIS tags if possible (as input and<br>
output from osis2mod and as content of modules not produced by osis2mod).<br>
This is just a recommendation and specifically a recommendation for the<br>
purpose of aiding processing with legacy SGML tools, which I can't see us<br>
doing and don't personally care about. (The semantic violation noted<br>
above<br>
is a bug in my mind, but that issue is orthogonal.)<br>
<br>
I would agree that the filter output is buggy if we're generating<br>
disallowed<br>
tag forms. OSIS <div> and <p> would need to be translated to their<br>
correct,<br>
non-self-closing HTML forms. Beyond those two, I can't think of any tags<br>
that have the same form & general semantics in both OSIS & HTML.<br>
<br>
--Chris<br>
<br>
<br>
<br>
______________________________<u></u>_________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://www.crosswire.org/mailman/listinfo/sword-devel" target="_blank">http://www.crosswire.org/<u></u>mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</blockquote>
______________________________<u></u>_________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://www.crosswire.org/mailman/listinfo/sword-devel" target="_blank">http://www.crosswire.org/<u></u>mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</blockquote>
<br>
<br>
______________________________<u></u>_________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://www.crosswire.org/mailman/listinfo/sword-devel" target="_blank">http://www.crosswire.org/<u></u>mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</blockquote>
______________________________<u></u>_________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://www.crosswire.org/mailman/listinfo/sword-devel" target="_blank">http://www.crosswire.org/<u></u>mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</blockquote>
<br>
<br>
______________________________<u></u>_________________<br>
sword-devel mailing list: <a href="mailto:sword-devel@crosswire.org" target="_blank">sword-devel@crosswire.org</a><br>
<a href="http://www.crosswire.org/mailman/listinfo/sword-devel" target="_blank">http://www.crosswire.org/<u></u>mailman/listinfo/sword-devel</a><br>
Instructions to unsubscribe/change your settings at above page<br>
</div></div></blockquote></div><br>