Typeface.Create Method

Definition

Overloads

Create(Typeface, TypefaceStyle)

Create a typeface object that best matches the specified existing typeface and the specified Style.

Create(String, TypefaceStyle)

Create a typeface object given a family name, and option style information.

Create(Typeface, Int32, Boolean)

Creates a typeface object that best matches the specified existing typeface and the specified weight and italic style

Create(Typeface, TypefaceStyle)

Create a typeface object that best matches the specified existing typeface and the specified Style.

[Android.Runtime.Register("create", "(Landroid/graphics/Typeface;I)Landroid/graphics/Typeface;", "")]
public static Android.Graphics.Typeface? Create (Android.Graphics.Typeface? family, Android.Graphics.TypefaceStyle style);
[<Android.Runtime.Register("create", "(Landroid/graphics/Typeface;I)Landroid/graphics/Typeface;", "")>]
static member Create : Android.Graphics.Typeface * Android.Graphics.TypefaceStyle -> Android.Graphics.Typeface

Parameters

family
Typeface

An existing Typeface object. In case of null, the default typeface is used instead.

style
TypefaceStyle

The style (normal, bold, italic) of the typeface. e.g. NORMAL, BOLD, ITALIC, BOLD_ITALIC

Returns

Typeface

The best matching typeface.

Attributes

Remarks

Java documentation for android.graphics.Typeface.create(android.graphics.Typeface, 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

Create(String, TypefaceStyle)

Create a typeface object given a family name, and option style information.

[Android.Runtime.Register("create", "(Ljava/lang/String;I)Landroid/graphics/Typeface;", "")]
public static Android.Graphics.Typeface? Create (string? familyName, Android.Graphics.TypefaceStyle style);
[<Android.Runtime.Register("create", "(Ljava/lang/String;I)Landroid/graphics/Typeface;", "")>]
static member Create : string * Android.Graphics.TypefaceStyle -> Android.Graphics.Typeface

Parameters

familyName
String

May be null. The name of the font family.

style
TypefaceStyle

The style (normal, bold, italic) of the typeface. e.g. NORMAL, BOLD, ITALIC, BOLD_ITALIC

Returns

Typeface

The best matching typeface.

Attributes

Remarks

Java documentation for android.graphics.Typeface.create(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

Create(Typeface, Int32, Boolean)

Creates a typeface object that best matches the specified existing typeface and the specified weight and italic style

[Android.Runtime.Register("create", "(Landroid/graphics/Typeface;IZ)Landroid/graphics/Typeface;", "", ApiSince=28)]
public static Android.Graphics.Typeface Create (Android.Graphics.Typeface? family, int weight, bool italic);
[<Android.Runtime.Register("create", "(Landroid/graphics/Typeface;IZ)Landroid/graphics/Typeface;", "", ApiSince=28)>]
static member Create : Android.Graphics.Typeface * int * bool -> Android.Graphics.Typeface

Parameters

family
Typeface

An existing Typeface object. In case of null, the default typeface is used instead.

weight
Int32

The desired weight to be drawn.

italic
Boolean

true if italic style is desired to be drawn. Otherwise, false

Returns

Typeface

A Typeface object for drawing specified weight and italic style. Never returns null

Attributes

Remarks

Java documentation for android.graphics.Typeface.create(android.graphics.Typeface, int, boolean).

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