Skip to content

Gtk.AccessibleHyperlink

class — extends GObject.Object, Accessible

Represents a link (i.e. a uri).

A widget that contains one or more links should implement the AccessibleHypertext interface and return GtkAccessibleHyperlink objects for each of the links.

Constructors

new

@classmethod
def new(cls, parent: AccessibleHypertext, index: int, uri: str, bounds: AccessibleTextRange) -> AccessibleHyperlink

Creates an accessible object that represents a hyperlink.

This is meant to be used with an implementation of the AccessibleHypertext interface.

Parameters:

  • parent — the parent
  • index — the index of this link in the parent
  • uri — the uri
  • bounds — the text range that the link occupies (or 0, 0)

Methods

set_platform_state

def set_platform_state(self, state: AccessiblePlatformState | int, enabled: bool) -> None

Sets a platform state on the accessible.

Parameters:

  • state — the platform state to change
  • enabled — the new value for the platform state