36 static const char oName[] =
"Strong's Numbers";
37 static const char oTip[] =
"Toggles Strong's Numbers On and Off if they exist";
41 static const StringList oVals(&choices[0], &choices[2]);
60 bool lastspace =
false;
66 unsigned int textStart = 0, textEnd = 0;
73 for (text =
""; *from; from++) {
80 textEnd = (
unsigned int)text.
length();
85 if (!
strnicmp(token,
"sync type=\"Strongs\" ", 20)) {
88 for (
unsigned int i = 27; token[i] !=
'\"' && i < 150; i++)
91 if (atoi((!isdigit(*val))?val+1:val) < 5627) {
93 sprintf(wordstr,
"%03d", word);
100 tmp.
append(text.
c_str()+textStart, (int)(textEnd - textStart));
119 if ((from[1] ==
' ') || (from[1] ==
',') || (from[1] ==
';') || (from[1] ==
'.') || (from[1] ==
'?') || (from[1] ==
'!') || (from[1] ==
')') || (from[1] ==
'\'') || (from[1] ==
'\"')) {
123 if (newText) {textStart = (
unsigned int)text.
length(); newText =
false; }
128 if (!strncmp(token,
"sync type=\"morph\"", 17)) {
129 for (ch = token+17; *ch; ch++) {
130 if (!strncmp(ch,
"class=\"", 7)) {
132 for (
unsigned int i = 7; ch[i] !=
'\"' && i < 127; i++)
135 sprintf(wordstr,
"%03d", word-1);
136 if ((!
stricmp(val,
"Robinsons")) || (!
stricmp(val,
"Robinson"))) {
137 strcpy(val,
"robinson");
142 if (!strncmp(ch,
"value=\"", 7)) {
144 for (
unsigned int i = 7; ch[i] !=
'\"' && i < 127; i++)
147 sprintf(wordstr,
"%03d", word-1);
159 if (newText) {textStart = (
unsigned int)text.
length(); newText =
false; }
164 token[tokpos++] = *from;
171 lastspace = (*from ==
' ');
#define SWORD_NAMESPACE_START
unsigned long length() const
static const StringList * oValues()
int stricmp(const char *s1, const char *s2)
const char * c_str() const
std::list< SWBuf > StringList
SWBuf & append(const char *str, long max=-1)
static const char oName[]
virtual bool isProcessEntryAttributes() const
virtual AttributeTypeList & getEntryAttributes() const
static const char * choices[4]
int strnicmp(const char *s1, const char *s2, int len)
#define SWORD_NAMESPACE_END
virtual char processText(SWBuf &text, const SWKey *key=0, const SWModule *module=0)