DeprecatedStringList DeprecatedStringList::split(const DeprecatedString &separator, const DeprecatedString &s, bool allowEmptyEntries) { DeprecatedStringList result; int startPos = 0; int endPos; while ((endPos = s.find(separator, startPos)) != -1) { if (allowEmptyEntries || startPos != endPos) result.append(s.mid(startPos, endPos - startPos)); startPos = endPos + separator.length(); } if (allowEmptyEntries || startPos != (int)s.length()) result.append(s.mid(startPos)); return result; }
KCanvasFEMerge *SVGFEMergeElement::filterEffect() const { if (!m_filterEffect) m_filterEffect = static_cast<KCanvasFEMerge *>(renderingDevice()->createFilterEffect(FE_MERGE)); if (!m_filterEffect) return 0; setStandardAttributes(m_filterEffect); DeprecatedStringList mergeInputs; for(Node *n = firstChild(); n != 0; n = n->nextSibling()) { if(n->hasTagName(SVGNames::feMergeNodeTag)) { String mergeInput = static_cast<SVGFEMergeNodeElement *>(n)->in1()->baseVal(); mergeInputs.append(mergeInput.deprecatedString()); } } m_filterEffect->setMergeInputs(mergeInputs); return m_filterEffect; }