Skip to content

Most visited

Recently visited

navigation

LeadingMarginSpan.LeadingMarginSpan2

public static interface LeadingMarginSpan.LeadingMarginSpan2
implements LeadingMarginSpan, WrapTogetherSpan

android.text.style.LeadingMarginSpan.LeadingMarginSpan2


An extended version of LeadingMarginSpan, which allows the implementor to specify the number of lines of the paragraph to which this object is attached that the "first line of paragraph" margin width will be applied to.

There should only be one LeadingMarginSpan2 per paragraph. The leading margin line count affects all LeadingMarginSpans in the paragraph, adjusting the number of lines to which the first line margin is applied.

As with LeadingMarginSpans, LeadingMarginSpan2s should be attached from the beginning to the end of a paragraph.

Summary

Public methods

abstract int getLeadingMarginLineCount()

Returns the number of lines of the paragraph to which this object is attached that the "first line" margin will apply to.

Inherited methods

From interface android.text.style.LeadingMarginSpan

Public methods

getLeadingMarginLineCount

added in API level 8
int getLeadingMarginLineCount ()

Returns the number of lines of the paragraph to which this object is attached that the "first line" margin will apply to.

Returns
int

This site uses cookies to store your preferences for site-specific language and display options.

Get the latest Android developer news and tips that will help you find success on Google Play.

* Required Fields

Hooray!

Follow Google Developers on WeChat

Browse this site in ?

You requested a page in , but your language preference for this site is .

Would you like to change your language preference and browse this site in ? If you want to change your language preference later, use the language menu at the bottom of each page.

This class requires API level or higher

This doc is hidden because your selected API level for the documentation is . You can change the documentation API level with the selector above the left navigation.

For more information about specifying the API level your app requires, read Supporting Different Platform Versions.

Take a short survey?
Help us improve the Android developer experience.
(Sep 2017 survey)