underline_color property

Font.underline_color property

Gets or sets the color of the underline applied to the font.

@property
def underline_color(self) -> aspose.pydrawing.Color:
    ...

@underline_color.setter
def underline_color(self, value: aspose.pydrawing.Color):
    ...

Examples

Shows how to configure the style and color of a text underline.

doc = aw.Document()
builder = aw.DocumentBuilder(doc)

builder.font.underline = aw.Underline.DOTTED
builder.font.underline_color = drawing.Color.red

builder.writeln("Underlined text.")

doc.save(ARTIFACTS_DIR + "Font.underlines.docx")

See Also