次の方法で共有


Html.FromHtml Method

Definition

Overloads

FromHtml(String)

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

FromHtml(String, FromHtmlOptions)

Returns displayable styled text from the provided HTML string.

FromHtml(String, Html+IImageGetter, Html+ITagHandler)

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

FromHtml(String, FromHtmlOptions, Html+IImageGetter, Html+ITagHandler)

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

FromHtml(String)

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

[Android.Runtime.Register("fromHtml", "(Ljava/lang/String;)Landroid/text/Spanned;", "")]
public static Android.Text.ISpanned? FromHtml (string? source);
[<Android.Runtime.Register("fromHtml", "(Ljava/lang/String;)Landroid/text/Spanned;", "")>]
static member FromHtml : string -> Android.Text.ISpanned

Parameters

source
String

Returns

Attributes

Remarks

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

This member is deprecated. use #fromHtml(String, int) instead.

Java documentation for android.text.Html.fromHtml(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

FromHtml(String, FromHtmlOptions)

Returns displayable styled text from the provided HTML string.

[Android.Runtime.Register("fromHtml", "(Ljava/lang/String;I)Landroid/text/Spanned;", "", ApiSince=24)]
public static Android.Text.ISpanned? FromHtml (string? source, Android.Text.FromHtmlOptions flags);
[<Android.Runtime.Register("fromHtml", "(Ljava/lang/String;I)Landroid/text/Spanned;", "", ApiSince=24)>]
static member FromHtml : string * Android.Text.FromHtmlOptions -> Android.Text.ISpanned

Parameters

source
String

Returns

Attributes

Remarks

Returns displayable styled text from the provided HTML string. Any &lt;img&gt; tags in the HTML will display as a generic replacement image which your program can then go through and replace with real images.

This uses TagSoup to handle real HTML, including all of the brokenness found in the wild.

Java documentation for android.text.Html.fromHtml(java.lang.String, 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

FromHtml(String, Html+IImageGetter, Html+ITagHandler)

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

[Android.Runtime.Register("fromHtml", "(Ljava/lang/String;Landroid/text/Html$ImageGetter;Landroid/text/Html$TagHandler;)Landroid/text/Spanned;", "")]
public static Android.Text.ISpanned? FromHtml (string? source, Android.Text.Html.IImageGetter? imageGetter, Android.Text.Html.ITagHandler? tagHandler);
[<Android.Runtime.Register("fromHtml", "(Ljava/lang/String;Landroid/text/Html$ImageGetter;Landroid/text/Html$TagHandler;)Landroid/text/Spanned;", "")>]
static member FromHtml : string * Android.Text.Html.IImageGetter * Android.Text.Html.ITagHandler -> Android.Text.ISpanned

Parameters

source
String
imageGetter
Html.IImageGetter
tagHandler
Html.ITagHandler

Returns

Attributes

Remarks

Java documentation for android.text.Html.fromHtml(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

FromHtml(String, FromHtmlOptions, Html+IImageGetter, Html+ITagHandler)

Returns displayable styled text from the provided HTML string with the legacy flags #FROM_HTML_MODE_LEGACY.

[Android.Runtime.Register("fromHtml", "(Ljava/lang/String;ILandroid/text/Html$ImageGetter;Landroid/text/Html$TagHandler;)Landroid/text/Spanned;", "", ApiSince=24)]
public static Android.Text.ISpanned? FromHtml (string? source, Android.Text.FromHtmlOptions flags, Android.Text.Html.IImageGetter? imageGetter, Android.Text.Html.ITagHandler? tagHandler);
[<Android.Runtime.Register("fromHtml", "(Ljava/lang/String;ILandroid/text/Html$ImageGetter;Landroid/text/Html$TagHandler;)Landroid/text/Spanned;", "", ApiSince=24)>]
static member FromHtml : string * Android.Text.FromHtmlOptions * Android.Text.Html.IImageGetter * Android.Text.Html.ITagHandler -> Android.Text.ISpanned

Parameters

source
String
imageGetter
Html.IImageGetter
tagHandler
Html.ITagHandler

Returns

Attributes

Remarks

Java documentation for android.text.Html.fromHtml(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