[sword-devel] references
Chris Little
chrislit at crosswire.org
Mon Jul 26 02:00:46 MST 2010
On 7/26/2010 12:30 AM, Peter von Kaehne wrote:
> Many thanks Chris,
>
> I think this answers my problem:
>> E.g.:
>> <reference osisRef="Exod.5.2">2. Mose 5,2</reference>
> The problem then is that usfm2osis.pl does not (yet) create such
> references with my texts. I presume I need to do some work to it.
> Currently the references look like
>
> <reference>2. Mose 5,2</reference>
Right, usfm2osis.pl doesn't have the data necessary to parse & interpret
localized references. I usually a followup pass (once I'm happy with the
rest of the conversion) that looks for every instance of
<reference>...</reference> and uses it as input to vs2osisref.
vs2osisref should have an option to take a locale value, so it can
interpret localized references. Then it will use Sword itself to parse
references individually. Since vs2osisref has to be executed separately
for every reference in a work, it can take a very long time to complete
this. (I've seen upwards of 15-20 minutes for some commentaries with
lots of references.)
If you need, I can write a little script to scan an OSIS doc and call
vs2osisref, but it may or may not be entirely OS-independent. Since it
requires Sword and requires calling an outside executable, I'd rather
not integrate this directly in usfm2osis.pl.
--Chris
More information about the sword-devel
mailing list