@@ -939,27 +939,22 @@ private float handleRun(int start, int measureLimit,
939939 continue ;
940940 }
941941
942- if (c == null ) {
943- x += handleText (wp , i , mlimit , i , inext , runIsRtl , c , x , top ,
944- y , bottom , fmi , needWidth || mlimit < measureLimit );
945- } else {
946- for (int j = i , jnext ; j < mlimit ; j = jnext ) {
947- jnext = mCharacterStyleSpanSet .getNextTransition (mStart + j , mStart + mlimit ) -
948- mStart ;
949-
950- wp .set (mPaint );
951- for (int k = 0 ; k < mCharacterStyleSpanSet .numberOfSpans ; k ++) {
952- // Intentionally using >= and <= as explained above
953- if ((mCharacterStyleSpanSet .spanStarts [k ] >= mStart + jnext ) ||
954- (mCharacterStyleSpanSet .spanEnds [k ] <= mStart + j )) continue ;
955-
956- CharacterStyle span = mCharacterStyleSpanSet .spans [k ];
957- span .updateDrawState (wp );
958- }
942+ for (int j = i , jnext ; j < mlimit ; j = jnext ) {
943+ jnext = mCharacterStyleSpanSet .getNextTransition (mStart + j , mStart + mlimit ) -
944+ mStart ;
945+
946+ wp .set (mPaint );
947+ for (int k = 0 ; k < mCharacterStyleSpanSet .numberOfSpans ; k ++) {
948+ // Intentionally using >= and <= as explained above
949+ if ((mCharacterStyleSpanSet .spanStarts [k ] >= mStart + jnext ) ||
950+ (mCharacterStyleSpanSet .spanEnds [k ] <= mStart + j )) continue ;
959951
960- x += handleText ( wp , j , jnext , i , inext , runIsRtl , c , x ,
961- top , y , bottom , fmi , needWidth || jnext < measureLimit );
952+ CharacterStyle span = mCharacterStyleSpanSet . spans [ k ];
953+ span . updateDrawState ( wp );
962954 }
955+
956+ x += handleText (wp , j , jnext , i , inext , runIsRtl , c , x ,
957+ top , y , bottom , fmi , needWidth || jnext < measureLimit );
963958 }
964959 }
965960
0 commit comments