38 static const char oName[] =
"Word Javascript";
39 static const char oTip[] =
"Toggles Word Javascript data";
43 static const StringList oVals(&choices[0], &choices[2]);
72 SWBuf wordSrcPrefix = (modName ==
"KJV")?
SWBuf(
"TR"):modName;
79 const SWBuf orig = text;
80 const char * from = orig.
c_str();
82 for (text =
""; *from; ++from) {
93 if ((*token ==
'w') && (token[1] ==
' ')) {
95 sprintf(wordstr,
"%03d", wordNum);
105 for (
int i = 0; i < count; i++) {
108 SWBuf tmp =
"LemmaClass";
117 if (lemmaClass ==
"strong") {
121 if (lemma.
size()) lemma +=
"|";
127 if (morph.
size()) morph +=
"|";
134 tmp.
insert(0, wordSrcPrefix);
135 if (src.
size()) src +=
"|";
151 if ((lemmaClass !=
"strong") && (xlit.
startsWith(
"betacode:"))) {
152 lexName =
"betacode";
166 for (
unsigned int i = 0; i < wordID.
size(); i++) {
167 if ((!isdigit(wordID[i])) && (!isalpha(wordID[i]))) {
172 text.
appendFormatted(
"<span class=\"clk\" onclick=\"p('%s','%s','%s','%s','%s','%s');\" >", lexName.
c_str(), lemma.
c_str(), wordID.
c_str(), morph.
c_str(), page.
c_str(), modName.
c_str());
176 text +=
"</w></span>";
179 if ((*token ==
'/') && (token[1] ==
'w') &&
option) {
180 text +=
"</w></span>";
193 token[tokpos++] = *from;
SWModule * defaultHebParse
const char * getName() const
#define SWORD_NAMESPACE_START
SWBuf & appendFormatted(const char *format,...)
unsigned long length() const
bool startsWith(const SWBuf &prefix) const
static const StringList * oValues()
virtual char processText(SWBuf &text, const SWKey *key=0, const SWModule *module=0)
SWModule * defaultGreekParse
virtual const char * getText() const
void insert(unsigned long pos, const char *str, unsigned long start=0, signed long max=-1)
const char * c_str() const
std::list< SWBuf > StringList
SWBuf & append(const char *str, long max=-1)
static const char oName[]
virtual int getVerse() const
#define SWDYNAMIC_CAST(className, object)
unsigned long size() const
virtual AttributeTypeList & getEntryAttributes() const
static const char * choices[4]
const char * getAttribute(const char *attribName, int partNum=-1, char partSplit= '|') const
SWModule * defaultGreekLex
#define SWORD_NAMESPACE_END