highlight_color property

Font.highlight_color property

Gets or sets the highlight (marker) color.

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

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

Examples

Shows how to format a run of text using its font property.

doc = aw.Document()
run = aw.Run(doc, "Hello world!")

font = run.font
font.name = "Courier New"
font.size = 36
font.highlight_color = drawing.Color.yellow

doc.first_section.body.first_paragraph.append_child(run)
doc.save(ARTIFACTS_DIR + "Font.create_formatted_run.docx")

See Also