RB.Rating

g Atk.ImplementorIface Atk.ImplementorIface Gtk.Widget Gtk.Widget Atk.ImplementorIface->Gtk.Widget GObject.GInterface GObject.GInterface GObject.GInterface->Atk.ImplementorIface Gtk.Buildable Gtk.Buildable GObject.GInterface->Gtk.Buildable GObject.InitiallyUnowned GObject.InitiallyUnowned GObject.InitiallyUnowned->Gtk.Widget GObject.Object GObject.Object GObject.Object->GObject.InitiallyUnowned Gtk.Buildable->Gtk.Widget RB.Rating RB.Rating Gtk.Widget->RB.Rating

Subclasses:

None

Methods

Inherited:

Gtk.Widget (278), GObject.Object (37), Gtk.Buildable (10)

Structs:

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

class

new ()

Virtual Methods

Inherited:

Gtk.Widget (82), GObject.Object (7), Gtk.Buildable (10)

do_adjust_rating (adjust)

do_rated (score)

do_set_rating (score)

Properties

Inherited:

Gtk.Widget (39)

Name

Type

Flags

Short Description

rating

float

r/w

Rating Value

Style Properties

Inherited:

Gtk.Widget (17)

Signals

Inherited:

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

Name

Short Description

adjust-rating

Action signal used to make a relative adjustment to the rating.

rated

Emitted when the user changes the rating.

set-rating

Action signal used to change the rating.

Fields

Inherited:

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

Name

Type

Access

Description

parent

Gtk.Widget

r

Class Details

class RB.Rating(**kwargs)
Bases:

Gtk.Widget

Abstract:

No

Structure:

RB.RatingClass

classmethod new()
Returns:

a new RB.Rating widget.

Return type:

RB.Rating

Creates a new rating widget

do_adjust_rating(adjust) virtual
Parameters:

adjust (float) –

Return type:

bool

do_rated(score) virtual
Parameters:

score (float) –

do_set_rating(score) virtual
Parameters:

score (float) –

Return type:

bool

Signal Details

RB.Rating.signals.adjust_rating(rating, adjust)
Signal Name:

adjust-rating

Flags:

RUN_LAST, ACTION

Parameters:
  • rating (RB.Rating) – The object which received the signal

  • adjust (float) – value to add to the rating

Action signal used to make a relative adjustment to the rating.

RB.Rating.signals.rated(rating, score)
Signal Name:

rated

Flags:

RUN_LAST

Parameters:
  • rating (RB.Rating) – The object which received the signal

  • score (float) – the new rating

Emitted when the user changes the rating.

RB.Rating.signals.set_rating(rating, score)
Signal Name:

set-rating

Flags:

RUN_LAST, ACTION

Parameters:
  • rating (RB.Rating) – The object which received the signal

  • score (float) – the new rating

Action signal used to change the rating.

Property Details

RB.Rating.props.rating
Name:

rating

Type:

float

Default Value:

2.5

Flags:

READABLE, WRITABLE

The rating displayed in the widget, as a floating point value between 0.0 and 5.0.