<div dir="ltr">Troy,<div><br></div><div>There seems to be an issue in the implementation of the filter for this. I'm currently getting the following from "lookup":</div><div><br></div><div>
<p class=""> [ Preverse ]</p>
<p class=""> 0 = <div canonical="true" sID="gen30107" subType="x-SH" type="section"/><title>Bartimaeus Receives His Sight</title> <div sID="gen30108" type="x-p"/></p>
<p class=""> module->renderText(heading[0]) = <h3><h3>Bartimaeus Receives His Sight</h3></p>
<p class=""><br></p>
<p class=""></h3></p><p class=""><br></p><p class="">The engine's filter is already wrapping the render text in double-h3 tags, so any applications doing that will end up triple-wrapping.</p><p class="">--Greg</p>
</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Apr 15, 2014 at 4:52 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">Dear all SWORD frontend developers.<br>
<br>
In the 1.7 codebase we introduced the new concept of preverse divs instead of simply a set of preverse titles. This was discussed at length over the years and we decided to move in this direction with everyone' consent, hopefully.<br>
<br>
We had an inconsistency in 1.7.[0-2] which I have just fixed and which you probably need to worry about:<br>
<br>
<br>
The problem:<br>
<br>
Previous, we were including preverse titles in the entryAttributes under:<br>
<br>
["Heading"]["Preverse"]["0" ... n] = "Some Title"<br>
<br>
You were probably wrapping this in a nice <h2> or something and being done with it.<br>
<br>
In the new world of preverse divs which can contain anything-- not just titles, this would look like this:<br>
<br>
["Heading"]["Preverse"]["0" ... n] = "<title>Some Title</title>"<br>
<br>
This was inconsistent. The former relied on the frontend to set this apart as a title. The later has the <title> tag included in whatever might be a title in the preverse material.<br>
<br>
The problem is that most of you (and me) didn't change any of our frontend code to handle the move to preverse div. We tried to make this as easy of a transition as possible and thought we did, but not quite good enough.<br>
<br>
As it stands now, for older modules, you're probably rendering something like:<br>
<br>
<h3>Some Title</h3><br>
<br>
But for newer modules you are probably rendering something like:<br>
<br>
<h3><h3>Some Title</h3></h3><br>
<br>
You were adding your own markup to highlight these always as titles, and in the new world, the highlighting is done for you, if it is indeed a title (the OSIS <title> tag is actually in the body of the material and will get rendered as all other <title> elements).<br>
<br>
A bug fix, which I've just committed and will go out in 1.7.3 shortly, will make these consistent. When processing headings, I am looking for old preverse title modules and I now preserve the containing "<title>" element. This will make them act the same as the newer preverse div modules and both will appear consistently as:<br>
<br>
["Heading"]["Preverse"]["0" ... n] = "<title>Some Title</title>"<br>
<br>
<br>
SUMMARY: In the new preverse div world, you should never add your own markup around the preverse material which assumes the entire content is a title. Simply remove your added markup and you should be good.<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></div><br></div>