ClapperGtk.Av

g ClapperGtk.Av ClapperGtk.Av GObject.GInterface GObject.GInterface Gtk.Accessible Gtk.Accessible GObject.GInterface->Gtk.Accessible Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable Gtk.ConstraintTarget Gtk.ConstraintTarget GObject.GInterface->Gtk.ConstraintTarget GObject.InitiallyUnowned GObject.InitiallyUnowned Gtk.Widget Gtk.Widget GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gtk.Accessible->Gtk.Widget Gtk.Buildable->Gtk.Widget Gtk.ConstraintTarget->Gtk.Widget Gtk.Widget->ClapperGtk.Av

Subclasses:

ClapperGtk.Audio, ClapperGtk.Video

Methods

Inherited:

Gtk.Widget (183), GObject.Object (37), Gtk.Accessible (18), Gtk.Buildable (1)

Structs:

Gtk.WidgetClass (18), GObject.ObjectClass (5)

get_auto_inhibit ()

get_inhibited ()

get_player ()

set_auto_inhibit (inhibit)

Virtual Methods

Inherited:

Gtk.Widget (25), GObject.Object (7), Gtk.Accessible (7), Gtk.Buildable (9)

Properties

Inherited:

Gtk.Widget (35), Gtk.Accessible (1)

Name

Type

Flags

Short Description

auto-inhibit

bool

r/w/en

inhibited

bool

r/en

player

Clapper.Player

r/en

Signals

Inherited:

Gtk.Widget (13), GObject.Object (1)

Fields

Inherited:

Gtk.Widget (13), GObject.Object (1)

Name

Type

Access

Description

parent_instance

Gtk.Widget

r

Class Details

class ClapperGtk.Av(**kwargs)
Bases:

Gtk.Widget

Abstract:

No

Structure:

ClapperGtk.AvClass

A base class for GTK audio and video widgets.

See its descendants: [class`ClapperGtk`.Audio] and [class`ClapperGtk`.Video].

Actions

ClapperGtk.Av defines a set of built-in actions:

```yaml

  • “av.toggle-play”: toggle play/pause

  • “av.play”: start/resume playback

  • “av.pause”: pause playback

  • “av.stop”: stop playback

  • “av.seek”: seek to position (variant “d”)

  • “av.seek-custom”: seek to position using seek method (variant “(di)”)

  • “av.toggle-mute”: toggle mute state

  • “av.set-mute”: set mute state (variant “b”)

  • “av.volume-up”: increase volume by 2%

  • “av.volume-down”: decrease volume by 2%

  • “av.set-volume”: set volume to specified value (variant “d”)

  • “av.speed-up”: increase speed (from 0.05x - 2x range to nearest quarter)

  • “av.speed-down”: decrease speed (from 0.05x - 2x range to nearest quarter)

  • “av.set-speed”: set speed to specified value (variant “d”)

  • “av.previous-item”: select previous item in queue

  • “av.next-item”: select next item in queue

  • “av.select-item”: select item at specified index in queue (variant “u”) ```

New in version 0.10.

get_auto_inhibit()
Returns:

True if enabled, False otherwise.

Return type:

bool

Get whether automatic session inhibit is enabled.

New in version 0.10.

get_inhibited()
Returns:

True if inhibited, False otherwise.

Return type:

bool

Get whether session is currently inhibited by [property`ClapperGtk`.Av:auto-inhibit].

New in version 0.10.

get_player()
Returns:

a Clapper.Player used by widget.

Return type:

Clapper.Player

Get Clapper.Player used by this ClapperGtk.Av instance.

New in version 0.10.

set_auto_inhibit(inhibit)
Parameters:

inhibit (bool) – whether to enable automatic session inhibit

Set whether widget should try to automatically inhibit session from idling (and possibly screen going black) when media is playing.

New in version 0.10.

Property Details

ClapperGtk.Av.props.auto_inhibit
Name:

auto-inhibit

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE, EXPLICIT_NOTIFY

Try to automatically inhibit session when media is playing.

ClapperGtk.Av.props.inhibited
Name:

inhibited

Type:

bool

Default Value:

False

Flags:

READABLE, EXPLICIT_NOTIFY

Get whether session is currently inhibited by playback.

ClapperGtk.Av.props.player
Name:

player

Type:

Clapper.Player

Default Value:

None

Flags:

READABLE, EXPLICIT_NOTIFY

A Clapper.Player used by widget.