AttributedString Constructors

Definition

Overloads

AttributedString(IAttributedCharacterIterator)

Constructs an AttributedString instance with the given attributed text represented by AttributedCharacterIterator.

AttributedString(String)

Constructs an AttributedString instance with the given text.

AttributedString(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

AttributedString(String, IDictionary<AttributedCharacterIteratorAttribute,Object>)

Constructs an AttributedString instance with the given text and attributes.

AttributedString(IAttributedCharacterIterator, Int32, Int32)

Constructs an AttributedString instance with the subrange of the given attributed text represented by AttributedCharacterIterator.

AttributedString(IAttributedCharacterIterator, Int32, Int32, AttributedCharacterIteratorAttribute[])

Constructs an AttributedString instance with the given text.

AttributedString(IAttributedCharacterIterator)

Constructs an AttributedString instance with the given attributed text represented by AttributedCharacterIterator.

[Android.Runtime.Register(".ctor", "(Ljava/text/AttributedCharacterIterator;)V", "")]
public AttributedString (Java.Text.IAttributedCharacterIterator? text);
[<Android.Runtime.Register(".ctor", "(Ljava/text/AttributedCharacterIterator;)V", "")>]
new Java.Text.AttributedString : Java.Text.IAttributedCharacterIterator -> Java.Text.AttributedString

Parameters

text
IAttributedCharacterIterator

The text for this attributed string.

Attributes

Remarks

Java documentation for java.text.AttributedString.AttributedString(java.text.AttributedCharacterIterator).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

AttributedString(String)

Constructs an AttributedString instance with the given text.

[Android.Runtime.Register(".ctor", "(Ljava/lang/String;)V", "")]
public AttributedString (string? text);
[<Android.Runtime.Register(".ctor", "(Ljava/lang/String;)V", "")>]
new Java.Text.AttributedString : string -> Java.Text.AttributedString

Parameters

text
String

The text for this attributed string.

Attributes

Remarks

Java documentation for java.text.AttributedString.AttributedString(java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

AttributedString(IntPtr, JniHandleOwnership)

A constructor used when creating managed representations of JNI objects; called by the runtime.

protected AttributedString (IntPtr javaReference, Android.Runtime.JniHandleOwnership transfer);
new Java.Text.AttributedString : nativeint * Android.Runtime.JniHandleOwnership -> Java.Text.AttributedString

Parameters

javaReference
IntPtr

nativeint

A IntPtrcontaining a Java Native Interface (JNI) object reference.

transfer
JniHandleOwnership

A JniHandleOwnershipindicating how to handle javaReference

Remarks

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

AttributedString(String, IDictionary<AttributedCharacterIteratorAttribute,Object>)

Constructs an AttributedString instance with the given text and attributes.

[Android.Runtime.Register(".ctor", "(Ljava/lang/String;Ljava/util/Map;)V", "")]
public AttributedString (string? text, System.Collections.Generic.IDictionary<Java.Text.AttributedCharacterIteratorAttribute,object>? attributes);
[<Android.Runtime.Register(".ctor", "(Ljava/lang/String;Ljava/util/Map;)V", "")>]
new Java.Text.AttributedString : string * System.Collections.Generic.IDictionary<Java.Text.AttributedCharacterIteratorAttribute, obj> -> Java.Text.AttributedString

Parameters

text
String

The text for this attributed string.

attributes
IDictionary<AttributedCharacterIteratorAttribute,Object>

The attributes that apply to the entire string.

Attributes

Remarks

Java documentation for java.text.AttributedString.AttributedString(java.lang.String, java.util.Map<? extends java.text.AttributedCharacterIterator.Attribute, ?>).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

AttributedString(IAttributedCharacterIterator, Int32, Int32)

Constructs an AttributedString instance with the subrange of the given attributed text represented by AttributedCharacterIterator.

[Android.Runtime.Register(".ctor", "(Ljava/text/AttributedCharacterIterator;II)V", "")]
public AttributedString (Java.Text.IAttributedCharacterIterator? text, int beginIndex, int endIndex);
[<Android.Runtime.Register(".ctor", "(Ljava/text/AttributedCharacterIterator;II)V", "")>]
new Java.Text.AttributedString : Java.Text.IAttributedCharacterIterator * int * int -> Java.Text.AttributedString

Parameters

text
IAttributedCharacterIterator

The text for this attributed string.

beginIndex
Int32

Index of the first character of the range.

endIndex
Int32

Index of the character following the last character of the range.

Attributes

Exceptions

if start is less than first index of iterator, end is greater than the last index + 1 in iterator or if start > end.

Remarks

Java documentation for java.text.AttributedString.AttributedString(java.text.AttributedCharacterIterator, int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

AttributedString(IAttributedCharacterIterator, Int32, Int32, AttributedCharacterIteratorAttribute[])

Constructs an AttributedString instance with the given text.

[Android.Runtime.Register(".ctor", "(Ljava/text/AttributedCharacterIterator;II[Ljava/text/AttributedCharacterIterator$Attribute;)V", "")]
public AttributedString (Java.Text.IAttributedCharacterIterator? text, int beginIndex, int endIndex, Java.Text.AttributedCharacterIteratorAttribute[]? attributes);
[<Android.Runtime.Register(".ctor", "(Ljava/text/AttributedCharacterIterator;II[Ljava/text/AttributedCharacterIterator$Attribute;)V", "")>]
new Java.Text.AttributedString : Java.Text.IAttributedCharacterIterator * int * int * Java.Text.AttributedCharacterIteratorAttribute[] -> Java.Text.AttributedString

Parameters

text
IAttributedCharacterIterator

The text for this attributed string.

beginIndex
Int32
endIndex
Int32
Attributes

Exceptions

if start is less than first index of iterator, end is greater than the last index + 1 in iterator or if start > end.

Remarks

Java documentation for java.text.AttributedString.AttributedString(java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to