GtkSource.StyleSchemePreview

g GObject.GInterface GObject.GInterface Gtk.Accessible Gtk.Accessible GObject.GInterface->Gtk.Accessible Gtk.Actionable Gtk.Actionable GObject.GInterface->Gtk.Actionable 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 GtkSource.StyleSchemePreview GtkSource.StyleSchemePreview Gtk.Actionable->GtkSource.StyleSchemePreview Gtk.Buildable->Gtk.Widget Gtk.ConstraintTarget->Gtk.Widget Gtk.Widget->GtkSource.StyleSchemePreview

Subclasses:

None

Methods

Inherited:

Gtk.Widget (181), GObject.Object (37), Gtk.Accessible (15), Gtk.Buildable (1), Gtk.Actionable (5)

Structs:

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

class

new (scheme)

get_scheme ()

get_selected ()

set_selected (selected)

Virtual Methods

Inherited:

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

Properties

Inherited:

Gtk.Widget (34), Gtk.Accessible (1), Gtk.Actionable (2)

Name

Type

Flags

Short Description

scheme

GtkSource.StyleScheme

r/w/co

The style scheme to preview

selected

bool

r/w

If the preview should have the selected state

Signals

Inherited:

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

Name

Short Description

activate

Fields

Inherited:

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

Class Details

class GtkSource.StyleSchemePreview(**kwargs)
Bases:

Gtk.Widget, Gtk.Actionable

Abstract:

No

Structure:

GtkSource.StyleSchemePreviewClass

A preview widget for [class`StyleScheme`].

This widget provides a convenient [class`Gtk`.Widget] to preview a [class`StyleScheme`].

The [property`StyleSchemePreview`:py:data::selected<GtkSource.StyleSchemePreview.props.selected>] property can be used to manage the selection state of a single preview widget.

New in version 5.4.

classmethod new(scheme)
Parameters:

scheme (GtkSource.StyleScheme) – a GtkSource.StyleScheme

Returns:

a Gtk.Widget

Return type:

Gtk.Widget

Creates a new GtkSource.StyleSchemePreview to preview the style scheme provided in scheme.

New in version 5.4.

get_scheme()
Returns:

a GtkSource.StyleScheme

Return type:

GtkSource.StyleScheme

Gets the GtkSource.StyleScheme previewed by the widget.

New in version 5.4.

get_selected()
Return type:

bool

set_selected(selected)
Parameters:

selected (bool) –

Signal Details

GtkSource.StyleSchemePreview.signals.activate(style_scheme_preview)
Signal Name:

activate

Flags:

RUN_LAST

Parameters:

style_scheme_preview (GtkSource.StyleSchemePreview) – The object which received the signal

Property Details

GtkSource.StyleSchemePreview.props.scheme
Name:

scheme

Type:

GtkSource.StyleScheme

Default Value:

None

Flags:

READABLE, WRITABLE, CONSTRUCT_ONLY

The style scheme to preview

GtkSource.StyleSchemePreview.props.selected
Name:

selected

Type:

bool

Default Value:

False

Flags:

READABLE, WRITABLE

If the preview should have the selected state