Annotation#

Added in version 5.18.

class Annotation(**properties: Any)#

Superclasses: Object

Represents an annotation added to View, it has a line property, description, icon and a style.

It will be displayed always at the end of a line.

If the style is GTK_SOURCE_ANNOTATION_STYLE_NONE it will use the same color as SpaceDrawer.

Constructors#

class Annotation
classmethod new(description: str | None, icon: Icon | None, line: int, style: AnnotationStyle) Annotation#
Parameters:
  • description – the text to display or None.

  • icon – the icon name to display or None.

  • line – the line where to display the annotation.

  • styleAnnotationStyle

Methods#

class Annotation
get_description() str#
get_icon() Icon | None#
get_line() int#
get_style() AnnotationStyle#

Properties#

class Annotation
props.description: str#

The type of the None singleton.

Added in version 5.18.

props.icon: Icon#

The type of the None singleton.

Added in version 5.18.

props.line: int#

The type of the None singleton.

Added in version 5.18.

props.style: AnnotationStyle#

The type of the None singleton.

Added in version 5.18.