Show / Hide Table of Contents

Class ExcelTextFont

Used by Rich-text and Paragraphs.

Inheritance
System.Object
XmlHelper
ExcelTextFont
ExcelParagraph
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: OfficeOpenXml.Style
Assembly: EPPlus.dll
Syntax
public class ExcelTextFont : XmlHelper

Properties

Bold

If the font is bold

Declaration
public bool Bold { get; set; }
Property Value
Type Description
System.Boolean

Color

Sets the default color of the text. This sets the Fill to a SolidFill with the specified color. Use the Fill property for more options

Declaration
[Obsolete("Use the Fill property for more options")]
public Color Color { get; set; }
Property Value
Type Description
System.Drawing.Color

ComplexFont

The complex font typeface name

Declaration
public string ComplexFont { get; set; }
Property Value
Type Description
System.String

EastAsianFont

The East Asian typeface name

Declaration
public string EastAsianFont { get; set; }
Property Value
Type Description
System.String

Fill

A reference to the fill properties

Declaration
public ExcelDrawingFill Fill { get; }
Property Value
Type Description
ExcelDrawingFill

Italic

If the font is italic

Declaration
public bool Italic { get; set; }
Property Value
Type Description
System.Boolean

Kerning

Specifies the minimum font size at which character kerning occurs for this text run

Declaration
public double Kerning { get; set; }
Property Value
Type Description
System.Double

LatinFont

The latin typeface name

Declaration
public string LatinFont { get; set; }
Property Value
Type Description
System.String

Size

Font size

Declaration
public float Size { get; set; }
Property Value
Type Description
System.Single

Strike

Font strike out type

Declaration
public eStrikeType Strike { get; set; }
Property Value
Type Description
eStrikeType

UnderLine

The fonts underline style

Declaration
public eUnderLineType UnderLine { get; set; }
Property Value
Type Description
eUnderLineType

UnderLineColor

The fonts underline color

Declaration
public Color UnderLineColor { get; set; }
Property Value
Type Description
System.Drawing.Color

Methods

CreateTopNode()

Creates the top nodes of the collection

Declaration
protected void CreateTopNode()

SetFromFont(String, Single, Boolean, Boolean, Boolean, Boolean)

Set the font style properties

Declaration
public void SetFromFont(string name, float size, bool bold = false, bool italic = false, bool underline = false, bool strikeout = false)
Parameters
Type Name Description
System.String name

Font family name

System.Single size

Font size

System.Boolean bold
System.Boolean italic
System.Boolean underline
System.Boolean strikeout
In This Article
Back to top Generated by DocFX