[sword-devel] usfm to osis converter...
Ryan
adyeths at gmail.com
Fri Jul 31 08:09:38 MST 2015
On Fri, 2015-07-31 at 08:19 +0100, Peter von Kaehne wrote:
> The pitfalls of all scripts I have seen so far are around the
> recognition of "end of construct" in USFM - end of verse, section etc.
> which is not explicit. This, combined with OSIS milestones has caused
> a lot of grief over the years.
>
> As a result we usually had to rely on some bad stuff with massive
> regexes to reorder tags.
>
> What are you doing in this matter?
Making sure things like milestone chapter and verse end markers don't
get put in the wrong place is one of the more challenging parts of the
conversion. I have included some code to try to make sure these end
markers are moved to where they belong and don't end up getting put at
the beginning of a new section when they should be put at the end of a
previous section, though. There may be more work that needs to be done
with regards to this. I would have to see examples of where my script
fails in order to do more in this area though.
>
> Wrt xrefs- I have always had a separate script using the Sword library
> to parse the xrefs and insert these into the OSIS. I do not think you
> can do much about this as every language will have different xref
> conventions - both names of books and, crucially, often different use
> of punctuation as separators.
>
This would be why I haven't done anything with xrefs. I am sure I don't
possess the knowledge required to handle them properly. :)
More information about the sword-devel
mailing list