summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
d81319d)
Looks like QTextBoundaryFinder has a pathological issue with strings of length 1.
line.setNumColumns(length);
layout.endLayout();
line.setNumColumns(length);
layout.endLayout();
- while((idx = finder.toNextBoundary()) >= 0 && idx < length) {
- idx++; // the boundary is *before* the actual character
+ while((idx = finder.toNextBoundary()) >= 0 && idx <= length) {
+ if(idx < length)
+ idx++; // the boundary is *before* the actual character
+
+ if(idx == oldidx)
+ continue;
word.start = oldidx;
int wordend = idx;
word.start = oldidx;
int wordend = idx;