aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--doc/ads/de/sword_cd.sxwbin17493 -> 17609 bytes
-rw-r--r--doc/ads/de/sword_cd_cover.sxdbin32274 -> 32386 bytes
-rw-r--r--src/modules/filters/gbfosis.cpp39
-rwxr-xr-xusrinst.sh14
4 files changed, 44 insertions, 9 deletions
diff --git a/doc/ads/de/sword_cd.sxw b/doc/ads/de/sword_cd.sxw
index e116513..1d0c908 100644
--- a/doc/ads/de/sword_cd.sxw
+++ b/doc/ads/de/sword_cd.sxw
Binary files differ
diff --git a/doc/ads/de/sword_cd_cover.sxd b/doc/ads/de/sword_cd_cover.sxd
index 45b19f4..8b8ed12 100644
--- a/doc/ads/de/sword_cd_cover.sxd
+++ b/doc/ads/de/sword_cd_cover.sxd
Binary files differ
diff --git a/src/modules/filters/gbfosis.cpp b/src/modules/filters/gbfosis.cpp
index a921225..ac41e5b 100644
--- a/src/modules/filters/gbfosis.cpp
+++ b/src/modules/filters/gbfosis.cpp
@@ -50,6 +50,7 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
std::string tmp;
bool suspendTextPassThru = false;
bool keepToken = false;
+ bool handled = false;
len = strlen(text) + 1; // shift string to right of buffer
if (len < maxlen) {
@@ -82,7 +83,7 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
keepToken = false;
suspendTextPassThru = false;
newWord = true;
-
+ handled = false;
while (wordStart < (text+maxlen)) {
// if (strchr(" ,;.?!()'\"", *wordStart))
@@ -101,6 +102,7 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
// pushString(buf, "<reference work=\"Bible.KJV\" reference=\"");
suspendTextPassThru = true;
newText = true;
+ handled = true;
}
else if (!strncmp(token, "/scripRef", 9)) {
tmp = "";
@@ -108,6 +110,7 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
pushString(&to, convertToOSIS(tmp.c_str(), key));
lastspace = false;
suspendTextPassThru = false;
+ handled = true;
}
// Footnote
@@ -116,17 +119,39 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
pushString(&to, "<note type=\"x-StudyNote\">");
newText = true;
lastspace = false;
+ handled = true;
}
else if (!strcmp(token, "Rf")) {
pushString(&to, "</note>");
lastspace = false;
+ handled = true;
+ }
+ // Italics assume transchange
+ if (!strcmp(token, "FI")) {
+ pushString(&to, "<transChange changeType=\"added\">");
+ newText = true;
+ lastspace = false;
+ handled = true;
+ }
+ else if (!strcmp(token, "Fi")) {
+ pushString(&to, "</transChange>");
+ lastspace = false;
+ handled = true;
+ }
+ // Paragraph break. For now use empty paragraph element
+ if (!strcmp(token, "CM")) {
+ pushString(&to, "<p />");
+ newText = true;
+ lastspace = false;
+ handled = true;
}
// Figure
else if (!strncmp(token, "img ", 4)) {
const char *src = strstr(token, "src");
if (!src) // assert we have a src attribute
- return false;
+ continue;
+// return false;
pushString(&to, "<figure src=\"");
const char *c;
@@ -146,7 +171,7 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
pushString(&to, "\" />");
lastspace = false;
- return true;
+ handled = true;
}
// Strongs numbers
@@ -184,6 +209,7 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
lastspace = false;
}
}
+ handled = true;
}
// Morphology
@@ -217,9 +243,14 @@ char GBFOSIS::ProcessText(char *text, int maxlen, const SWKey *key, const SWModu
pushString(&to, "</w>");
lastspace = false;
}
+ handled = true;
}
- if (!keepToken) { // if we don't want strongs
+ if (!keepToken) {
+ if (!handled) {
+ SWLog::systemlog->LogError("Unprocessed Token: <%s>", token);
+// exit(-1);
+ }
if (from[1] && strchr(" ,;.:?!()'\"", from[1])) {
if (lastspace)
to--;
diff --git a/usrinst.sh b/usrinst.sh
index a89e4f9..fc54a88 100755
--- a/usrinst.sh
+++ b/usrinst.sh
@@ -1,10 +1,14 @@
#!/bin/sh
-CPPFLAGS=-DUSBINARY ./configure --prefix=/usr \
- --disable-shared --without-conf --sysconfdir=/etc \
- --with-vcl \
-# --enable-debug --enable-profile \
- $*
+OPTIONS="--prefix=/usr"
+OPTIONS="--disable-shared $OPTIONS"
+OPTIONS="--without-conf $OPTIONS"
+OPTIONS="--sysconfdir=/etc $OPTIONS"
+OPTIONS="--with-vcl $OPTIONS"
+OPTIONS="--enable-debug $OPTIONS"
+#OPTIONS="--enable-profile $OPTIONS"
+
+CPPFLAGS=-DUSBINARY ./configure $OPTIONS $*
echo ""
echo ""