Hello,

I recently noticed this bug when formatting a Bible to OSIS:
https://tracker.crosswire.org/browse/MODTOOLS-8 I noticed both NET and WEB have 
the same issue (book group title appears at the end of Malachi and/or 
Apocrypha).

I put together a patch which works for me. It only moves the bookGroup start 
div tag for the New Testament and following title from the end of the ot​ file 
to the beginning of nt. This results in an OOPS message in the debug log, but 
it doesn't seem to have any unwanted effect on the output.

-Jesse
diff --git utilities/osis2mod.cpp utilities/osis2mod.cpp
index 38efa560..9f034a23 100644
--- utilities/osis2mod.cpp
+++ utilities/osis2mod.cpp
@@ -886,6 +886,14 @@ bool handleToken(SWBuf &text, XMLTag token) {
 
 		// Now consider everything else.
 
+		if (tokenName == "div" && typeAttr == "bookGroup") {
+			if (debug & DEBUG_OTHER) {
+				cout << "DEBUG(FOUND): Found bookGroup div, saving following material for book intro" << endl;
+			}
+			inBookIntro = true;
+			return false;
+		}
+
 /*
 		// "majorSection" is code for the Book 1-5 of Psalms // This is incorrect assumption - majorSection can appear in any large book and can start and end inside chapters
 		if (tokenName == "div" && typeAttr == "majorSection") {
_______________________________________________
sword-devel mailing list: sword-devel@crosswire.org
http://crosswire.org/mailman/listinfo/sword-devel
Instructions to unsubscribe/change your settings at above page

Reply via email to