Language

StaticLayout.Builder.SetUseBoundsForWidth(Boolean) Method

Definition

Set true for using width of bounding box as a source of automatic line breaking and drawing.

[Android.Runtime.Register("setUseBoundsForWidth", "(Z)Landroid/text/StaticLayout$Builder;", "", ApiSince=35)]
public Android.Text.StaticLayout.Builder SetUseBoundsForWidth(bool useBoundsForWidth);
[<Android.Runtime.Register("setUseBoundsForWidth", "(Z)Landroid/text/StaticLayout$Builder;", "", ApiSince=35)>]
member this.SetUseBoundsForWidth : bool -> Android.Text.StaticLayout.Builder

Parameters

useBoundsForWidth
Boolean

True for using bounding box, false for advances.

Returns

this builder instance. This value cannot be null.

Attributes

Remarks

Set true for using width of bounding box as a source of automatic line breaking and drawing. If this value is false, the Layout determines the drawing offset and automatic line breaking based on total advances. By setting true, use all joined glyph's bounding boxes as a source of text width. If the font has glyphs that have negative bearing X or its xMax is greater than advance, the glyph clipping can happen because the drawing area may be bigger. By setting this to true, the Layout will reserve more spaces for drawing.

Android reference for android.text.StaticLayout.Builder.setUseBoundsForWidth.

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