Crate gtk4[][src]

Expand description

Rust GTK 4 bindings

This library contains safe Rust bindings for GTK 4, a multi-platform GUI toolkit. It is a part of gtk-rs.

Most of this documentation is generated from the C API. Until all parts of the documentation have been reviewed there will be incongruities with the actual Rust API.

For a gentle introduction to gtk-rs we recommend the online book GUI development with Rust and GTK 4.

See also

“Hello, World!” example program

GTK needs to be initialized before use by calling init. Creating an Application will call init for you.

The gtk4 crate is usually renamed to gtk. You can find an example in the features section for how to do this globally in your Cargo.toml.

use gtk::prelude::*;
use gtk::{Application, ApplicationWindow};

fn main() {
    let app = Application::builder()
        .application_id("org.example.HelloWorld")
        .build();

    app.connect_activate(|app| {
        // We create the main window.
        let window = ApplicationWindow::builder()
            .application(app)
            .default_width(320)
            .default_height(200)
            .title("Hello, World!")
            .build();

        // Show the window.
        window.show();
    });

    app.run();
}

The main loop

In a typical GTK application you set up the UI, assign signal handlers and run the main event loop.

use gtk::prelude::*;
use gtk::{Application, ApplicationWindow, Button};

fn main() {
    let application = Application::builder()
        .application_id("com.example.FirstGtkApp")
        .build();

    application.connect_activate(|app| {
        let window = ApplicationWindow::builder()
            .application(app)
            .title("First GTK Program")
            .default_width(350)
            .default_height(70)
            .build();

        let button = Button::with_label("Click me!");
        button.connect_clicked(|_| {
            eprintln!("Clicked!");
        });
        window.set_child(Some(&button));

        window.show();
    });

    application.run();
}

Threads

GTK is not thread-safe. Accordingly, none of this crate’s structs implement Send or Sync.

The thread where init was called is considered the main thread. OS X has its own notion of the main thread and init must be called on that thread. After successful initialization, calling any gtk or gdk functions (including init) from other threads will panic.

Any thread can schedule a closure to be run by the main loop on the main thread via glib::idle_add or glib::timeout_add. While working with GTK you might need the glib::idle_add_local or glib::timeout_add_local version without the Send bound. Those may only be called from the main thread.

Panics

The gtk and gdk crates have some run-time safety and contract checks.

  • Any constructor or free function will panic if called before init or on a non-main thread.

  • Any &str or &Path parameter with an interior null (\0) character will cause a panic.

  • Some functions will panic if supplied out-of-range integer parameters. All such cases will be documented individually but they are not yet.

  • A panic in a closure that handles signals or in any other closure passed to a gtk function will abort the process.

Features

Library versions

By default this crate provides only GTK 4.0 APIs. You can access additional functionality by selecting one of the v4_2, v4_4, etc. features.

Cargo.toml example:

[dependencies.gtk]
package = "gtk4"
version = "0.x.y"
features = ["v4_2"]

Take care when choosing the version to target: some of your users might not have easy access to the latest ones. The higher the version, the fewer users will have it installed.

Re-exports

pub use ffi;
pub use cairo;
pub use gdk;
pub use gdk_pixbuf;
pub use gio;
pub use glib;
pub use graphene;
pub use gsk;
pub use pango;

Modules

functions
prelude

Traits intended for blanket imports.

subclass

Structs

ATContext

ATContext is an abstract class provided by GTK to communicate to platform-specific assistive technologies API.

AboutDialog

The AboutDialog offers a simple way to display information about a program.

AboutDialogBuilder

A builder-pattern type to construct AboutDialog objects.

Accessible

Accessible is an interface for describing UI elements for Assistive Technologies.

ActionBar

ActionBar is designed to present contextual actions.

ActionBarBuilder

A builder-pattern type to construct ActionBar objects.

Actionable

The Actionable interface provides a convenient way of asscociating widgets with actions.

ActivateAction

A ShortcutAction that calls WidgetExt::activate().

Adjustment

Adjustment is a model for a numeric value.

AdjustmentBuilder

A builder-pattern type to construct Adjustment objects.

AlternativeTrigger

A ShortcutTrigger that combines two triggers.

AlternativeTriggerBuilder

A builder-pattern type to construct AlternativeTrigger objects.

AnyFilter

AnyFilter matches an item when at least one of its filters matches.

AppChooser

AppChooser is an interface for widgets which allow the user to choose an application.

AppChooserButton

The AppChooserButton lets the user select an application.

AppChooserButtonBuilder

A builder-pattern type to construct AppChooserButton objects.

AppChooserDialog

AppChooserDialog shows a AppChooserWidget inside a Dialog.

AppChooserDialogBuilder

A builder-pattern type to construct AppChooserDialog objects.

AppChooserWidget

AppChooserWidget is a widget for selecting applications.

AppChooserWidgetBuilder

A builder-pattern type to construct AppChooserWidget objects.

Application

Application is a high-level API for writing applications.

ApplicationBuilder

A builder-pattern type to construct Application objects.

ApplicationInhibitFlags

Types of user actions that may be blocked by Application.

ApplicationWindow

ApplicationWindow is a Window subclass that integrates with Application.

ApplicationWindowBuilder

A builder-pattern type to construct ApplicationWindow objects.

AspectFrame

AspectFrame preserves the aspect ratio of its child.

AspectFrameBuilder

A builder-pattern type to construct AspectFrame objects.

Assistant

Assistant is used to represent a complex as a series of steps.

AssistantBuilder

A builder-pattern type to construct Assistant objects.

AssistantPage

