private static void setBlockSpan ( SpannableStringBuilder builder , Object what ) { int length = Math . max ( 0 , builder . length ( ) - 1 ) ; builder . setSpan ( what , 0 , length , Spannable . SPAN_EXCLUSIVE_EXCLUSIVE ) ; }
These have trailing newlines that we want to avoid spanning