[sword-devel] How to make new module
Jerry Hastings
sword-devel@crosswire.org
Thu, 31 Aug 2000 09:55:30 -0700
Right, the files don't get used. But VerseKey::otbks[], VerseKey::otcpss[],
VerseKey::ntbks[] and VerseKey::ntcps[] in canon.h are the data of the
*.bks and *.cps files reduced to record numbers instead of offset
bytes--the same data divided by four for *bks[] and divided by six for *cps[].
Your Idea of looking for files to use if present would make it ease to
support other verse systems. You could even have more than one set of
indexes for a given translation. The Douay could have dr_ot.bks, dr_ot.cps
and can_ot.bks, can_ot.cps. The dr* files could map native dr verse
references while the can* files could map KJV style references. Using the
dr files one could have access to non-canonical books. And references from
KJV based commentaries could correctly locate canonical verses by the can*
files.
Jerry
At 12:08 AM 8/31/2000 -0700, Chris Little wrote:
>No, the bks and cps files don't get used at all. The data for the KJV's
>bks and cps files is contained in a static array (it's in the canon.h
>file). It's simpler to implement, but it requires that all your modules
>have the same number of verses per chapter per book. That's why we only
>support KJV verse numbering. Even when bks/cps files are available, the
>static arrays get used, though it would be cool to add support for reading
>the files if present for more versatility.
>
>--Chris