AssistantPage is an auxiliary object used by `GtkAssistant.

BinLayout

BinLayout is a LayoutManager subclass useful for create “bins” of widgets.

Bitset

A Bitset represents a set of unsigned integers.

BitsetIter

An opaque, stack-allocated struct for iterating over the elements of a Bitset.

BookmarkList

BookmarkList is a list model that wraps GBookmarkFile.

BookmarkListBuilder
BoolFilter

BoolFilter evaluates a boolean Expression to determine whether to include items.

BoolFilterBuilder

A builder-pattern type to construct BoolFilter objects.

Border

A struct that specifies a border around a rectangular area.

BorderBuilder
Box

The Box widget arranges child widgets into a single row or column.

BoxBuilder

A builder-pattern type to construct Box objects.

BoxLayout

BoxLayout is a layout manager that arranges children in a single row or column.

BoxLayoutBuilder

A builder-pattern type to construct BoxLayout objects.

Buildable

Buildable allows objects to extend and customize their deserialization from ui files.

Builder

A Builder reads XML descriptions of a user interface and instantiates the described objects.

BuilderClosureFlags

The list of flags that can be passed to Builder::create_closure().

BuilderListItemFactory

BuilderListItemFactory is a ListItemFactory that creates widgets by instantiating Builder UI templates.

BuilderScope

BuilderScope is an interface to provide language binding support to Builder.

Button

The Button widget is generally used to trigger a callback function that is called when the button is pressed.

ButtonBuilder

A builder-pattern type to construct Button objects.

Calendar

Calendar is a widget that displays a Gregorian calendar, one month at a time.

CalendarBuilder

A builder-pattern type to construct Calendar objects.

CallbackAction

A ShortcutAction that invokes a callback.

CellArea

An abstract class for laying out GtkCellRenderers

CellAreaBox

A cell area that renders GtkCellRenderers into a row or a column

CellAreaBoxBuilder

A builder-pattern type to construct CellAreaBox objects.

CellAreaContext

Stores geometrical information for a series of rows in a GtkCellArea

CellEditable

Interface for widgets that can be used for editing cells

CellLayout

An interface for packing cells

CellRenderer

An object for rendering a single cell

CellRendererAccel

Renders a keyboard accelerator in a cell

CellRendererAccelBuilder

A builder-pattern type to construct CellRendererAccel objects.

CellRendererCombo

Renders a combobox in a cell

CellRendererComboBuilder

A builder-pattern type to construct CellRendererCombo objects.

CellRendererPixbuf

Renders a pixbuf in a cell

CellRendererPixbufBuilder

A builder-pattern type to construct CellRendererPixbuf objects.

CellRendererProgress

Renders numbers as progress bars

CellRendererProgressBuilder

A builder-pattern type to construct CellRendererProgress objects.

CellRendererSpin

Renders a spin button in a cell

CellRendererSpinBuilder

A builder-pattern type to construct CellRendererSpin objects.

CellRendererSpinner

Renders a spinning animation in a cell

CellRendererSpinnerBuilder

A builder-pattern type to construct CellRendererSpinner objects.

CellRendererState

Tells how a cell is to be rendered.

CellRendererText

Renders text in a cell

CellRendererTextBuilder

A builder-pattern type to construct CellRendererText objects.

CellRendererToggle

Renders a toggle button in a cell

CellRendererToggleBuilder

A builder-pattern type to construct CellRendererToggle objects.

CellView

A widget displaying a single row of a GtkTreeModel

CellViewBuilder

A builder-pattern type to construct CellView objects.

CenterBox

CenterBox arranges three children in a row, keeping the middle child centered as well as possible.

CenterBoxBuilder

A builder-pattern type to construct CenterBox objects.

CenterLayout

CenterLayout is a layout manager that manages up to three children.

CheckButton

A CheckButton places a label next to an indicator.

CheckButtonBuilder

A builder-pattern type to construct CheckButton objects.

ClosureExpression

An expression using a custom GClosure to compute the value from its parameters.

ColorButton

The ColorButton allows to open a color chooser dialog to change the color.

ColorButtonBuilder

A builder-pattern type to construct ColorButton objects.

ColorChooser

ColorChooser is an interface that is implemented by widgets for choosing colors.

ColorChooserDialog

A dialog for choosing a color.

ColorChooserDialogBuilder

A builder-pattern type to construct ColorChooserDialog objects.

ColorChooserWidget

The ColorChooserWidget widget lets the user select a color.

ColorChooserWidgetBuilder

A builder-pattern type to construct ColorChooserWidget objects.

ColumnView

ColumnView presents a large dynamic list of items using multiple columns with headers.

ColumnViewBuilder

A builder-pattern type to construct ColumnView objects.

ColumnViewColumn

ColumnViewColumn represents the columns being added to ColumnView.

ColumnViewColumnBuilder

A builder-pattern type to construct ColumnViewColumn objects.

ComboBox

A ComboBox is a widget that allows the user to choose from a list of valid choices.

ComboBoxBuilder

A builder-pattern type to construct ComboBox objects.

ComboBoxText

A ComboBoxText is a simple variant of ComboBox for text-only use cases.

ComboBoxTextBuilder

A builder-pattern type to construct ComboBoxText objects.

ConstantExpression

A constant value in a Expression.

Constraint

Constraint describes a constraint between attributes of two widgets, expressed as a linear equation.

ConstraintBuilder

A builder-pattern type to construct Constraint objects.

ConstraintGuide

A ConstraintGuide is an invisible layout element in a ConstraintLayout.

ConstraintGuideBuilder

A builder-pattern type to construct ConstraintGuide objects.

ConstraintLayout

A layout manager using constraints to describe relations between widgets.

ConstraintLayoutChild

LayoutChild subclass for children in a ConstraintLayout.

ConstraintLayoutChildBuilder

A builder-pattern type to construct ConstraintLayoutChild objects.

ConstraintTarget

The ConstraintTarget interface is implemented by objects that can be used as source or target in Constraints.

CssLocation

Represents a location in a file or other source of data parsed by the CSS engine.

CssProvider

CssProvider is an object implementing the StyleProvider interface for CSS.

CssSection

Defines a part of a CSS document.

CustomFilter

CustomFilter determines whether to include items with a callback.

CustomSorter

CustomSorter is a Sorter implementation that sorts via a callback function.

DebugFlags
Dialog

Dialogs are a convenient way to prompt the user for a small amount of input.

DialogBuilder

A builder-pattern type to construct Dialog objects.

DialogFlags

Flags used to influence dialog construction.

DirectoryList

DirectoryList is a list model that wraps FileExtManual::enumerate_children_async().

DirectoryListBuilder
DragIcon

DragIcon is a Root implementation for drag icons.

DragIconBuilder

A builder-pattern type to construct DragIcon objects.

DragSource

DragSource is an event controller to initiate Drag-And-Drop operations.

DragSourceBuilder

A builder-pattern type to construct DragSource objects.

DrawingArea

DrawingArea is a widget that allows drawing with cairo.

DrawingAreaBuilder

A builder-pattern type to construct DrawingArea objects.

DropControllerMotion

DropControllerMotion is an event controller tracking the pointer during Drag-and-Drop operations.

DropControllerMotionBuilder

A builder-pattern type to construct DropControllerMotion objects.

DropDown

DropDown is a widget that allows the user to choose an item from a list of options.

DropDownBuilder

A builder-pattern type to construct DropDown objects.

DropTarget

DropTarget is an event controller to receive Drag-and-Drop operations.

DropTargetAsync

DropTargetAsync is an event controller to receive Drag-and-Drop operations, asynchronously.

DropTargetAsyncBuilder

A builder-pattern type to construct DropTargetAsync objects.

DropTargetBuilder

A builder-pattern type to construct DropTarget objects.

Editable

Editable is an interface for text editing widgets.

EditableLabel

A EditableLabel is a label that allows users to edit the text by switching to an “edit mode”.

EditableLabelBuilder

A builder-pattern type to construct EditableLabel objects.

EmojiChooser

The EmojiChooser is used by text widgets such as Entry or TextView to let users insert Emoji characters.

EmojiChooserBuilder

A builder-pattern type to construct EmojiChooser objects.

Entry

Entry is a single line text entry widget.

EntryBuffer

A EntryBuffer hold the text displayed in a Text widget.

EntryBufferBuilder

A builder-pattern type to construct EntryBuffer objects.

EntryBuilder

A builder-pattern type to construct Entry objects.

EntryCompletion

EntryCompletion is an auxiliary object to provide completion functionality for Entry.

EntryCompletionBuilder

A builder-pattern type to construct EntryCompletion objects.

EventController

EventController is the base class for event controllers.

EventControllerFocus

EventControllerFocus is an event controller to keep track of keyboard focus.

EventControllerFocusBuilder

A builder-pattern type to construct EventControllerFocus objects.

EventControllerKey

EventControllerKey is an event controller that provides access to key events.

EventControllerKeyBuilder

A builder-pattern type to construct EventControllerKey objects.

EventControllerLegacy

EventControllerLegacy is an event controller that provides raw access to the event stream.

EventControllerLegacyBuilder

A builder-pattern type to construct EventControllerLegacy objects.

EventControllerMotion

EventControllerMotion is an event controller tracking the pointer position.

EventControllerMotionBuilder

A builder-pattern type to construct EventControllerMotion objects.

EventControllerScroll

EventControllerScroll is an event controller that handles scroll events.

EventControllerScrollBuilder

A builder-pattern type to construct EventControllerScroll objects.

EventControllerScrollFlags

Describes the behavior of a EventControllerScroll.

EveryFilter

EveryFilter matches an item when each of its filters matches.

Expander

Expander allows the user to reveal its child by clicking on an expander triangle.

ExpanderBuilder

A builder-pattern type to construct Expander objects.

Expression

Expression provides a way to describe references to values.

ExpressionWatch

An opaque structure representing a watched Expression.

FileChooser

FileChooser is an interface that can be implemented by file selection widgets.

FileChooserDialog

FileChooserDialog is a dialog suitable for use with “File Open” or “File Save” commands.

FileChooserDialogBuilder

A builder-pattern type to construct FileChooserDialog objects.

FileChooserNative

FileChooserNative is an abstraction of a dialog suitable for use with “File Open” or “File Save as” commands.

FileChooserNativeBuilder

A builder-pattern type to construct FileChooserNative objects.

FileChooserWidget

FileChooserWidget is a widget for choosing files.

FileChooserWidgetBuilder

A builder-pattern type to construct FileChooserWidget objects.

FileFilter

FileFilter filters files by name or mime type.

Filter

A Filter object describes the filtering to be performed by a FilterListModel.

FilterListModel

FilterListModel is a list model that filters the elements of the underlying model according to a Filter.

FilterListModelBuilder

A builder-pattern type to construct FilterListModel objects.

Fixed

Fixed places its child widgets at fixed positions and with fixed sizes.

FixedBuilder

A builder-pattern type to construct Fixed objects.

FixedLayout

FixedLayout is a layout manager which can place child widgets at fixed positions.

FixedLayoutChild

LayoutChild subclass for children in a FixedLayout.

FixedLayoutChildBuilder

A builder-pattern type to construct FixedLayoutChild objects.

FlattenListModel

FlattenListModel is a list model that concatenates other list models.

FlowBox

A FlowBox puts child widgets in reflowing grid.

FlowBoxBuilder

A builder-pattern type to construct FlowBox objects.

FlowBoxChild

FlowBoxChild is the kind of widget that can be added to a FlowBox.

FlowBoxChildBuilder

A builder-pattern type to construct FlowBoxChild objects.

FontButton

The FontButton allows to open a font chooser dialog to change the font.

FontButtonBuilder

A builder-pattern type to construct FontButton objects.

FontChooser

FontChooser is an interface that can be implemented by widgets for choosing fonts.

FontChooserDialog

The FontChooserDialog widget is a dialog for selecting a font.

FontChooserDialogBuilder

A builder-pattern type to construct FontChooserDialog objects.

FontChooserLevel

Specifies the granularity of font selection that is desired in a FontChooser.

FontChooserWidget

The FontChooserWidget widget lets the user select a font.

FontChooserWidgetBuilder

A builder-pattern type to construct FontChooserWidget objects.

Frame

Frame is a widget that surrounds its child with a decorative frame and an optional label.

FrameBuilder

A builder-pattern type to construct Frame objects.

GLArea

GLArea is a widget that allows drawing with OpenGL.

GLAreaBuilder

A builder-pattern type to construct GLArea objects.

Gesture

Gesture is the base class for gesture recognition.

GestureClick

GestureClick is a Gesture implementation for clicks.

GestureClickBuilder

A builder-pattern type to construct GestureClick objects.

GestureDrag

GestureDrag is a Gesture implementation for drags.

GestureDragBuilder

A builder-pattern type to construct GestureDrag objects.

GestureLongPress

GestureLongPress is a Gesture for long presses.

GestureLongPressBuilder

A builder-pattern type to construct GestureLongPress objects.

GesturePan

GesturePan is a Gesture for pan gestures.

GesturePanBuilder

A builder-pattern type to construct GesturePan objects.

GestureRotate

GestureRotate is a Gesture for 2-finger rotations.

GestureRotateBuilder

A builder-pattern type to construct GestureRotate objects.

GestureSingle

GestureSingle is a GtkGestures subclass optimized for singe-touch and mouse gestures.

GestureSingleBuilder

A builder-pattern type to construct GestureSingle objects.

GestureStylus

GestureStylus is a Gesture specific to stylus input.

GestureStylusBuilder

A builder-pattern type to construct GestureStylus objects.

GestureSwipe

GestureSwipe is a Gesture for swipe gestures.

GestureSwipeBuilder

A builder-pattern type to construct GestureSwipe objects.

GestureZoom

GestureZoom is a Gesture for 2-finger pinch/zoom gestures.

GestureZoomBuilder

A builder-pattern type to construct GestureZoom objects.

Grid

Grid is a container which arranges its child widgets in rows and columns.

GridBuilder

A builder-pattern type to construct Grid objects.

GridLayout

GridLayout is a layout manager which arranges child widgets in rows and columns.

GridLayoutBuilder

A builder-pattern type to construct GridLayout objects.

GridLayoutChild

LayoutChild subclass for children in a GridLayout.

GridLayoutChildBuilder

A builder-pattern type to construct GridLayoutChild objects.

GridView

GridView presents a large dynamic grid of items.

GridViewBuilder

A builder-pattern type to construct GridView objects.

HeaderBar

HeaderBar is a widget for creating custom title bars for windows.

HeaderBarBuilder

A builder-pattern type to construct HeaderBar objects.

IMContext

IMContext defines the interface for GTK input methods.

IMContextSimple

IMContextSimple is an input method supporting table-based input methods.

IMContextSimpleBuilder

A builder-pattern type to construct IMContextSimple objects.

IMMulticontext

IMMulticontext is input method supporting multiple, switchable input methods.

IMMulticontextBuilder

A builder-pattern type to construct IMMulticontext objects.

IconLookupFlags

Used to specify options for IconTheme::lookup_icon().

IconPaintable

Contains information found when looking up an icon in IconTheme.

IconPaintableBuilder

A builder-pattern type to construct IconPaintable objects.

IconTheme

IconTheme provides a facility for loading themed icons.

IconThemeBuilder

A builder-pattern type to construct IconTheme objects.

IconView

IconView is a widget which displays data in a grid of icons.

IconViewBuilder

A builder-pattern type to construct IconView objects.

Image

The Image widget displays an image.

ImageBuilder

A builder-pattern type to construct Image objects.

InfoBar

InfoBar can be show messages to the user without a dialog.

InfoBarBuilder

A builder-pattern type to construct InfoBar objects.

Inhibit

Whether to propagate the signal to the default handler.

InputHints

Describes hints that might be taken into account by input methods or applications.

KeyvalTrigger

A ShortcutTrigger that triggers when a specific keyval and modifiers are pressed.

Label

The Label widget displays a small amount of text.

LabelBuilder

A builder-pattern type to construct Label objects.

LayoutChild

LayoutChild is the base class for objects that are meant to hold layout properties.

LayoutManager

Layout managers are delegate classes that handle the preferred size and the allocation of a widget.

LevelBar

LevelBar is a widget that can be used as a level indicator.

LevelBarBuilder

A builder-pattern type to construct LevelBar objects.

LinkButton

A LinkButton is a button with a hyperlink.

LinkButtonBuilder

A builder-pattern type to construct LinkButton objects.

ListBase

ListBase is the abstract base class for GTK’s list widgets.

ListBox

ListBox is a vertical list.

ListBoxBuilder

A builder-pattern type to construct ListBox objects.

ListBoxRow

ListBoxRow is the kind of widget that can be added to a ListBox.

ListBoxRowBuilder

A builder-pattern type to construct ListBoxRow objects.

ListItem

ListItem is used by list widgets to represent items in a GListModel.

ListItemFactory

A ListItemFactory creates widgets for the items taken from a GListModel.

ListStore

A list-like data structure that can be used with the GtkTreeView

ListView

ListView presents a large dynamic list of items.

ListViewBuilder

A builder-pattern type to construct ListView objects.

LockButton

LockButton is a widget to obtain and revoke authorizations needed to operate the controls.

LockButtonBuilder

A builder-pattern type to construct LockButton objects.

MapListModel

A MapListModel maps the items in a list model to different items.

MediaControls

MediaControls is a widget to show controls for a video.

MediaControlsBuilder

A builder-pattern type to construct MediaControls objects.

MediaFile

MediaFile implements MediaStream for files.

MediaStream

MediaStream is the integration point for media playback inside GTK.

MenuButton

The MenuButton widget is used to display a popup when clicked.

MenuButtonBuilder

A builder-pattern type to construct MenuButton objects.

MessageDialog

MessageDialog presents a dialog with some message text.

MessageDialogBuilder

A builder-pattern type to construct MessageDialog objects.

MnemonicAction

A ShortcutAction that calls WidgetExt::mnemonic_activate().

MnemonicTrigger

A ShortcutTrigger that triggers when a specific mnemonic is pressed.

MountOperation

MountOperation is an implementation of GMountOperation.

MountOperationBuilder

A builder-pattern type to construct MountOperation objects.

MultiFilter

MultiFilter is the base class for filters that combine multiple filters.

MultiSelection

MultiSelection is a SelectionModel that allows selecting multiple elements.

MultiSorter

MultiSorter combines multiple sorters by trying them in turn.

NamedAction

A ShortcutAction that activates an action by name.

Native

Native is the interface implemented by all widgets that have their own gdk::Surface.

NativeDialog

Native dialogs are platform dialogs that don’t use Dialog.

NeverTrigger

A ShortcutTrigger that never triggers.

NoSelection

NoSelection is a SelectionModel that does not allow selecting anything.

Notebook

Notebook is a container whose children are pages switched between using tabs.

NotebookBuilder

A builder-pattern type to construct Notebook objects.

NotebookPage

NotebookPage is an auxiliary object used by Notebook.

NothingAction

A ShortcutAction that does nothing.

NumericSorter

NumericSorter is a Sorter that compares numbers.

NumericSorterBuilder

A builder-pattern type to construct NumericSorter objects.

ObjectExpression

A GObject value in a Expression.

Orientable

The Orientable interface is implemented by all widgets that can be oriented horizontally or vertically.

Overlay

Overlay is a container which contains a single main child, on top of which it can place “overlay” widgets.

OverlayBuilder

A builder-pattern type to construct Overlay objects.

OverlayLayout

OverlayLayout is the layout manager used by Overlay.

OverlayLayoutChild

LayoutChild subclass for children in a OverlayLayout.

OverlayLayoutChildBuilder

A builder-pattern type to construct OverlayLayoutChild objects.

PadActionEntry

Struct defining a pad action entry.

PadController

PadController is an event controller for the pads found in drawing tablets.

PadControllerBuilder

A builder-pattern type to construct PadController objects.

PageRange

A range of pages to print.

PageSetup

A PageSetup object stores the page size, orientation and margins.

PageSetupUnixDialog

PageSetupUnixDialog implements a page setup dialog for platforms which don’t provide a native page setup dialog, like Unix.

PageSetupUnixDialogBuilder

A builder-pattern type to construct PageSetupUnixDialog objects.

Paned

Paned has two panes, arranged either horizontally or vertically.

PanedBuilder

A builder-pattern type to construct Paned objects.

PaperSize

PaperSize handles paper sizes.

ParamSpecExpression

A GParamSpec for properties holding a Expression.

PasswordEntry

PasswordEntry is an entry that has been tailored for entering secrets.

PasswordEntryBuilder

A builder-pattern type to construct PasswordEntry objects.

PickFlags

Flags that influence the behavior of WidgetExt::pick().

Picture

The Picture widget displays a gdk::Paintable.

PictureBuilder

A builder-pattern type to construct Picture objects.

Popover

Popover is a bubble-like context popup.

PopoverBuilder

A builder-pattern type to construct Popover objects.

PopoverMenu

PopoverMenu is a subclass of Popover that implements menu behavior.

PopoverMenuBar

PopoverMenuBar presents a horizontal bar of items that pop up popover menus when clicked.

PopoverMenuBarBuilder

A builder-pattern type to construct PopoverMenuBar objects.

PopoverMenuBuilder

A builder-pattern type to construct PopoverMenu objects.

PopoverMenuFlags

Flags that affect how popover menus are created from a menu model.

PrintCapabilities

Specifies which features the print dialog should offer.

PrintContext

A PrintContext encapsulates context information that is required when drawing pages for printing.

PrintJob

A PrintJob object represents a job that is sent to a printer.

PrintJobBuilder

A builder-pattern type to construct PrintJob objects.

PrintOperation

PrintOperation is the high-level, portable printing API.

PrintOperationBuilder

A builder-pattern type to construct PrintOperation objects.

PrintOperationPreview

PrintOperationPreview is the interface that is used to implement print preview.

PrintSettings

A PrintSettings object represents the settings of a print dialog in a system-independent way.

PrintUnixDialog

PrintUnixDialog implements a print dialog for platforms which don’t provide a native print dialog, like Unix.

PrintUnixDialogBuilder

A builder-pattern type to construct PrintUnixDialog objects.

Printer

A Printer object represents a printer.

PrinterBuilder

A builder-pattern type to construct Printer objects.

ProgressBar

ProgressBar is typically used to display the progress of a long running operation.

ProgressBarBuilder

A builder-pattern type to construct ProgressBar objects.

PropertyExpression

A GObject property value in a Expression.

Range

Range is the common base class for widgets which visualize an adjustment.

RecentData

Meta-data to be passed to RecentManagerExt::add_full() when registering a recently used resource.

RecentInfo

RecentInfo contains the metadata associated with an item in the recently used files list.

RecentManager

RecentManager manages and looks up recently used files.

Requisition

A Requisition-struct represents the desired size of a widget. See [GtkWidget’s geometry management section][geometry-management] for more information.

Revealer

A Revealer animates the transition of its child from invisible to visible.

RevealerBuilder

A builder-pattern type to construct Revealer objects.

Root

Root is the interface implemented by all widgets that can act as a toplevel widget.

Scale

A Scale is a slider control used to select a numeric value.

ScaleBuilder

A builder-pattern type to construct Scale objects.

ScaleButton

ScaleButton provides a button which pops up a scale widget.

ScaleButtonBuilder

A builder-pattern type to construct ScaleButton objects.

Scrollable

Scrollable is an interface for widgets with native scrolling ability.

Scrollbar

The Scrollbar widget is a horizontal or vertical scrollbar.

ScrollbarBuilder

A builder-pattern type to construct Scrollbar objects.

ScrolledWindow

ScrolledWindow is a container that makes its child scrollable.

ScrolledWindowBuilder

A builder-pattern type to construct ScrolledWindow objects.

SearchBar

SearchBar is a container made to have a search entry.

SearchBarBuilder

A builder-pattern type to construct SearchBar objects.

SearchEntry

SearchEntry is an entry widget that has been tailored for use as a search entry.

SearchEntryBuilder

A builder-pattern type to construct SearchEntry objects.

SelectionFilterModel

SelectionFilterModel is a list model that presents the selection from a SelectionModel.

SelectionModel

SelectionModel is an interface that add support for selection to list models.

Separator

Separator is a horizontal or vertical separator widget.

SeparatorBuilder

A builder-pattern type to construct Separator objects.

Settings

Settings provides a mechanism to share global settings between applications.

SettingsBuilder

A builder-pattern type to construct Settings objects.

Shortcut

A Shortcut describes a keyboard shortcut.

ShortcutAction

ShortcutAction encodes an action that can be triggered by a keyboard shortcut.

ShortcutActionFlags

List of flags that can be passed to action activation.

ShortcutBuilder

A builder-pattern type to construct Shortcut objects.

ShortcutController

ShortcutController is an event controller that manages shortcuts.

ShortcutControllerBuilder

A builder-pattern type to construct ShortcutController objects.

ShortcutLabel

ShortcutLabel displays a single keyboard shortcut or gesture.

ShortcutLabelBuilder

A builder-pattern type to construct ShortcutLabel objects.

ShortcutManager

The ShortcutManager interface is used to implement shortcut scopes.

ShortcutTrigger

ShortcutTrigger tracks how a Shortcut should be activated.

ShortcutsGroup

A ShortcutsGroup represents a group of related keyboard shortcuts or gestures.

ShortcutsGroupBuilder

A builder-pattern type to construct ShortcutsGroup objects.

ShortcutsSection

A ShortcutsSection collects all the keyboard shortcuts and gestures for a major application mode.

ShortcutsSectionBuilder

A builder-pattern type to construct ShortcutsSection objects.

ShortcutsShortcut

A ShortcutsShortcut represents a single keyboard shortcut or gesture with a short text.

ShortcutsShortcutBuilder

A builder-pattern type to construct ShortcutsShortcut objects.

ShortcutsWindow

A ShortcutsWindow shows information about the keyboard shortcuts and gestures of an application.

ShortcutsWindowBuilder

A builder-pattern type to construct ShortcutsWindow objects.

SignalAction

A ShortcutAction that emits a signal.

SignalListItemFactory

SignalListItemFactory is a ListItemFactory that emits signals to to manage listitems.

SingleSelection

SingleSelection is a SelectionModel that allows selecting a single item.

SingleSelectionBuilder

A builder-pattern type to construct SingleSelection objects.

SizeGroup

SizeGroup groups widgets together so they all request the same size.

SliceListModel

SliceListModel is a list model that presents a slice of another model.

SliceListModelBuilder

A builder-pattern type to construct SliceListModel objects.

Snapshot

Snapshot assists in creating GskRenderNodes for widgets.

SortListModel

SortListModel is a list model that sorts the elements of the underlying model according to a Sorter.

SortListModelBuilder

A builder-pattern type to construct SortListModel objects.

Sorter

Sorter is an object to describe sorting criteria.

SpinButton

A SpinButton is an ideal way to allow the user to set the value of some attribute.

SpinButtonBuilder

A builder-pattern type to construct SpinButton objects.

Spinner

A Spinner widget displays an icon-size spinning animation.

SpinnerBuilder

A builder-pattern type to construct Spinner objects.

Stack

Stack is a container which only shows one of its children at a time.

StackBuilder

A builder-pattern type to construct Stack objects.

StackPage

StackPage is an auxiliary class used by Stack.

StackSidebar

A StackSidebar uses a sidebar to switch between Stack pages.

StackSidebarBuilder

A builder-pattern type to construct StackSidebar objects.

StackSwitcher

The StackSwitcher shows a row of buttons to switch between Stack pages.

StackSwitcherBuilder

A builder-pattern type to construct StackSwitcher objects.

StateFlags

Describes a widget state.

Statusbar

A Statusbar widget is usually placed along the bottom of an application’s main Window.

StatusbarBuilder

A builder-pattern type to construct Statusbar objects.

StringFilter

StringFilter determines whether to include items by comparing strings to a fixed search term.

StringFilterBuilder

A builder-pattern type to construct StringFilter objects.

StringList

StringList is a list model that wraps an array of strings.

StringObject

StringObject is the type of items in a StringList.

StringSorter

StringSorter is a Sorter that compares strings.

StringSorterBuilder

A builder-pattern type to construct StringSorter objects.

StyleContext

StyleContext stores styling information affecting a widget.

StyleContextPrintFlags

Flags that modify the behavior of StyleContextExt::to_string().

StyleProvider

StyleProvider is an interface for style information used by StyleContext.

Switch

Switch is a “light switch” that has two states: on or off.

SwitchBuilder

A builder-pattern type to construct Switch objects.

Text

The Text widget is a single-line text entry widget.

TextBuffer

Stores text and attributes for display in a TextView.

TextBufferBuilder

A builder-pattern type to construct TextBuffer objects.

TextBuilder

A builder-pattern type to construct Text objects.

TextChildAnchor

A TextChildAnchor is a spot in a TextBuffer where child widgets can be “anchored”.

TextIter

An iterator for the contents of a TextBuffer.

TextMark

A TextMark is a position in a GtkTextbuffer that is preserved across modifications.

TextMarkBuilder

A builder-pattern type to construct TextMark objects.

TextSearchFlags

Flags affecting how a search is done.

TextTag

A tag that can be applied to text contained in a TextBuffer.

TextTagBuilder

A builder-pattern type to construct TextTag objects.

TextTagTable

The collection of tags in a TextBuffer

TextView

A widget that displays the contents of a TextBuffer.

TextViewBuilder

A builder-pattern type to construct TextView objects.

TickCallbackId
ToggleButton

A ToggleButton is a button which remains “pressed-in” when clicked.

ToggleButtonBuilder

A builder-pattern type to construct ToggleButton objects.

Tooltip

Tooltip is an object representing a widget tooltip.

TreeDragDest

Interface for Drag-and-Drop destinations in TreeView.

TreeDragSource

Interface for Drag-and-Drop destinations in TreeView.

TreeExpander

TreeExpander is a widget that provides an expander for a list.

TreeExpanderBuilder

A builder-pattern type to construct TreeExpander objects.

TreeIter

The TreeIter is the primary structure for accessing a TreeModel. Models are expected to put a unique integer in the stamp member, and put model-specific data in the three user_data members.

TreeListModel

TreeListModel is a list model that can create child models on demand.

TreeListModelBuilder

A builder-pattern type to construct TreeListModel objects.

TreeListRow

TreeListRow is used by TreeListModel to represent items.

TreeListRowSorter

TreeListRowSorter is a special-purpose sorter that will apply a given sorter to the levels in a tree.

TreeModel

The tree interface used by GtkTreeView

TreeModelFilter

A GtkTreeModel which hides parts of an underlying tree model

TreeModelFlags

These flags indicate various properties of a TreeModel.

TreeModelSort

A GtkTreeModel which makes an underlying tree model sortable

TreePath

An opaque structure representing a path to a row in a model.

TreeRowReference

A GtkTreeRowReference tracks model changes so that it always refers to the same row (a TreePath refers to a position, not a fixed row). Create a new GtkTreeRowReference with new().

TreeSelection

The selection object for GtkTreeView

TreeSortable

The interface for sortable models used by GtkTreeView

TreeStore

A tree-like data structure that can be used with the GtkTreeView

TreeView

A widget for displaying both trees and lists

TreeViewBuilder

A builder-pattern type to construct TreeView objects.

TreeViewColumn

A visible column in a GtkTreeView widget

TreeViewColumnBuilder

A builder-pattern type to construct TreeViewColumn objects.

Video

Video is a widget to show a MediaStream with media controls.

VideoBuilder

A builder-pattern type to construct Video objects.

Viewport

Viewport implements scrollability for widgets that lack their own scrolling capabilities.

ViewportBuilder

A builder-pattern type to construct Viewport objects.

VolumeButton

VolumeButton is a ScaleButton subclass tailored for volume control.

VolumeButtonBuilder

A builder-pattern type to construct VolumeButton objects.

Widget

The base class for all widgets.

WidgetPaintable

WidgetPaintable is a gdk::Paintable that displays the contents of a widget.

Window

A Window is a toplevel window which can contain other widgets.

WindowBuilder

A builder-pattern type to construct Window objects.

WindowControls

WindowControls shows window frame controls.

WindowControlsBuilder

A builder-pattern type to construct WindowControls objects.

WindowGroup

WindowGroup makes group of windows behave like separate applications.

WindowHandle

WindowHandle is a titlebar area widget.

WindowHandleBuilder

A builder-pattern type to construct WindowHandle objects.

Enums

AccessibleAutocomplete

The possible values for the AccessibleProperty::Autocomplete accessible property.

AccessibleInvalidState

The possible values for the AccessibleState::Invalid accessible state.

AccessibleProperty

The possible accessible properties of a Accessible.

AccessibleRelation

The possible accessible relations of a Accessible.

AccessibleRole

The accessible role for a Accessible implementation.

AccessibleSort

The possible values for the AccessibleProperty::Sort accessible property.

AccessibleState

The possible accessible states of a Accessible.

AccessibleTristate

The possible values for the AccessibleState::Pressed accessible state.

Align

Controls how a widget deals with extra space in a single dimension.

ArrowType

Used to indicate the direction in which an arrow should point.

AssistantPageType

Determines the page role inside a Assistant.

BaselinePosition

Baseline position in a row of widgets.

BorderStyle

Describes how the border of a UI element should be rendered.

BuilderError

Error codes that identify various errors that can occur while using Builder.

ButtonsType

Prebuilt sets of buttons for Dialog.

CellRendererAccelMode

Determines if the edited accelerators are GTK accelerators. If they are, consumed modifiers are suppressed, only accelerators accepted by GTK are allowed, and the accelerators are rendered in the same way as they are in menus.

CellRendererMode

Identifies how the user can interact with a particular cell.

ConstraintAttribute

The widget attributes that can be used when creating a Constraint.

ConstraintRelation

The relation between two terms of a constraint.

ConstraintStrength

The strength of a constraint, expressed as a symbolic constant.

ConstraintVflParserError

Domain for VFL parsing errors.

CornerType

Specifies which corner a child widget should be placed in when packed into a ScrolledWindow

CssParserError

Errors that can occur while parsing CSS.

CssParserWarning

Warnings that can occur while parsing CSS.

DeleteType

Passed to various keybinding signals for deleting text.

DirectionType

Focus movement types.

EditableProperties
EntryIconPosition

Specifies the side of the entry at which an icon is placed.

EventSequenceState

Describes the state of a gdk::EventSequence in a Gesture.

FileChooserAction

Describes whether a FileChooser is being used to open existing files or to save to a possibly new file.

FileChooserError

These identify the various errors that can occur while calling FileChooser functions.

FilterChange

Describes changes in a filter in more detail and allows objects using the filter to optimize refiltering items.

FilterMatch

Describes the known strictness of a filter.

IconSize

Built-in icon sizes.

IconThemeError

Error codes for IconTheme operations.

IconViewDropPosition

An enum for determining where a dropped item goes.

ImageType

Describes the image data representation used by a Image.

InputPurpose

Describes primary purpose of the input widget.

Justification

Used for justifying the text inside a Label widget.

LevelBarMode

Describes how LevelBar contents should be rendered.

License

The type of license for an application.

MessageType

The type of message being displayed in a MessageDialog.

MovementStep

Passed as argument to various keybinding signals for moving the cursor position.

NotebookTab

The parameter used in the action signals of Notebook.

NumberUpLayout

Used to determine the layout of pages on a sheet when printing multiple pages per sheet.

Ordering

Describes the way two values can be compared.

Orientation

Represents the orientation of widgets and other objects.

Overflow

Defines how content overflowing a given area should be handled.

PackType

Represents the packing location of a children in its parent.

PadActionType

The type of a pad action.

PageOrientation

See also PrintSettings::set_orientation().

PageSet

See also PrintJob::set_page_set().

PanDirection

Describes the panning direction of a GesturePan

PolicyType

Determines how the size should be computed to achieve the one of the visibility mode for the scrollbars.

PositionType

Describes which edge of a widget a certain feature is positioned at.

PrintDuplex

See also PrintSettings::set_duplex().

PrintError

Error codes that identify various errors that can occur while using the GTK printing support.

PrintOperationAction

Determines what action the print operation should perform.

PrintOperationResult

The result of a print operation.

PrintPages

See also PrintJob::set_pages()

PrintQuality

See also PrintSettings::set_quality().

PrintStatus

The status gives a rough indication of the completion of a running print operation.

PropagationLimit

Describes limits of a EventController for handling events targeting other widgets.

PropagationPhase

Describes the stage at which events are fed into a EventController.

RecentManagerError

Error codes for RecentManager operations

ResponseType

Predefined values for use as response ids in DialogExt::add_button().

RevealerTransitionType

These enumeration values describe the possible transitions when the child of a Revealer widget is shown or hidden.

ScrollStep

Passed as argument to various keybinding signals.

ScrollType

Scrolling types.

ScrollablePolicy

Defines the policy to be used in a scrollable widget when updating the scrolled window adjustments in a given orientation.

SelectionMode

Used to control what selections users are allowed to make.

SensitivityType

Determines how GTK handles the sensitivity of various controls, such as combo box buttons.

ShortcutScope

Describes where Shortcuts added to a ShortcutController get handled.

ShortcutType

GtkShortcutType specifies the kind of shortcut that is being described.

SizeGroupMode

The mode of the size group determines the directions in which the size group affects the requested sizes of its component widgets.

SizeRequestMode

Specifies a preference for height-for-width or width-for-height geometry management.

SortColumn
SortType

Determines the direction of a sort.

SorterChange

Describes changes in a sorter in more detail and allows users to optimize resorting.

SorterOrder

Describes the type of order that a Sorter may produce.

SpinButtonUpdatePolicy

Determines whether the spin button displays values outside the adjustment bounds.

SpinType

The values of the GtkSpinType enumeration are used to specify the change to make in SpinButton::spin().

StackTransitionType

Possible transitions between pages in a Stack widget.

StringFilterMatchMode

Specifies how search strings are matched inside text.

SystemSetting

Values that can be passed to the GtkWidgetClass.system_setting_changed vfunc.

TextDirection

Reading directions for text.

TextExtendSelection

Granularity types that extend the text selection. Use the signal::TextView::extend-selection signal to customize the selection.

TextViewLayer

Used to reference the layers of TextView for the purpose of customized drawing with the ::snapshot_layer vfunc.

TextWindowType

Used to reference the parts of TextView.

TreeViewColumnSizing

The sizing method the column uses to determine its width. Please note that Autosize are inefficient for large views, and can make columns appear choppy.

TreeViewDropPosition

An enum for determining where a dropped row goes.

TreeViewGridLines

Used to indicate which grid lines to draw in a tree view.

Unit

See also PrintSettings::set_paper_width().

WrapMode

Describes a type of line wrapping.

Constants

ACCESSIBLE_VALUE_UNDEFINED

An undefined value. The accessible attribute is either unset, or its value is undefined.

INVALID_LIST_POSITION
NONE_ACCESSIBLE
NONE_ACTIONABLE
NONE_ADJUSTMENT
NONE_APPLICATION
NONE_APPLICATION_WINDOW
NONE_APP_CHOOSER
NONE_BOX
NONE_BUILDABLE
NONE_BUILDER_SCOPE
NONE_BUTTON
NONE_CELL_AREA
NONE_CELL_AREA_CONTEXT
NONE_CELL_EDITABLE
NONE_CELL_LAYOUT
NONE_CELL_RENDERER
NONE_CELL_RENDERER_TEXT
NONE_CHECK_BUTTON
NONE_COLOR_CHOOSER
NONE_COMBO_BOX
NONE_CONSTRAINT_TARGET
NONE_DIALOG
NONE_DRAWING_AREA
NONE_EDITABLE
NONE_ENTRY
NONE_ENTRY_BUFFER
NONE_EVENT_CONTROLLER
NONE_EXPRESSION
NONE_FILE_CHOOSER
NONE_FILTER
NONE_FIXED
NONE_FLOW_BOX_CHILD
NONE_FONT_CHOOSER
NONE_FRAME
NONE_GESTURE
NONE_GESTURE_DRAG
NONE_GESTURE_SINGLE
NONE_GL_AREA
NONE_GRID
NONE_IM_CONTEXT
NONE_IM_CONTEXT_SIMPLE
NONE_IM_MULTICONTEXT
NONE_LAYOUT_CHILD
NONE_LAYOUT_MANAGER
NONE_LIST_BASE
NONE_LIST_BOX_ROW
NONE_LIST_ITEM_FACTORY
NONE_MEDIA_FILE
NONE_MEDIA_STREAM
NONE_MOUNT_OPERATION
NONE_MULTI_FILTER
NONE_NATIVE
NONE_NATIVE_DIALOG
NONE_ORIENTABLE
NONE_POPOVER
NONE_PRINT_OPERATION
NONE_PRINT_OPERATION_PREVIEW
NONE_RANGE
NONE_RECENT_MANAGER
NONE_ROOT
NONE_SCALE
NONE_SCALE_BUTTON
NONE_SCROLLABLE
NONE_SELECTION_MODEL
NONE_SHORTCUT_ACTION
NONE_SHORTCUT_MANAGER
NONE_SHORTCUT_TRIGGER
NONE_SORTER
NONE_STYLE_CONTEXT
NONE_STYLE_PROVIDER
NONE_TEXT_BUFFER
NONE_TEXT_CHILD_ANCHOR
NONE_TEXT_MARK
NONE_TEXT_TAG
NONE_TEXT_VIEW
NONE_TOGGLE_BUTTON
NONE_TREE_DRAG_DEST
NONE_TREE_DRAG_SOURCE
NONE_TREE_MODEL
NONE_TREE_MODEL_FILTER
NONE_TREE_MODEL_SORT
NONE_TREE_SORTABLE
NONE_TREE_VIEW
NONE_WIDGET
NONE_WINDOW
NONE_WINDOW_GROUP
PRIORITY_RESIZE

Use this priority for functionality related to size allocation.

STYLE_PROVIDER_PRIORITY_APPLICATION

A priority that can be used when adding a StyleProvider for application-specific style information.

STYLE_PROVIDER_PRIORITY_FALLBACK

The priority used for default style information that is used in the absence of themes.

STYLE_PROVIDER_PRIORITY_SETTINGS

The priority used for style information provided via Settings.

STYLE_PROVIDER_PRIORITY_THEME

The priority used for style information provided by themes.

STYLE_PROVIDER_PRIORITY_USER

The priority used for the style information from $XDG_CONFIG_HOME/gtk-4.0/gtk.css.

TEXT_VIEW_PRIORITY_VALIDATE

The priority at which the text view validates onscreen lines in an idle job in the background.

Statics

IM_MODULE_EXTENSION_POINT_NAME
LEVEL_BAR_OFFSET_FULL

The name used for the stock full offset included by LevelBar.

LEVEL_BAR_OFFSET_HIGH

The name used for the stock high offset included by LevelBar.

LEVEL_BAR_OFFSET_LOW

The name used for the stock low offset included by LevelBar.

MEDIA_FILE_EXTENSION_POINT_NAME
PAPER_NAME_A3

Name for the A3 paper size.

PAPER_NAME_A4

Name for the A4 paper size.

PAPER_NAME_A5

Name for the A5 paper size.

PAPER_NAME_B5

Name for the B5 paper size.

PAPER_NAME_EXECUTIVE

Name for the Executive paper size.

PAPER_NAME_LEGAL

Name for the Legal paper size.

PAPER_NAME_LETTER

Name for the Letter paper size.

PRINT_SETTINGS_COLLATE
PRINT_SETTINGS_DEFAULT_SOURCE
PRINT_SETTINGS_DITHER
PRINT_SETTINGS_DUPLEX
PRINT_SETTINGS_FINISHINGS
PRINT_SETTINGS_MEDIA_TYPE
PRINT_SETTINGS_NUMBER_UP
PRINT_SETTINGS_NUMBER_UP_LAYOUT
PRINT_SETTINGS_N_COPIES
PRINT_SETTINGS_ORIENTATION
PRINT_SETTINGS_OUTPUT_BASENAME

The key used by the “Print to file” printer to store the file name of the output without the path to the directory and the file extension.

PRINT_SETTINGS_OUTPUT_BIN
PRINT_SETTINGS_OUTPUT_DIR

The key used by the “Print to file” printer to store the directory to which the output should be written.

PRINT_SETTINGS_OUTPUT_FILE_FORMAT

The key used by the “Print to file” printer to store the format of the output. The supported values are “PS” and “PDF”.

PRINT_SETTINGS_OUTPUT_URI

The key used by the “Print to file” printer to store the URI to which the output should be written. GTK itself supports only “file://” URIs.

PRINT_SETTINGS_PAGE_RANGES
PRINT_SETTINGS_PAGE_SET
PRINT_SETTINGS_PAPER_FORMAT
PRINT_SETTINGS_PAPER_HEIGHT
PRINT_SETTINGS_PAPER_WIDTH
PRINT_SETTINGS_PRINTER
PRINT_SETTINGS_PRINTER_LPI
PRINT_SETTINGS_PRINT_PAGES
PRINT_SETTINGS_QUALITY
PRINT_SETTINGS_RESOLUTION
PRINT_SETTINGS_RESOLUTION_X
PRINT_SETTINGS_RESOLUTION_Y
PRINT_SETTINGS_REVERSE
PRINT_SETTINGS_SCALE
PRINT_SETTINGS_USE_COLOR
PRINT_SETTINGS_WIN32_DRIVER_EXTRA
PRINT_SETTINGS_WIN32_DRIVER_VERSION

Functions

accelerator_get_default_mod_mask

Gets the modifier mask.

accelerator_get_label

Converts an accelerator keyval and modifier mask into a string which can be used to represent the accelerator to the user.

accelerator_get_label_with_keycode

Converts an accelerator keyval and modifier mask into a string that can be displayed to the user.

accelerator_name

Converts an accelerator keyval and modifier mask into a string parseable by accelerator_parse().

accelerator_name_with_keycode

Converts an accelerator keyval and modifier mask into a string parseable by gtk_accelerator_parse_with_keycode().

accelerator_parse

Parses a string representing an accelerator.

accelerator_valid

Determines whether a given keyval and modifier mask constitute a valid keyboard accelerator.

binary_age

Returns the binary age as passed to libtool.

check_version

Checks that the GTK library in use is compatible with the given version.

debug_flags

Returns the GTK debug flags that are currently active.

default_language

Returns the pango::Language for the default language currently in effect. (Note that this can change over the life of an application.) The default language is derived from the current locale. It determines, for example, whether GTK uses the right-to-left or left-to-right text direction.

disable_setlocale

Prevents gtk_init and gtk_init_check from automatically calling setlocale (LC_ALL, "").

enumerate_printersLinux

Calls a function for all Printers.

hsv_to_rgb

Converts a color from HSV space to RGB.

init

Tries to initialize GTK.

interface_age

Returns the interface age as passed to libtool.

is_initialized

Returns true if GTK has been initialized.

is_initialized_main_thread

Returns true if GTK has been initialized and this is the main thread.

locale_direction

Get the direction of the current locale. This is the expected reading direction for text and UI.

major_version

Returns the major version number of the GTK library.

micro_version

Returns the micro version number of the GTK library.

minor_version

Returns the minor version number of the GTK library.

print_run_page_setup_dialog

Runs a page setup dialog, letting the user modify the values from page_setup. If the user cancels the dialog, the returned PageSetup is identical to the passed in page_setup, otherwise it contains the modifications done in the dialog.

print_run_page_setup_dialog_async

Runs a page setup dialog, letting the user modify the values from page_setup.

render_activity

Renders an activity indicator (such as in Spinner). The state StateFlags::CHECKED determines whether there is activity going on.

render_arrow

Renders an arrow pointing to angle.

render_background

Renders the background of an element.

render_check

Renders a checkmark (as in a CheckButton).

render_expander

Renders an expander (as used in TreeView and Expander) in the area defined by x, y, width, height. The state StateFlags::CHECKED determines whether the expander is collapsed or expanded.

render_focus

Renders a focus indicator on the rectangle determined by x, y, width, height.

render_frame

Renders a frame around the rectangle defined by x, y, width, height.

render_handle

Renders a handle (as in Paned and Window’s resize grip), in the rectangle determined by x, y, width, height.

render_icon

Renders the icon in texture at the specified x and y coordinates.

render_layout

Renders layout on the coordinates x, y

render_line

Renders a line from (x0, y0) to (x1, y1).

render_option

Renders an option mark (as in a radio button), the StateFlags::CHECKED state will determine whether the option is on or off, and StateFlags::INCONSISTENT whether it should be marked as undefined.

rgb_to_hsv

Converts a color from RGB space to HSV.

set_debug_flags

Sets the GTK debug flags.

set_initialized

Informs this crate that GTK has been initialized and the current thread is the main one.

show_about_dialog

A convenience function for showing an application’s about dialog.

show_uri

This function launches the default application for showing a given uri, or shows an error dialog if that fails.

test_accessible_assertion_message_role
test_accessible_has_property

Checks whether the Accessible has property set.

test_accessible_has_relation

Checks whether the Accessible has relation set.

test_accessible_has_role

Checks whether the property::Accessible::accessible-role of the accessible is role.

test_accessible_has_state

Checks whether the Accessible has state set.

test_list_all_types

Return the type ids that have been registered after calling test_register_all_types().

test_register_all_types

Force registration of all core GTK object types.

test_widget_wait_for_draw

Enters the main loop and waits for widget to be “drawn”.

tree_create_row_drag_content

Creates a content provider for dragging path from tree_model.

tree_get_row_drag_data

Obtains a tree_model and path from value of target type GTK_TYPE_TREE_ROW_DATA.

Type Definitions

Allocation