RB.SegmentedBar

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.SegmentedBar RB.SegmentedBar Gtk.Widget->RB.SegmentedBar

Subclasses:

None

Methods

Inherited:

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

Structs:

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

class

new ()

add_segment (title, percent, red, green, blue, alpha)

add_segment_default_color (title, percent)

set_value_formatter (formatter, *data)

update_segment (segment_index, percent)

Virtual Methods

Inherited:

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

Properties

Inherited:

Gtk.Widget (39)

Name

Type

Flags

Short Description

bar-height

int

r/w/c

height of the segmented bar

show-labels

bool

r/w

Whether the labels describing the various segments should be shown

show-reflection

bool

r/w

Whether there will be a reflection below the segmented bar

Style Properties

Inherited:

Gtk.Widget (17)

Signals

Inherited:

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

Fields

Inherited:

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

Name

Type

Access

Description

parent

Gtk.Widget

r

Class Details

class RB.SegmentedBar(**kwargs)
Bases:

Gtk.Widget

Abstract:

No

Structure:

RB.SegmentedBarClass

classmethod new()
Return type:

Gtk.Widget

add_segment(title, percent, red, green, blue, alpha)
Parameters:
Return type:

int

add_segment_default_color(title, percent)
Parameters:
Return type:

int

set_value_formatter(formatter, *data)
Parameters:

Sets a value formatter function to use for the bar.

update_segment(segment_index, percent)
Parameters:
  • segment_index (int) –

  • percent (float) –

Property Details

RB.SegmentedBar.props.bar_height
Name:

bar-height

Type:

int

Default Value:

26

Flags:

READABLE, WRITABLE, CONSTRUCT

Height of the segmented bar

RB.SegmentedBar.props.show_labels
Name:

show-labels

Type:

bool

Default Value:

True

Flags:

READABLE, WRITABLE

Set to True if you want labels describing the various segments to be shown.

RB.SegmentedBar.props.show_reflection
Name:

show-reflection

Type:

bool

Default Value:

True

Flags:

READABLE, WRITABLE

Set to True if you want a reflection to be shown below the segmented bar.