Home
last modified time | relevance | path

Searched refs:setSpan (Results 1 – 25 of 29) sorted by relevance

12

/cts/tests/tests/text/src/android/text/cts/
DSpannableStringTest.java81 spannable.setSpan(null, 1, 4, SpannableString.SPAN_POINT_POINT); in testSetSpan()
87 spannable.setSpan(underlineSpan, 0, 2, SpannableString.SPAN_EXCLUSIVE_EXCLUSIVE); in testSetSpan()
94 spannable.setSpan(null, 4, 1, SpannableString.SPAN_POINT_POINT); in testSetSpan()
100 spannable.setSpan(underlineSpan, -1, text.length() + 1, in testSetSpan()
114 spannable.setSpan(underlineSpan, 0, 2, 2); in testRemoveSpan()
162 first.setSpan(quoteSpan, 0, 2, Spanned.SPAN_PARAGRAPH); in testSubsequence_copiesSpans()
163 first.setSpan(localeSpan, 2, 4, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); in testSubsequence_copiesSpans()
164 first.setSpan(underlineSpan, 0, first.length(), Spanned.SPAN_PRIORITY); in testSubsequence_copiesSpans()
188 first.setSpan(new QuoteSpan(), 0, 2, Spanned.SPAN_PARAGRAPH); in testCopyConstructor_copiesAllSpans()
189 first.setSpan(new LocaleSpan(Locale.US), 2, 4, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); in testCopyConstructor_copiesAllSpans()
[all …]
DSpannableStringBuilderTest.java101 builder.setSpan(mUnderlineSpan, 2, 4, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testGetSpanFlags()
102 builder.setSpan(mUnderlineSpan, 0, 1, Spanned.SPAN_EXCLUSIVE_INCLUSIVE); in testGetSpanFlags()
103 builder.setSpan(mStrikethroughSpan, 5, 7, Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in testGetSpanFlags()
114 builder.setSpan(mUnderlineSpan, 1, 2, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testNextSpanTransition()
115 builder.setSpan(mUnderlineSpan, 3, 4, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testNextSpanTransition()
116 builder.setSpan(mStrikethroughSpan, 5, 6, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testNextSpanTransition()
117 builder.setSpan(mStrikethroughSpan, 8, 9, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testNextSpanTransition()
130 builder.setSpan(mUnderlineSpan, 4, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testSetSpan()
137 builder.setSpan(mUnderlineSpan, -1, 100, Spanned.SPAN_POINT_POINT); in testSetSpan()
143 builder.setSpan(null, 1, 4, Spanned.SPAN_POINT_POINT); in testSetSpan()
[all …]
DHtmlTest.java252 s.setSpan(new AlignmentSpan.Standard(Layout.Alignment.ALIGN_CENTER), in testParagraphStyles()
260 s.setSpan(new AlignmentSpan.Standard(Layout.Alignment.ALIGN_OPPOSITE), in testParagraphStyles()
269 s.setSpan(new AlignmentSpan.Standard(Layout.Alignment.ALIGN_NORMAL), in testParagraphStyles()
280 s.setSpan(new BulletSpan(), 0, 8, Spanned.SPAN_PARAGRAPH); in testBulletSpan()
281 s.setSpan(new BulletSpan(), 8, 16, Spanned.SPAN_PARAGRAPH); in testBulletSpan()
297 s.setSpan(new QuoteSpan(), start, end, Spannable.SPAN_PARAGRAPH); in testBlockquote()
303 s.setSpan(new QuoteSpan(), start, end, Spannable.SPAN_PARAGRAPH); in testBlockquote()
329 s.setSpan(new StyleSpan(Typeface.BOLD), start, end, SPAN_EXCLUSIVE_INCLUSIVE); in testMarkup()
335 s.setSpan(new StyleSpan(Typeface.ITALIC), start, end, SPAN_EXCLUSIVE_INCLUSIVE); in testMarkup()
341 s.setSpan(new TypefaceSpan("monospace"), start, end, SPAN_EXCLUSIVE_INCLUSIVE); in testMarkup()
[all …]
DSpannedTest.java76 text.setSpan(new QuoteSpan(), 0, 4, flags); in testNextSpanTransition()
77 text.setSpan(new LocaleSpan((Locale) null), 2, 7, flags); in testNextSpanTransition()
78 text.setSpan(new UnderlineSpan(), 5, text.length(), flags); in testNextSpanTransition()
DPrecomputedTextTest.java73 ssb.setSpan(SPAN, SPAN_START, SPAN_END, Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in ssb.setSpan()
240 s.setSpan(span, SPAN_START, SPAN_END, Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in testSpannedInterface_Spannable()
259 s.setSpan(SPAN, SPAN_START, SPAN_END, Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in testSpannedInterface_Spannable_setSpan_MetricsAffectingSpan()
352 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 1 /* text size */, in testGetWidth_multiStyle()
354 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 5 /* text size */, in testGetWidth_multiStyle()
379 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 1 /* text size */, in testGetWidth_multiStyle2()
381 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 5 /* text size */, in testGetWidth_multiStyle2()
383 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 5 /* text size */, in testGetWidth_multiStyle2()
513 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 1 /* text size */, in testGetBounds_multiStyle()
515 ssb.setSpan(new TextAppearanceSpan(null /* family */, Typeface.NORMAL, 5 /* text size */, in testGetBounds_multiStyle()
[all …]
DStaticLayoutLineBreakingTest.java223 result.setSpan(getMetricAffectingSpan(), sSpanStarts[i], sSpanEnds[i], in spanify()
353 ssb.setSpan(metricAffectingSpan, spanStart, spanEnd, in testWithOneSpan()
379 ssb.setSpan(metricAffectingSpan1, spanStart1, spanEnd1, in testWithTwoSpans()
384 ssb.setSpan(metricAffectingSpan2, spanStart2, spanEnd2, in testWithTwoSpans()
DTextUtilsTest.java273 string1.setSpan(urlSpan, 0, string1.length() - 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testConcat()
275 string2.setSpan(bgColorSpan, 0, string2.length() - 1, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); in testConcat()
309 piece.setSpan(span, 0, piece.length(), Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in testConcat_NullParameters()
327 string1.setSpan(span1, 0, string1.length(), Spanned.SPAN_PARAGRAPH); in testConcat_twoParagraphSpans()
328 string2.setSpan(span2, 0, string2.length(), Spanned.SPAN_PARAGRAPH); in testConcat_twoParagraphSpans()
347 string1.setSpan(span1, 0, string1.length(), Spanned.SPAN_PARAGRAPH); in testConcat_oneParagraphSpanAndOneInclusiveSpan()
348 string2.setSpan(span2, 0, string2.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testConcat_oneParagraphSpanAndOneInclusiveSpan()
370 source1.setSpan(urlSpan, 0, midPos, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testCopySpansFrom()
372 source1.setSpan(bgColorSpan, midPos - 1, in testCopySpansFrom()
392 source2.setSpan(urlSpan, 0, source2.length() - 1, Spanned.SPAN_EXCLUSIVE_INCLUSIVE); in testCopySpansFrom()
[all …]
DSpannableStringBuilderSpanTest.java388 spannable.setSpan(mSpans[count], start, end, flag); in initSpans()
397 spannable.setSpan(mRecorder, 0, spannable.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE); in initSpans()
566 newText.setSpan(new QuoteSpan(), 0, 1, Spannable.SPAN_PARAGRAPH); in testReplace_retainsParagraphSpanInSourceIfEndIsEqualToLengthOfString()
582 newText.setSpan(new QuoteSpan(), 0, 1, Spannable.SPAN_PARAGRAPH); in testReplace_discardsParagraphSpanInSourceIfThereIsNoNewLineAfter()
597 original.setSpan(span, 1, original.length() - 1, Spanned.SPAN_PARAGRAPH); in testCopyConstructorDoesNotEnforceParagraphStyleConstraint()
DStaticLayoutTest.java1203 text.setSpan(new StyleSpan(Typeface.BOLD),
1238 spannable.setSpan(new Object(), 0, text.length(), SpannableString.SPAN_EXCLUSIVE_EXCLUSIVE);
1520 ssb.setSpan(firstStyleSpan, 0, 13, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
1521 ssb.setSpan(firstReplacement, 0, 13, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
1522 ssb.setSpan(secondStyleSpan, 13, 27, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
1523 ssb.setSpan(secondReplacement, 13, 27, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE);
1547 spanStr0.setSpan(new LineHeightSpan.Standard(expectedHeight0), 0, spanStr0.length(),
1562 spanStr1.setSpan(new LineHeightSpan.Standard(expectedHeight1), 0, spanStr1.length(),
1580 spanStr.setSpan(new LineHeightSpan.Standard(25), 0, spanStr.length(),
1583 spanStr.setSpan(new LineHeightSpan.Standard(expectedHeight), 0, spanStr.length(),
[all …]
DInputFilter_AllCapsTest.java119 source.setSpan(span, 0, 2, Spanned.SPAN_INCLUSIVE_INCLUSIVE); // around "ί" in testFilter_greekWithSpans()
DStaticLayoutGetLineLeftRightTest.java102 ss.setSpan(new LeadingMarginSpan.Standard(mLeadingMargin), in StaticLayoutGetLineLeftRightTest()
DBidiFormatterTest.java259 CS_EN_HE.setSpan(RELATIVE_SIZE_SPAN, 0, EN.length(), Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testCharSequenceApis()
/cts/tests/tests/text/src/android/text/method/cts/
DMetaKeyKeyListenerTest.java58 content.setSpan(Selection.SELECTION_START, 0, 0, Spanned.SPAN_POINT_POINT); in testPressKey()
59 content.setSpan(Selection.SELECTION_END, 0, 0, Spanned.SPAN_POINT_POINT); in testPressKey()
64 content.setSpan(Selection.SELECTION_START, 1, 1, Spanned.SPAN_POINT_POINT); in testPressKey()
65 content.setSpan(Selection.SELECTION_END, 1, 1, Spanned.SPAN_POINT_POINT); in testPressKey()
70 content.setSpan(Selection.SELECTION_START, 3, 3, Spanned.SPAN_POINT_POINT); in testPressKey()
71 content.setSpan(Selection.SELECTION_END, 3, 3, Spanned.SPAN_POINT_POINT); in testPressKey()
84 content.setSpan(Selection.SELECTION_START, 0, 0, Spanned.SPAN_POINT_POINT); in testReleaseKey()
85 content.setSpan(Selection.SELECTION_END, 0, 0, Spanned.SPAN_POINT_POINT); in testReleaseKey()
90 content.setSpan(Selection.SELECTION_START, 1, 1, Spanned.SPAN_POINT_POINT); in testReleaseKey()
91 content.setSpan(Selection.SELECTION_END, 1, 1, Spanned.SPAN_POINT_POINT); in testReleaseKey()
[all …]
DSingleLineTransformationMethodTest.java86 original.setSpan(span, 1, original.length() - 1, Spanned.SPAN_PARAGRAPH); in testSubsequence_doesNotThrowExceptionWithParagraphSpans()
DEditorState.java172 spannable.setSpan(new MockReplacementSpan(), replacementSpanStart, replacementSpanEnd, in setByString()
DDigitsKeyListenerTest.java110 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter1()
189 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter2()
272 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter3()
358 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter4()
472 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter4_internationalized()
DNumberKeyListenerTest.java79 spannableSource.setSpan(what, 0, spannableSource.length(), Spanned.SPAN_POINT_POINT); in testFilter()
/cts/tests/tests/text/src/android/text/style/cts/
DUnderlineSpanTest.java111 text.setSpan(new UnderlineSpan(), 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
119 text.setSpan(new UnderlineSpan(), 1, 2, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
127 text.setSpan(new UnderlineSpan(), 3, 4, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
135 text.setSpan(new UnderlineSpan(), 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
136 text.setSpan(new UnderlineSpan(), 3, 4, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
154 text.setSpan(new SafeUnderlineSpan(), 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth_safeSubclass()
174 text.setSpan(new NoUnderlineSpan(), 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth_noUnderlineSubclass()
198 text.setSpan(new ElegantUnderlineSpan(), 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testAffectsWidth_ElegantSubclass()
DStrikethroughSpanTest.java113 text.setSpan(new StrikethroughSpan(), 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
DSuggestionSpanTest.java234 text.setSpan(span, 0, 1, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testDoesntAffectWidth()
/cts/tests/inputmethod/src/android/view/inputmethod/cts/
DExtractedTextTest.java48 hint.setSpan(new StyleSpan(Typeface.BOLD), 1, 3, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testWriteToParcel()
DBaseInputConnectionTest.java460 editable.setSpan(Selection.SELECTION_START, 4, 4, Spanned.SPAN_POINT_POINT);
/cts/tests/tests/widget/src/android/widget/cts/
DMultiAutoCompleteTextView_CommaTokenizerTest.java127 spannableString.setSpan(what, 0, spannableString.length(), in testTerminateToken()
DTextViewTest.java1682 text.setSpan(span, 0, 1, Spanned.SPAN_EXCLUSIVE_EXCLUSIVE); in testSetTextUpdatesHeightAfterRemovingImageSpan()
2421 spannable.setSpan(new URLSpan("http://example.com"), 0, spannable.length(), 0); in testCutAndPaste_withAndWithoutStyle()
4672 spannable.setSpan(new URLSpan(url), 0, url.length(), 0); in testGetUrls()
4678 spannable.setSpan(new URLSpan(email), 0, email.length(), 0); in testGetUrls()
4687 spannable.setSpan(new Object(), 0, 9, 0); in testGetUrls()
5596 ss.setSpan(new UnderlineSpan(), 0, 2, 0); in testSetExtractedText()
5597 ss.setSpan(new URLSpan("ctstest://TextView/test"), 1, 2, 0); in testSetExtractedText()
6253 source.setSpan(new Object(), 0, 1, flags); in testAllCaps_SpansArePreserved()
6254 source.setSpan(new Object(), 1, 2, flags); in testAllCaps_SpansArePreserved()
6255 source.setSpan(new Object(), 2, 3, flags); in testAllCaps_SpansArePreserved()
[all …]
/cts/tests/accessibilityservice/src/android/accessibilityservice/cts/
DAccessibilityTextActionTest.java198 textWithClickableSpan.setSpan(clickableSpan, 0, 1, 0); in testClickableSpan_shouldWorkFromAccessibilityService()
220 textWithClickableSpan.setSpan(urlSpan, 0, 1, 0); in testUrlSpan_shouldWorkFromAccessibilityService()

12