[sword-devel] Psalm 3.1 returns canonical title

Chris Burrell chris at burrell.me.uk
Sun Jul 14 12:54:32 MST 2013

This affects me in quite a number of different ways. All of which have to
do with parallel displaying, comparing, interlinears, etc.

I had assumed that Psalm titles should fall under the verse 0 construct.
And as a result it meant I could map verse 0 in the NRSV versification to 0
(via the KJV) to verse 1 in the Leningrad versification. My pre-supposition
was that anything from chapter-start to verse 1 should fall under the verse
0 construct.

*So, if I ask for a full chapter, *although the canonical content isn't
part of a 'verse' (or even part of the div marking verse.0), I can remember
the fact I've seen verse 0, and therefore consider anything before verse 1
(like the Psalm heading) to be in verse 0. This then means that we get very
nice mappings from Psalms headers to Leningrad verse 1.

*For a single verse, *there is no osisID on any fragment before the verse,
and therefore I'd have to write (ugly?) code to try and map it to the
Leningrad verse 1.

>From the sounds of it, I'm exploiting something that wasn't by design, but
something that makes parallel displays look so much better.

I'm open to ideas? I'd like to get to a position when we can address
pre-verse content separately to the verse it is contained in.

On 14 July 2013 20:13, DM Smith <dmsmith at crosswire.org> wrote:

> This is in reply to this and another thread on the same subject. And
> cross-posting to JSword-devel to which this and the other post belong.
> First, Verse 0 is a SWORD construct indicating non-canonical material
> standing before the first verse, whether of the testament, book or chapter.
> It should never have canonical material in it. It was originally used for
> just headings and typically only has one or more titles, but more generally
> applies to any introductory material. It is possible for an author of OSIS
> to mark introductory material as canonical. However that is a bad practice.
> To my knowledge, Psalm headings/titles and book colophons are the only
> canonical material outside of verses. The difference between the two is
> that the Psalm title needs to appear before the verse number. We use a
> special construct for this called the "preverse" div, which is prepended to
> the canonical verse content. The attributes on the title element are taken
> from the OSIS source. This  preverse div is part of the stored entry for
> the verse.
> A colophon merely appears after the last verse of the book and has no
> specific delineation from the last verse. They are merely appended to that
> verse when the OSIS is converted to a module.
> I could modify osis2mod to have an osisID, based upon the verse that it
> precedes. But the reason that you don't find an osisID on the material that
> stands before the verse is that the authored OSIS does not have one.
> BTW, in the sample below the wrapping div, the x-gen entries and the verse
> begin/end are created by JSword, but otherwise the content is exactly what
> comes out of the OSIS module.
> I'm not clear on where you are going with this line of questions. It might
> help if we knew what you were trying to accomplish.
> In Him,
>         DM
> On Jul 14, 2013, at 5:28 AM, Chris Burrell <chris at burrell.me.uk> wrote:
> > Hello
> >
> > In the ESV, if we simply look up one verse, we get the canonical title.
> However, the canonical title is not attached to any verse. There is also no
> previous osisID in the fragment for which we can determine the fact it's
> part of verse 0.
> >
> > <div>
> >   <title type="x-gen">Psalms 3:1</title>
> >   <div type="x-milestone" subType="x-preverse" sID="pv2789" />
> >   <div sID="gen7559" type="section" />
> >   <title>Save Me, O My God</title>
> >   <title canonical="true" type="psalm" subType="x-preverse">
> >     A Psalm of David,
> >     <note n="n" osisID="Ps.3.1!crossReference.n" osisRef="Ps.3.1"
> type="crossReference">
> >       See
> >       <reference osisRef="2Sam.15.14-2Sam.15.17">2 Sam.
> 15:14-17</reference>
> >     </note>
> >     when he fled from Absalom his son.
> >   </title>
> >   <lg sID="gen7560" />
> >   <div type="x-milestone" subType="x-preverse" eID="pv2789" />
> >   <verse osisID="Ps.3.1">
> > ...
> > </div>
> >
> > Any ideas if this is a bug (perhaps this is similar to a thread I
> started yesterday).
> > Presumably the canonical should not be output, or it should be output
> but within a Psalm.3.0 div (or at least in proximity of a div Psalm.3.0 tag)
> > Chris
> >
> > _______________________________________________
> > sword-devel mailing list: sword-devel at crosswire.org
> > http://www.crosswire.org/mailman/listinfo/sword-devel
> > Instructions to unsubscribe/change your settings at above page
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.crosswire.org/pipermail/sword-devel/attachments/20130714/9bf31e9e/attachment.html>

More information about the sword-devel mailing list