[sword-cvs] sword/src/modules/filters thmlhtmlhref.cpp,1.37,1.38
sword@www.crosswire.org
sword@www.crosswire.org
Mon, 15 Dec 2003 12:58:51 -0700
Update of /usr/local/cvsroot/sword/src/modules/filters
In directory www:/tmp/cvs-serv1254
Modified Files:
thmlhtmlhref.cpp
Log Message:
fixed crash when sync type = Dict
Index: thmlhtmlhref.cpp
===================================================================
RCS file: /usr/local/cvsroot/sword/src/modules/filters/thmlhtmlhref.cpp,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -d -r1.37 -r1.38
--- thmlhtmlhref.cpp 12 Aug 2003 05:36:30 -0000 1.37
+++ thmlhtmlhref.cpp 15 Dec 2003 19:58:48 -0000 1.38
@@ -143,11 +143,34 @@
if (tag.getName() && !strcmp(tag.getName(), "sync")) {
if( tag.getAttribute("type") && !strcmp(tag.getAttribute("type"), "morph")) { //>
buf += "<small><em>(<a href=\"";
+ buf += "type=";
+ buf += tag.getAttribute("type");
+
+ const char* value = tag.getAttribute("value");
+ buf += " value=";
+ buf += value ? value : "";
+ buf += "\">";
+ buf += "</a>) </em></small>";
}
- else {
+ else if( tag.getAttribute("type") && !strcmp(tag.getAttribute("type"), "Strongs")) {
buf += "<small><em><<a href=\"";
+ buf += "type=";
+ buf += tag.getAttribute("type");
+
+ const char* value = tag.getAttribute("value");
+ buf += " value=";
+ buf += value ? value : "";
+ buf += "\">";
+ value++;
+ buf += "</a>> </em></small>";
}
-
+ else if( tag.getAttribute("type") && !strcmp(tag.getAttribute("type"), "Dict")) {
+ buf += "<b>";
+ }
+ else if(tag.isEndTag()) {
+ buf += "</b>";
+ }
+/*
buf += "type=";
buf += tag.getAttribute("type");
@@ -166,6 +189,7 @@
buf += "</a>) </em></small>";
else
buf += "</a>> </em></small>";
+*/
}
else if (tag.getName() && !strcmp(tag.getName(), "scripture")) {
u->inscriptRef = true;