[sword-svn] r3019 - trunk/utilities/diatheke
refdoc at crosswire.org
refdoc at crosswire.org
Thu Jan 23 02:50:23 MST 2014
Author: refdoc
Date: 2014-01-23 02:50:23 -0700 (Thu, 23 Jan 2014)
New Revision: 3019
Modified:
trunk/utilities/diatheke/corediatheke.cpp
Log:
correction to font and language handling in HTML like output formats
Modified: trunk/utilities/diatheke/corediatheke.cpp
===================================================================
--- trunk/utilities/diatheke/corediatheke.cpp 2014-01-23 09:27:45 UTC (rev 3018)
+++ trunk/utilities/diatheke/corediatheke.cpp 2014-01-23 09:50:23 UTC (rev 3019)
@@ -492,8 +492,11 @@
else {
*output << (char*)target->getKeyText();
}
- if (font && (outputformat == FMT_HTML || outputformat == FMT_HTMLHREF || outputformat == FMT_XHTML || outputformat == FMT_THML || outputformat == FMT_CGI)) {
- *output << ": <span style=\"font:\"" << font << ";\"" << " lang=\"" << modlocale << "\">";
+ if (outputformat == FMT_HTML || outputformat == FMT_HTMLHREF || outputformat == FMT_XHTML || outputformat == FMT_THML || outputformat == FMT_CGI) {
+ *output << ": <span ";
+ if (font) { *output << "style=\"font:\"" << font << ";\" " ;}
+ if (strcmp(modlocale,locale) !=0 ) { *output << "lang=\"" << modlocale << "\"";}
+ *output << ">";
}
else if (outputformat == FMT_RTF) {
*output << ": {\\f1 ";
@@ -508,7 +511,7 @@
*output << target->renderText();
- if (font && (outputformat == FMT_HTML || outputformat == FMT_HTMLHREF || outputformat == FMT_XHTML || outputformat == FMT_THML || outputformat == FMT_CGI)) {
+ if (outputformat == FMT_HTML || outputformat == FMT_HTMLHREF || outputformat == FMT_XHTML || outputformat == FMT_THML || outputformat == FMT_CGI) {
*output << "</span>";
}
else if (outputformat == FMT_RTF) {
More information about the sword-cvs
mailing list