• DR-IT Software
  • Products
  • Documentation
  • Product page
  • Examples
  • API reference
  • Support
Show / Hide Table of Contents

Class RichTextOptions

Rich-text layout options for Graphics.DrawRichText and Graphics.MeasureRichText. Carries a list of RichTextRun segments and default font properties.

Inheritance
object
RichTextOptions
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: DRIT.Drawing.Text
Assembly: DRIT.Drawing.dll
Syntax
public sealed class RichTextOptions

Constructors

RichTextOptions(FontFamily, float, FontStyle)

Initializes a new RichTextOptions with the specified default font family, size, and style.

Declaration
public RichTextOptions(FontFamily family, float emSize, FontStyle style = FontStyle.Regular)
Parameters
Type Name Description
FontFamily family
float emSize
FontStyle style

Properties

EmSize

Default em size for runs without a EmSize override.

Declaration
public float EmSize { get; }
Property Value
Type Description
float

Fallback

Fallback font chain override for this rich-text operation, or null to use FontFallback (or the system default).

Declaration
public FontFallbackChain? Fallback { get; set; }
Property Value
Type Description
FontFallbackChain

FontFamily

Default font family for runs without a FontFamily override.

Declaration
public FontFamily FontFamily { get; }
Property Value
Type Description
FontFamily

FontStyle

Default font style for runs without a FontStyle override.

Declaration
public FontStyle FontStyle { get; }
Property Value
Type Description
FontStyle

Runs

Rich text runs. Characters not covered by any run use the default font/size/style. Runs may overlap; later runs win for overlapping ranges (matches ImageSharp RichTextOptions.Runs semantics).

Declaration
public IList<RichTextRun> Runs { get; }
Property Value
Type Description
IList<RichTextRun>

Unit

Unit for EmSize and EmSize. Default Point.

Declaration
public GraphicsUnit Unit { get; set; }
Property Value
Type Description
GraphicsUnit
Back to top

DR-IT Software documentation

DR-IT Software · Products · Documentation index · Product page · Downloads · Support · Licensing

Generated by DocFX