Lines Matching defs:attributes

103 void SvoxSsmlParser::starttagHandler(void* data, const XML_Char* element, const XML_Char** attributes)
105 ((SvoxSsmlParser*)data)->startElement(element, attributes);
108 void SvoxSsmlParser::startElement(const XML_Char* element, const XML_Char** attributes)
127 for (int i = 0; attributes[i]; i += 2)
129 if (strcmp(attributes[i], "xml:lang") == 0)
133 m_docLanguage = new char[strlen(attributes[i+1])+1];
135 strcpy(m_docLanguage, attributes[i+1]);
140 else if (strcmp(element, "p") == 0) /* currently no attributes are supported for <p> */
152 else if (strcmp(element, "s") == 0) /* currently no attributes are supported for <s> */
173 for (int i = 0; attributes[i]; i += 2)
175 if (strcmp(attributes[i], "alphabet") == 0)
177 if (strcmp(attributes[i+1], "xsampa") == 0)
182 if (strcmp(attributes[i], "ph") == 0)
184 ph = new char16_t[strlen8to16(attributes[i+1]) + 1];
185 ph = strdup8to16(attributes[i+1], &phsize);
283 for (int i = 0; attributes[i]; i += 2)
285 if (strcmp(attributes[i], "time") == 0)
287 time = new char[strlen(attributes[i+1]) + 1];
293 strcpy(time, attributes[i+1]);
295 else if (strcmp(attributes[i], "strength") == 0 && !time)
297 time = convertBreakStrengthToTime(attributes[i+1]);
308 strcpy(time, SSML_BREAK_WEAK); /* if no time or strength attributes are specified, default to weak break */
322 else if (strcmp(element, "prosody") == 0) /* only pitch, rate and volume attributes are supported */
324 for (int i = 0; attributes[i]; i += 2)
326 if (strcmp(attributes[i], "pitch") == 0)
328 char* svoxpitch = convertToSvoxPitch(attributes[i+1]);
369 else if (strcmp(attributes[i], "rate") == 0)
371 char* svoxrate = convertToSvoxRate(attributes[i+1]);
412 else if (strcmp(attributes[i], "volume") == 0)
414 char* svoxvol = convertToSvoxVolume(attributes[i+1]);
464 for (int i = 0; attributes[i]; i += 2)
466 if (strcmp(attributes[i], "src") == 0)
468 if (strlen(m_data) + strlen(attributes[i+1]) + 1 > (size_t)m_datasize)
476 strcat(m_data, attributes[i+1]);