NanoXLSX.Formatting 3.0.0
Loading...
Searching...
No Matches
NanoXLSX.Extensions.TextRun Class Reference

Represents a single text run with optional inline formatting. More...

Public Member Functions

 TextRun (string text, Font fontStyle=null)
 Constructor to create a text run with optional inline style.
TextRun Copy ()
 Creates a copy of the current text run.
override bool Equals (object obj)
 Equals override to compare text runs.
override int GetHashCode ()
 HashCode override for text runs.

Properties

string Text [get, set]
 Plain text of the run.
Font FontStyle [get, set]
 Font style applied to the text run.

Detailed Description

Represents a single text run with optional inline formatting.

Definition at line 17 of file TextRun.cs.

Constructor & Destructor Documentation

◆ TextRun()

NanoXLSX.Extensions.TextRun.TextRun ( string text,
Font fontStyle = null )

Constructor to create a text run with optional inline style.

Parameters
textPlain text
fontStyleOptional font style
Exceptions
Exceptions.FormatExceptionThrown when the text is null

Definition at line 48 of file TextRun.cs.

Member Function Documentation

◆ Copy()

TextRun NanoXLSX.Extensions.TextRun.Copy ( )

Creates a copy of the current text run.

Returns
Copy of the text run

Definition at line 58 of file TextRun.cs.

◆ Equals()

override bool NanoXLSX.Extensions.TextRun.Equals ( object obj)

Equals override to compare text runs.

Parameters
objOther object to compare
Returns
True, if the other object is equal

Definition at line 68 of file TextRun.cs.

◆ GetHashCode()

override int NanoXLSX.Extensions.TextRun.GetHashCode ( )

HashCode override for text runs.

Returns
Hash code of the current object

Definition at line 83 of file TextRun.cs.

Property Documentation

◆ FontStyle

Font NanoXLSX.Extensions.TextRun.FontStyle
getset

Font style applied to the text run.

Definition at line 40 of file TextRun.cs.

◆ Text

string NanoXLSX.Extensions.TextRun.Text
getset

Plain text of the run.

Exceptions
Exceptions.FormatExceptionThrown when the text is null

Definition at line 25 of file TextRun.cs.


The documentation for this class was generated from the following file: