Parse QTextBlock from QTextDocument problem
On parse and iterate QTextBlock i can find all elements! only <hr> horizzontal line i can not find, is this element hidden on a property qvariant nummer from QTextBlockFormat or QTextCharFormat.. ?
http://doc.trolltech.com/4.1/qtextfo...ml#intProperty
How i can find the objekt?
I wand to export my xhtml + class name that I have put on QTextBlockFormat Property..
Code:
{
for (de = para.begin(); !(de.atEnd()); ++de) {
if (fr.isValid()) {
if (Pics.isValid()) {
........ /// image
} else if (Tabl.isValid()) {
........ /// table
} else if (Uls.isValid()) {
........ //// ul li
} else if (base.isAnchor() && base.anchorHref() !="" ) {
...... ///link
} else if (para.charFormat() !=fr.charFormat()) {
/* found diffs from fragment to paragraph ... */
if (para.text() == fr.text()) {
///// no span only format append
} else {
////span + format
}
} else {
forcedLineBreakRegExp
[3] = QChar::LineSeparator;
if (lines.size() > 0) {
for (int i = 0; i < lines.size(); ++i) {
const QString piece
= lines.
at(i
);
//// .chop(1) paragraph.appendChild(dom.createTextNode(piece));
if (piece != lines.last() ) {
paragraph.appendChild(breakline);
}
}
} else {
paragraph.appendChild(dom.createTextNode(txtfrag)); //// .chop(1)
}
}
}
}
appender.appendChild(paragraph);
}