Loading core/java/android/text/StaticLayout.java +25 −18 Original line number Diff line number Diff line Loading @@ -216,8 +216,10 @@ extends Layout boolean tab = false; int spanEnd; for (int spanStart = paraStart; spanStart < paraEnd; spanStart = spanEnd) { for (int spanStart = paraStart, spanEnd = spanStart, nextSpanStart; spanStart < paraEnd; spanStart = nextSpanStart) { if (spanStart == spanEnd) { if (spanned == null) spanEnd = paraEnd; else Loading @@ -225,9 +227,6 @@ extends Layout MetricAffectingSpan.class); int spanLen = spanEnd - spanStart; int startInPara = spanStart - paraStart; int endInPara = spanEnd - paraStart; if (spanned == null) { measured.addStyleRun(paint, spanLen, fm); } else { Loading @@ -235,6 +234,11 @@ extends Layout spanned.getSpans(spanStart, spanEnd, MetricAffectingSpan.class); measured.addStyleRun(paint, spans, spanLen, fm); } } nextSpanStart = spanEnd; int startInPara = spanStart - paraStart; int endInPara = spanEnd - paraStart; int fmtop = fm.top; int fmbottom = fm.bottom; Loading Loading @@ -432,7 +436,10 @@ extends Layout } if (here < spanStart) { j = spanEnd = here; // must remeasure // didn't output all the text for this span // we've measured the raw widths, though, so // just reset the start point j = nextSpanStart = here; } else { j = here - 1; // continue looping } Loading Loading
core/java/android/text/StaticLayout.java +25 −18 Original line number Diff line number Diff line Loading @@ -216,8 +216,10 @@ extends Layout boolean tab = false; int spanEnd; for (int spanStart = paraStart; spanStart < paraEnd; spanStart = spanEnd) { for (int spanStart = paraStart, spanEnd = spanStart, nextSpanStart; spanStart < paraEnd; spanStart = nextSpanStart) { if (spanStart == spanEnd) { if (spanned == null) spanEnd = paraEnd; else Loading @@ -225,9 +227,6 @@ extends Layout MetricAffectingSpan.class); int spanLen = spanEnd - spanStart; int startInPara = spanStart - paraStart; int endInPara = spanEnd - paraStart; if (spanned == null) { measured.addStyleRun(paint, spanLen, fm); } else { Loading @@ -235,6 +234,11 @@ extends Layout spanned.getSpans(spanStart, spanEnd, MetricAffectingSpan.class); measured.addStyleRun(paint, spans, spanLen, fm); } } nextSpanStart = spanEnd; int startInPara = spanStart - paraStart; int endInPara = spanEnd - paraStart; int fmtop = fm.top; int fmbottom = fm.bottom; Loading Loading @@ -432,7 +436,10 @@ extends Layout } if (here < spanStart) { j = spanEnd = here; // must remeasure // didn't output all the text for this span // we've measured the raw widths, though, so // just reset the start point j = nextSpanStart = here; } else { j = here - 1; // continue looping } Loading