GTK

GTK (formerly GIMP ToolKit and GTK+)[2] is a free and open-source cross-platform widget toolkit for creating graphical user interfaces (GUIs).[3] It is licensed under the terms of the GNU Lesser General Public License, allowing both free and proprietary software to use it. It is one of the most popular toolkits for the Wayland and X11 windowing systems.[4]

GTK
Original author(s)Spencer Kimball, Peter Mattis
Developer(s)The GNOME Project, eXperimental Computing Facility (XCF)
Initial releaseApril 14, 1998 (1998-04-14)
Stable release
4.6.6 / July 2, 2022 (2022-07-02)
Preview release
4.7.1 / July 13, 2022 (2022-07-13)
Repository
Written inC, CSS[1]
Operating systemLinux, Unix-like, macOS, Windows
TypeWidget toolkit
LicenseLGPLv2.1+
Websitegtk.org

The GTK team releases new versions on a regular basis.[5] GTK 4 and GTK 3 are maintained, while GTK 2 is end-of-life.[6]

Software architecture

Simplified software architecture of GTK. Pango, GDK, ATK, GIO, Cairo and GLib
GDK contains back-ends to X11, Wayland, Broadway (HTTP), Quartz, and GDI and relies on Cairo for the rendering. Its new SceneGraph is work-in-progress.

The GTK library contains a set of graphical control elements (widgets); version 3.22.16 contains 186 active and 36 deprecated widgets.[7] GTK is an object-oriented widget toolkit written in the programming language C; it uses GObject, that is the GLib object system, for the object orientation. While GTK is mainly for windowing systems based on X11 and Wayland, it works on other platforms, including Microsoft Windows (interfaced with the Windows API), and macOS (interfaced with Quartz). There is also an HTML5 back-end named Broadway.[8][9]

GTK can be configured to change the look of the widgets drawn; this is done using different display engines. Several display engines exist which try to emulate the look of the native widgets on the platform in use.

Starting with version 2.8, released in 2005, GTK began the transition to using Cairo to render most of its graphical control elements widgets.[10] Since GTK version 3.0, all rendering is done using Cairo.[11]

On 26 January 2018 at DevConf.cz, Matthias Clasen gave an overview of the current state of GTK 4 development, including a high-level explanation of how rendering and input worked in GTK 3, what changes are being made in GTK 4 (>3.90), and why.[12] On 6 February 2019 it was announced that GTK 4 will drop the “+” from the project's name.[2]

GTK Drawing Kit (GDK)

GDK acts as a wrapper around the low-level functions provided by the underlying windowing and graphics systems.

GDK is found in the /gdk directory.

GTK Scene Graph Kit (GSK)

GSK is the rendering and scene graph API for GTK. GSK lies between the graphical control elements (widgets) and the rendering. GSK was finally merged into GTK version 3.90 released March 2017.

GSK is found in the /gsk directory.

GtkInspector

GtkInspector was introduced with version 3.14.[13][14] GtkInspector can only be invoked after installing the development package libgtk-3-dev/gtk+-devel.

GUI designers

There are several GUI designers for GTK. The following projects are active as of July 2011:

  • Glade, supports GtkBuilder, which is a GTK built-in GUI description format.
  • Gazpacho, GUI builder for the GTK toolkit written in Python[15]
  • Crow Designer, relies on its own GuiXml format and GuiLoader library.[16]
  • Stetic, part of MonoDevelop, oriented toward Gtk#.
  • Gambas since version 2.0 atop BASIC
  • Xojo on Linux
  • Lazarus on Linux defaults to interfacing with GTK 2

GtkBuilder

GtkBuilder allows user interfaces to be designed without writing code. The interface is described in an Extensible Markup Language (XML) file, which is then loaded at runtime and the objects created automatically. The Glade Interface Designer allows creation of the user interface in a what you see is what you get (WYSIWYG) manner. The description of the user interface is independent from the programming language being used.

Language bindings

Language bindings are available for using GTK from languages other than C, including C++, Genie, JavaScript, Perl, Python, Vala, and others.[17]

GtkSharp, not to be confused with Gtk#, supports GTK 3.

Gtk#

Gtk#
Developer(s)Xamarin
Initial releaseMarch 12, 2004 (2004-03-12)
Stable release
2.12.41[18] / September 22, 2016 (2016-09-22)
Preview release
2.99.3 (for GTK3)[18] / June 6, 2014 (2014-06-06)
Repository
Written inC#, XML, Perl, C
Operating systemWindows, macOS, Linux
TypeWidget toolkit
LicenseGNU Lesser General Public License
Websitemono-project.com/GtkSharp

Gtk# is a set of .NET Framework bindings for the GTK graphical user interface (GUI) toolkit and assorted GNOME libraries. The library facilitates building graphical GNOME applications using Mono or any other compliant Common Language Runtime (CLR). Gtk# is an event-driven system like any other modern windowing library where every widget allows associating handler methods, which get called when certain events occur.

Applications built using Gtk# will run on many platforms including Linux, Windows and macOS. The Mono packages for Windows include GTK, Gtk# and a native theme to make applications look like native Windows applications. Starting with Mono 1.9, running Gtk# applications on macOS no longer requires running an X11 server.[19]

Glade Interface Designer can be used with the Glade# bindings to easily design GUI applications. A GUI designer named Stetic is integrated with the MonoDevelop integrated development environment (IDE).

In addition to support the standard GTK/GNOME stack of development tools, the gtk-dotnet.dll assembly provides a bridge to consume functionality available on the .NET stack. At this point this includes the functionality to use System.Drawing to draw on a widget.

As of September 2020, Gtk# support for Gtk3 remains in the preview phase and forked projects, such as GtkSharp, have been founded to provide full Gtk3 support for C# and other CLI languages. The lack of a released version of Gtk# with support for Gtk3 was cited as a reason to remove the Banshee media player in Ubuntu 12.04.[20]

Development

GTK is mainly developed by The GNOME Project, which also develops the GNOME Development Platform and the GNOME Desktop Environment.[21]

GTK development is loosely managed. Discussion chiefly occurs on several public mailing lists.[22] GNOME developers and users gather at an annual GNOME Users And Developers European Conference GUADEC meeting to discuss GNOME's current state and future direction.[23] GNOME incorporates standards and programs from freedesktop.org to better interoperate with other desktops.

GTK is mainly written in C.[24] Many language bindings are available.

On 1 September 2016 a post on the GTK development blog denoted, among other things, the future numbering scheme of GTK.[25] GTK version 3.22, released in Autumn 2016, was planned to be the last 3.x release, although version 3.24 followed in Fall 2018 with the delay of GTK 4.[26] The development of GTK 4 used version names 3.90, 3.92, etc. until the first GTK 4.0 stable release was launched in December 2020.[27] Despite the first stable GTK 4 release, some applications using GTK still rely on GTK 2. For example, as of January 2022, GIMP is still being ported to GTK 3.[28]

Build automation

GTK (and GNOME, GLib, etc.) formerly utilized the GNU Build System (named Autotools) as the build automation system of choice.

Since 14 Aug 2017, the master branch of GTK has been built with Meson, and the Autotools build system files have been dropped.[29]

Criticism

The most common criticism of GTK is the lack of backward-compatibility in major updates, most notably in the application programming interface (API)[30] and theming.[31]

The compatibility breaks between minor releases during the GTK 3.x development cycle was explained by Benjamin Otte as due to strong pressures to innovate, such as providing the features modern users expect and supporting the increasingly influential Wayland display server protocol. With the release of GTK 4, the pressure from the need to innovate will have been released and the balance between stability and innovation will tip toward stability.[32] Similarly, recent changes to theming are specifically intended to improve and stabilise that part of the API, meaning some investment now should be rewarded later.

  • Dirk Hohndel, codeveloper of Subsurface and member of Intel's Open-Source Technology Center, criticized the GTK developers for being abrasive and ignoring most community requests.[33]
  • Hong Jen Yee, developer of LXDE (the GTK version of which was dropped and all efforts focused on the Qt port), expressed disdain for version 3 of the GTK toolkit's radical API changes and increased memory usage, and ported PCMan File Manager (PCManFM) to Qt. PCManFM is being developed with a GTK and with a Qt backend at the same time.[34]
  • The Audacious music player moved to Qt in version 3.6.[35] The reasons stated by the developers for this include a transition to client-side window decorations, which they claim cause the application to look "GNOME-y and out of place."[36]
  • Wireshark has switched to Qt due to not having a good experience with GTK's cross-platform support.[37]

Use

The GTK support for Wayland, co-requisites applications to be adapted to Wayland also
Screenshot of GIMP 2.8 - GTK is responsible for managing the interface components of the program, including the menus, buttons, and input fields.

Applications

Some notable applications that use GTK as a widget toolkit include:

Desktop environments

Several desktop environments utilize GTK as the widget toolkit.

Current

  • GNOME, based on GTK, meaning that programs native to GNOME use GTK
  • Budgie, built from scratch for the SolusOS successor, Solus Operating System
  • Cinnamon, a fork of GNOME 3 which uses GTK version 3
  • MATE, a fork of GNOME 2 which uses GTK 3 since version 1.18
  • Xfce, based on GTK 3 since version 4.14
  • Pantheon uses GTK 3 exclusively, being developed by elementary OS
  • Sugar, a desktop environment for youth primary education, which uses GTK, especially PyGTK
  • Phosh, a mobile UI designed for PureOS
  • LXDE (Lightweight X11 Desktop Environment) is based on GTK 2

Inactive

  • Unity, the former default desktop environment of Ubuntu
  • Access Linux Platform (successor of the Palm OS PDA platform)
  • Consort, the GNOME 3.4 Fallback Mode – fork from SolusOS
  • GPE, the GPE Palmtop Environment
  • ROX Desktop, a lightweight desktop, with features from the GUI of RISC OS

Miscellaneous

GTK programs can be run on desktop environments based on X11 and Wayland, or window managers even those not made with GTK, provided the needed libraries are installed; this includes macOS if X11.app is installed. GTK can be also run on Microsoft Windows, where it is used by some popular cross-platform applications like Pidgin and GIMP. wxWidgets, a cross-platform GUI tool-kit, uses GTK on Linux by default.[38] Other ports include DirectFB (used by the Debian installer, for example) and ncurses.[39]

Window managers

The following window managers use GTK:

  • Aewm
  • AfterStep
  • Amaterus
  • Consortium
  • IceWM
  • Marco
  • Metacity
  • Muffin
  • Mutter
  • Sawfish
  • Wmg
  • Xfwm

GtkSourceView

For syntax highlighting there is GtkSourceView, "source code editing widget". GtkSourceView is maintained by GNOME separately from GTK as a library: gtksourceview. There are plans to rename to gsv.

GtkSpell

GtkSpell is a library separate from GTK. GtkSpell depends on GTK and Enchant. Enchant is a wrapper for ispell, hunspell, etc., the actual spell checker engine/software. GtkSpell uses GTK's GtkTextView widget, to highlight misspelled words and offer replacement.

Example

Documentation is available here:

The following code presents a graphical GTK hello-world program in the C programming language. This program has a window with the title "Hello, world!" and a label with similar text.

// helloworld.c
#include <gtk/gtk.h>

/* Callback that will be called when the application is activated */
static void
activate_callback(GApplication *app, gpointer user_data)
{
    GtkWidget *window;
    GtkWidget *label;

    /* Create the main, top level window */
    window = gtk_window_new();

    /* Give it the title */
    gtk_window_set_title(GTK_WINDOW(window), "Hello, world!");

    /* Set the window's default size */
    gtk_window_set_default_size(GTK_WINDOW(window), 200, 100);

    /* Assign the variable "label" to a new GTK label,
     * with the text "Hello, world!" */
    label = gtk_label_new("Hello, world!");

    /* Plot the label onto the main window */
    gtk_window_set_child(GTK_WINDOW(window), label);

    /* Make the application aware of the window.
     * The application process will continue to run until all
     * windows are closed */
    gtk_application_add_window(GTK_APPLICATION(app), GTK_WINDOW(window));

    /* Make sure that everything, window and label, are visible */
    gtk_widget_show(window);
}

int main (int argc, char *argv[])
{
    /* Create our test application */
    GtkApplication *application = gtk_application_new("org.wikipedia.gtktest", 0);

    /* Connect our handler to the "activate" callback, which will be called
     * when the application is activated by the user, e.g. on first start */
    g_signal_connect(application, "activate", G_CALLBACK(activate_callback), NULL);

    /* Run the application and return its status */
    return g_application_run(G_APPLICATION(application), argc, argv);
}

Needs installing the libraries first in Debian or derivatives: $ sudo apt-get install libgtk-4-dev

Using pkg-config in a Unix shell, this code can be compiled with the following command: $ cc -Wall $(pkg-config --cflags --libs gtk4) helloworld.c -o helloworld

Invoke the program: $ ./helloworld

History

Linux

GTK was originally designed and used in the GNU Image Manipulation Program (GIMP) as a replacement of the Motif toolkit; at some point Peter Mattis became disenchanted with Motif and began to write his own GUI toolkit named the GIMP toolkit and had successfully replaced Motif by the 0.60 release of GIMP.[40] Finally GTK was re-written to be object-oriented and was renamed GTK+.[41] This was first used in the 0.99 release of GIMP. GTK was subsequently adopted for maintenance by the GNOME Foundation, which uses it in the GNOME desktop environment.

The GTK 2.0.0 release series introduced new features which include improved text rendering using Pango, a new theme engine, improved accessibility using the Accessibility Toolkit, transition to Unicode using UTF-8 strings, and a more flexible API. Starting with version 2.8, GTK 2 depends on the Cairo graphics library for rendering vector graphics.

GTK version 3.0.0 included revised input device handling, support for themes written with CSS-like syntax, and the ability to receive information about other opened GTK applications.

The '+' was dropped returning to simply 'GTK' in February 2019 during a Hackathon.[42]

macOS

With Quartz-backend[43] GTK is available in macOS.[44]

Windows

  • After GTK 2.24.10 and 3.6.4 Development of Windows with Installer was closed by Gnome. Installation of MSYS2 on Windows is a good way to use actual GTK.[45]
  • GTK 2.24.10 and 3.6.4 is available in Internet, but very buggy and limited against actual versions.[46][47]
  • A version for Windows 64-bit is prepared by Tom Schoonjans with 2.24.33 (actual like Linux) and 3.24.24 (actual like Linux) from January 2021 available.[48]
  • Windows 10's Fall Creators Update includes Windows Subsystem for Linux (WSL). With Linux distributions like Ubuntu or Debian available from the Microsoft Store and an X server like Xming or VcXsvr, thousands of programs like GTK 2 or 3 can run with X or terminal support.

OpenVMS

HP stated that their goal was to merge the needed OpenVMS changes into the GTK Version 1.3 development stream,[49] however this never materialised. The latest version of GTK for OpenVMS is version 1.2.10.[50]

GTK 4

One of the cardinal novelties implemented during the GTK 4 development cycle (i.e. GTK 3.92, etc.) has been the delegation of functionality to ancillary objects instead of encoding it into the base classes provided by GTK.

  • the event handling from signal handlers described by GtkWidget is delegated to event controllers
  • the rendering is delegated to GtkSnapshot objects
  • the layout mechanism from GtkWidget is delegated to GtkLayoutManager

In 2018-Jan-26 at DevConf.cz Matthias Clasen gave an overview of the then current state of GTK 4 development, including a high-level explanation of how rendering and input worked in GTK 3, what changes were being made to GTK 4, and the reasons for those changes. Examples of things that have become possible with GTK 4 were given as well.[51]

Releases

Legend:
Old version
Older version, still maintained
Latest version
Latest preview version
Future release
Release series Initial release Major enhancements Latest minor version
Old version, no longer maintained: 1.0 1998-04-13[52] First stable version 1.0.6
Old version, no longer maintained: 1.2 1999-02-25[53] New widgets:
  • GtkFontSelector
  • GtkPacker
  • GtkItemFactory
  • GtkCTree
  • GtkInvisible
  • GtkCalendar
  • GtkLayout
  • GtkPlug
  • GtkSocket
1.2.10
Old version, no longer maintained: 2.0 2002-03-11[54] GObject

Overall support for UTF-8

2.0.9
Old version, no longer maintained: 2.2 2002-12-22[55] Multihead support 2.2.4
Old version, no longer maintained: 2.4 2004-03-16[56] New widgets:
  • GtkFileChooser
  • GtkComboBox
  • GtkComboBoxEntry
  • GtkExpander
  • GtkFontButton
  • GtkColorButton
2.4.14
Old version, no longer maintained: 2.6 2004-12-16[57] New widgets:
  • GtkIconView
  • GtkAboutDialog
  • GtkCellView

The last to support Windows 98/Me

2.6.10
Old version, no longer maintained: 2.8 2005-08-13[58] Most widgets are rendered by Cairo 2.8.20
Old version, no longer maintained: 2.10 2006-07-03[59] New widgets:
  • GtkStatusIcon
  • GtkAssistant
  • GtkLinkButton
  • GtkRecentChooser

Print support: GtkPrintOperation

2.10.14
Old version, no longer maintained: 2.12 2007-09-14[60] GtkBuilder 2.12.12
Old version, no longer maintained: 2.14 2008-09-04[61] JPEG 2000 load support 2.14.7
Old version, no longer maintained: 2.16 2009-03-13[62] New widget: GtkOrientable

Caps Lock warning in password entry

Improvements on GtkScale, GtkStatusIcon, GtkFileChooser

2.16.6
Old version, no longer maintained: 2.18 2009-09-23[63] New widget: GtkInfoBar

Improvement on file chooser, printing

To remove much of the necessary IPC between the X11 application and the X11 server, GDK is rewritten (mainly by Alexander Larsson) to use "client-side windows", i.e., the GdkWindow, which every widget must have, belongs now to the client

2.18.9
Old version, no longer maintained: 2.20 2010-03-23[64] New widgets:
  • GtkSpinner
  • GtkToolPalette
  • GtkOffscreenWindow

Improvement on file chooser, keyboard handling, GDK

Introspection data is now included in GTK

2.20.1
Old version, no longer maintained: 2.22 2010-09-23[65] GdkPixbuf moved to separate module

Most GDK drawing are based on Cairo

Many internal data are now private and can be sealed in preparation to GTK 3

2.22.1
Old version, no longer maintained: 2.24 2011-01-30[66] New widget: GtkComboBoxText which had previously been a custom widget shipped with Gtkmm

The CUPS print backend can send print jobs as PDF

GtkBuilder has gained support for text tags and menu toolbuttons and many introspection annotation fixes were added

Migrating from GTK+ 2.x to GTK+ 3

2.24.32
(2018-01-08)
Old version, no longer maintained: 3.0 2011-02-10[67] Development and design of the GTK 3 release of the toolkit started in February 2009 during the GTK Theming Hackfest held in Dublin[68]
  • The first draft of the development roadmap was released on 9 April 2009[69]

Completed mostly Project Ridley

  • the attempt to consolidate several libraries that were external to GTK+
  • including libgnome, libgnomeui, libgnomeprint22, libgnomeprintui22, libglade, libgnomecanvas, libegg, libeel, gtkglext, and libsexy[70]

All the rendering is done using Cairo

GDK became more X11 agnostic

XInput2, theme API is based on Cascading Style Sheets (CSS), worsening the achievable performance for 60 Hz frame rates

3.0.12
Old version, no longer maintained: 3.2 2011-09-25[71] New widgets:
  • GtkLockButton
  • GtkOverlay

New Font Chooser dialog

New experimental backends:

3.2.4
Old version, no longer maintained: 3.4 2012-03-26[72] Menu support in GtkApplication

A new color chooser

Added support for touch devices

Added support for smooth scrolling

GtkScrolledWindow will do kinetic scrolling with touch devices

macOS support is improved

This is the first version of GTK 3 that works well on Windows

The Wayland backend is updated to the current Wayland version

Spin buttons have received a new look

Accessibility: the treeview accessible support is rewritten

More complete CSS theming support

3.4.4
Old version, no longer maintained: 3.6 2012-09-24[73] New widgets:
  • GtkSearchEntry
  • GtkMenuButton
  • GtkLevelBar

Vertical spin buttons

CSS animations, blur shadows

Support for cross-fading and transitions in themes

3.6.5
Old version, no longer maintained: 3.8 2013-03-25[74] Wayland 1.0 stable support

Support for the broadwayd server

Improved theming

Better geometry management

Touch improvements

Support with the window manager for the frame synchronization protocol

GdkFrameClock added[75]

3.8.9
Old version, no longer maintained: 3.10 2013-09-23[76] New widgets:
  • GtkHeaderBar
  • GtkPlacesSidebar
  • GtkStack
  • GtkStackSwitcher
  • GtkRevealer
  • GtkSearchBar
  • GtkListBox

Support for Wayland 1.2

  • maximization
  • animated cursors
  • multiple monitors
  • settings
  • custom surfaces
  • frame synchronization

Added:

  • client-side decorations
  • scaled output support on high-dpi screens
  • fine-adjustment mode for scrolling

Removed:

  • support for the Motif DND protocol
  • support for multiple screens per display
  • gdk_window_get_display
  • gtk_widget_push_composite_child

Tear-off menu-items, plus many GTK settings

The modern GTK drawing model

3.10.9
Old version, no longer maintained: 3.12 2014-03-25[77] Client-side decorations[78]

Support for Wayland 1.5

New widget: GtkPopover (an alternative to menus and dialogs)

3.12.2
Old version, no longer maintained: 3.14 2014-09-22[79] GtkInspector (a copy of gtkparasite) introduced[80][81]

Improved support for gestures/multi-touch merged[82][83]

Deprecated:[84]

  • GtkMisc
  • GtkAlignment
  • GtkArrow
  • GdkColor
  • Style regions
  • support for .icon files
  • gdk_window_flush
  • drawing outside of begin/end paint

Most widgets converted to use gestures internally

Wayland supports GNOME Shell classic mode[85]

3.14.15
Old version, no longer maintained: 3.16 2015-03-22[86] GDK supports rendering windows using OpenGL for X11 and Wayland using libepoxy

New widgets:

  • GtkGLArea
  • GtkStackSidebar
  • GtkModelButton
  • GtkPopoverMenu

Scrolling overhauled (scrollbar hidden by default[87])

Experimental Mir backend[88]

3.16.7
Old version, no longer maintained: 3.18 2015-09-23[89] Add CSS node infrastructure

More filechooser design refresh and better filechooser search

Dropped Windows XP support

Model support for list and flow box

Kinetic touchpad scrolling

Touchpad gestures (Wayland)

gtk-builder-tool utility

Output-only windows

3.18.9
Old version, no longer maintained: 3.20 2016-03-21[90] Further Integration of CSS nodes[91]

Move drag and drop down to GDK

New widget: GtkShortcutsWindow (shows keyboard shortcuts and gestures of an application)

3.20.10
Old version, no longer maintained: 3.22 2016-09-21[92] Last 3.x release[25]

Wayland tablet support is merged,[93] support for graphics tablets is considered feature complete[94]

GTK 3.22 shall be as rock-stable (and hence "boring") as GTK 2[32][95][96]

for 3+ years
3.22.29
Older version, yet still maintained: 3.24 2018-09-03[97] 3.22 was supposed to be the last version of GTK 3 series

Dependency bumps – require:

  • libepoxy 1.4
  • pango 1.41

New font chooser features:

  • allow setting OpenType font features
  • show examples for OpenType font features
  • allow selecting OpenType font variations
  • support levels of details for selection

New Emoji features:

  • support a completion popup for Emoji
  • drop Ctrl-Shift-e shortcut

Other new APIs: gdk_window_move_to_rect

Wayland: use anonymous shared memory on FreeBSD

Backported event controllers from GTK 4:

  • GtkEventControllerScroll
  • GtkEventControllerMotion
  • GtkEventControllerKey
  • GtkGestureStylus

Deprecate a few APIs that are gone in GTK 4:

  • focus chains in GtkContainer
  • stepper sensitivity in GtkRange
3.23.0
3.23.1
3.23.2
3.23.3
3.24.0
...3.24.5
3.24.14
...

3.24.29

Old version, no longer maintained: 3.90 2017-03-31[98] GTK Scene Graph Kit (GSK) merged[5]

Remove any API marked as deprecated

Heavy development

A new Vulkan-renderer augments the old Cairo-renderer[99]

3.89.1

3.89.2
3.89.4
3.89.5
3.90

Old version, no longer maintained: 3.92 2017-10-18[100][101] As GNOME 3.26 was released already on September 13, 2017,[102] it was not based on GTK 3.92.

GNU autotools was replaced with Meson.

3.91.0

3.91.1
3.91.2
3.92.1

Old version, no longer maintained: 3.94 2018-06-26[103] 3.93
  • GdkScreen, GdkVisual removed
  • GdkDeviceManager replaced by GdkSeat
  • Clipboard handling is moved from GTK to GDK
  • GdkEvent is converted to an opaque GObject
  • the GL renderer in GSK is substantially completed, and is now on par with the Vulkan renderer
  • the use of GdkPixbuf in APIs is reduced
    • and the GskTexture object is moved to GDK as GdkTexture, to take its place
  • the Wayland backend now implements the KDE server-side decoration protocol
  • Broadway is ported to GSK.

GdkWindow renamed to GdkSurface

New abstraction for drawable content: GdkPaintable

There is support for displaying media with:

  • GtkVideo
  • GtkMediaFile
  • GtkMediaStream
  • GtkMediaControls
3.93
3.94.0
Old version, no longer maintained: 3.96 2019-05-07[104] The gtk4-builder-tool simplify command has gained a --3to4 option to convert GTK3 ui files to GTK4; though with AMTK menus, toolbars or other objects like GtkShortcutsWindow are created programmatically (not with a *.ui file), but with convenient APIs.[105]

GtkWidget can now use a GtkLayoutManager for size allocation

  • layout managers can optionally use layout children holding layout properties
  • GtkBinLayout, GtkBoxLayout, GtkGridLayout, GtkFixedLayout and GtkCustomLayout are currently available
  • more layout manager implementations will appear in the future

Focus handling has been rewritten, and focus-change event generation has been unified with crossing events

Events have been simplified and are just used for input:

  • expose events have been replaced by a GdkSurface::render signal
  • configure events have been replaced by a GdkSurface::size-changed signal
  • map events have been replaced by a GdkSurface::mapped property
  • gdk_event_handler_set has been replaced by a GdkSurface::event signal
  • key events no longer contain a string
  • events on unmapped widgets are ignored
3.96.0
Old version, no longer maintained: 3.98 2020-02-10[104]
  • Performance improvements
  • Drag and drop refactoring
  • Moving GDK towards Wayland
  • Removals
    • GtkMenu, GtkToolbar and similar classes have been replaced by GMenu.
  • Additions
    • Emoji chooser
    • Text widgets now have undo stacks
    • A new layout manager[106]
3.98.5
Old version, no longer maintained: 3.99.0 2020-07-31[107]
  • Introduced successor to Accessibility Toolkit (ATK).[108] The new approach will implement WAI-ARIA (World Wide Web Consortium (W3C) Accessibility Initiative – Accessible Rich Internet Applications).
  • Updated headers to use standard C types instead of GLib types
  • New widgets
  • Fixes and improvements[107]
3.99.4
Old version, no longer maintained: 4.0 2020-12-16[109] 4.0.2
Old version, no longer maintained: 4.2 2021-03-30[110]
Old version, no longer maintained: 4.4 2021-08-23[111]
Current stable version: 4.6 2021-12-30[112]

See also

  • Client-Side Decoration
  • List of widget toolkits
  • GDK – the GIMP Drawing Kit lies between the xlib and the GTK library, handling basic rendering such as drawing primitives, raster graphics (bitmaps), cursors, fonts, as well as window events and drag-and-drop functionality
  • gtkmm – C++ bindings for GTK
  • Qt – cross platform framework and toolkit
  • Xojo – cross-platform development tool and framework
  • Enlightenment Foundation Libraries (EFL) – widget toolkit written for the Enlightenment window manager
  • FLTK – a light, cross-platform, non-native widget toolkit
  • FOX toolkit – a fast, open source, cross-platform widget toolkit
  • IUP – a multi-platform toolkit for building native graphical user interfaces
  • Ultimate++
  • Visual Component Library (VCL)
  • Vala – an object-oriented programming language with a self-hosting compiler that generates C code and uses the GObject system.
  • wxWidgets - a cross-platform GUI toolkit whose goal is to directly use each platform's native graphic API whenever possible.

References

  1. "The GTK Open Source Project on Open Hub: Languages Page". www.openhub.net.
  2. Bassi, Emmanuele (6 February 2019). "Project rename to "GTK"". mail.gnome.org. GNOME mailinglist. Retrieved 7 February 2019.
  3. The GTK+ Team. "GTK+ Features". Archived from the original on 25 May 2019. Retrieved 8 September 2014.
  4. "Documentation". www.x.org.
  5. "Projects/GTK/Roadmap - GNOME Wiki!". wiki.gnome.org.
  6. "GTK 4.0 – GTK Development Blog". Retrieved 18 October 2021.
  7. "GTK+ 3 Reference Manual". Retrieved 15 July 2017.
  8. "Using GTK+ with Broadway". GNOME Developer. GNOME. Retrieved 6 March 2018.
  9. "Broadway - GitHub symbiose/symbiose Wiki". GitHub. Retrieved 6 March 2018.
  10. "GTK+ to Use Cairo Vector Engine". Retrieved 27 December 2009.
  11. "Gtk: Migrating from GTK 2.x to GTK 3". docs.gtk.org. Retrieved 16 June 2022. All drawing in GTK 3 is done via Cairo.
  12. "Matthias Clasen DevConf.cz 2018 talk about GTK+ 4" (PDF). 26 January 2018.
  13. "Introducing GtkInspector". 15 May 2014.
  14. "Another GtkInspector update". 11 July 2014.
  15. "Debian -- Package Search Results -- gazpacho". packages.debian.org.
  16. "Nothing-personal - A development site for Crow Designer, GuiLoader and Rally - Google Project Hosting". Archived from the original on 24 January 2013. Retrieved 17 February 2014.
  17. The GTK+ Team. "GTK+ Language Bindings". www.gtk.org. Archived from the original on 25 May 2019. Retrieved 3 June 2017.
  18. "Gtk# is a Mono/.NET binding to the cross platform Gtk+ GUI toolkit and the foundation of most GUI apps built with Mono: mono/gtk-sharp". 16 November 2019 via GitHub.
  19. "Download Gtk#". The GTK+ Project.
  20. "'Bansheegeddon' may see Banshee, Mono dropped from Ubuntu default". ITWorld. Retrieved 31 August 2015.
  21. "GNOME Quick SWOT Analysis". The GNOME Project. Retrieved 18 March 2014.
  22. "GTK+ and GNOME Mailing Lists". The GNOME Project. Retrieved 4 December 2011.
  23. "About". GNOME Users And Developers European Conference (GUADEC). Archived from the original on 4 October 2011. Retrieved 3 December 2011.
  24. "GNOME Languages". Ohloh. Black Duck Software. Retrieved 22 May 2014.
  25. "Versioning and long term stability promise in GTK". GTK development blog. 1 September 2016.
  26. "GTK+ 3.24 To Deliver Some New Features While Waiting For GTK4". www.phoronix.com.
  27. "GTK 4.0". GTK development blog. 16 December 2020.
  28. "Development release GIMP 2.99.2 is out". Gimp news. 6 November 2020.
  29. "Build system change GTK's master branch". mail.gnome.org.
  30. "How Does One Create A Gtk+ Application? – Morten Welinder". blogs.gnome.org. Retrieved 3 June 2017.
  31. mclasen (20 November 2015). "A GTK+ update". Goings on.
  32. "GUADEC2013: Benjamin Otte talks about GTK+". GUADEC.
  33. Larabel, Michael (12 January 2014). "The Biggest Problem With GTK & What Qt Does Good". Phoronix. Retrieved 10 September 2014.
  34. Hong Jen Yee (26 March 2013). "PCManFM Qt 0.1.0 released". Retrieved 10 September 2014.
  35. "Audacious - An Advanced Audio Player". audacious-media-player.org.
  36. Lindgren, John (6 May 2014). "Ugly window decorations and how to fix them (GTK 3.12)". Retrieved 21 October 2014.
  37. Gerald Combs (15 October 2013). "We're switching to Qt". Retrieved 19 August 2015.
  38. "GTK+". WxWidgets Compared To Other Toolkits.
  39. "GTK+ TTY Port". Slashdot. Retrieved 31 August 2010.
  40. "LinuxWorld - Where did Spencer Kimball and Peter Mattis go?". Archived from the original on 17 April 1999. Retrieved 19 August 2013.{{cite web}}: CS1 maint: bot: original URL status unknown (link)
  41. "What is the + in GTK+?". 2011. Archived from the original on 26 March 2012. Retrieved 18 March 2014.
  42. "Rename some references to GTK+ (d080be3e) · Commits · GNOME / gtk". gitlab.gnome.org.
  43. "Projects/GTK/OSX - GNOME Wiki!". wiki.gnome.org.
  44. "GTK Download: Mac OS X". www.gtk.org.
  45. "GTK Download: Windows". www.gtk.org.
  46. "GTK+ for Windows Runtime Environment". SourceForge.
  47. "GTK+". www.tarnyko.net.
  48. "GTK+ for Windows Runtime Environment Installer (fork from http://gtk-win.sourceforge.net): tschoonj/GTK-for-Windows-Runtime-Environment-Installer". 19 November 2020 via GitHub.
  49. http://h41379.www4.hpe.com/openvms/products/ips/gtk.html
  50. http://h41379.www4.hpe.com/openvms/products/ips/gtk_down.html
  51. https://mclasen.fedorapeople.org/gtk4-devconf2018.pdf
  52. Amundson, Shawn T. (13 April 1998). "ANNOUNCE: GTK+ 1.0.0 Released!". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  53. Amundson, Shawn T. (25 February 1999). "ANNOUNCE: GTK+ and GLib 1.2.0 Released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  54. Taylor, Owen (11 March 2002). "GTK+-2.0.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  55. Taylor, Owen (22 December 2002). "GTK+-2.2.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  56. Taylor, Owen (16 March 2004). "GTK+-2.4.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  57. Clasen, Matthias (16 December 2004). "GTK+-2.6.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  58. Clasen, Matthias (13 August 2005). "GTK+ 2.8.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  59. Clasen, Matthias (3 July 2006). "GTK+ 2.10 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  60. Clasen, Matthias (14 September 2007). "GTK+ 2.12 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  61. Clasen, Matthias (4 September 2008). "GTK+ 2.14.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  62. Clasen, Matthias (13 March 2009). "GTK+ 2.16.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  63. Clasen, Matthias (23 September 2009). "GTK+ 2.18.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  64. Clasen, Matthias (23 March 2010). "GTK+ 2.20.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  65. Clasen, Matthias (23 September 2010). "GTK+ 2.22.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  66. Clasen, Matthias (20 January 2011). "GTK+ 2.24.0". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  67. Clasen, Matthias (10 February 2011). "GTK+ 3.0.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  68. "Gtk+ 3.0 Theming API Hackfest". Silicon Island. Retrieved 3 June 2017.
  69. "Gtk+ 3 roadmap draft". Retrieved 3 June 2017.
  70. "Attic/ProjectRidley - GNOME Wiki!". wiki.gnome.org.
  71. Clasen, Matthias (25 September 2011). "GTK+ 3.2.0". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  72. Clasen, Matthias (26 March 2012). "GTK+ 3.4.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  73. Clasen, Matthias (24 September 2012). "GTK+ 3.6.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  74. Clasen, Matthias (25 March 2013). "GTK+ 3.8.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  75. "Frame clock: GDK 3 Reference Manual". developer.gnome.org.
  76. Clasen, Matthias (23 September 2013). "GTK+ 3.10.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  77. Clasen, Matthias (25 March 2014). "GTK+ 3.12 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  78. "Client-side decorations in themes | Goings on".
  79. Clasen, Matthias (22 September 2014). "GTK+ 3.14.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  80. Matthias Clasen (15 May 2014). "GtkInspector Author's blog entry". Retrieved 17 May 2014.
  81. "GtkInspector in GNOME wiki". 15 May 2014. Retrieved 17 May 2014.
  82. "Merging gestures into 3.14". 23 May 2014. Retrieved 23 May 2014.
  83. "RFC: gestures". 4 March 2014. Retrieved 23 May 2014.
  84. "gtk+ 3.13.2". 27 May 2014.
  85. "gtk+ 3.13.3". 24 June 2014.
  86. Clasen, Matthias (22 March 2015). "GTK+ 3.16.0 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  87. online, heise. "Linux-Desktop: Neues Gnome zeigt Nachrichten oben". heise online. Retrieved 3 June 2017.
  88. "GTK+ 3.16.0 released". mail.gnome.org. Retrieved 3 June 2017.
  89. Nestor, Marius (24 September 2015). "GTK+ 3.18.0 Officially Released as Part of the GNOME 3.18 Desktop Environment". Softpedia. Retrieved 25 May 2019.
  90. Clasen, Matthias (21 March 2016). "GTK+ 3.20". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  91. "GTK+ 3.20 – Style Classes and Element Names". 20 November 2015.
  92. Clasen, Matthias (21 September 2016). "GTK+ 3.22 released". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  93. "GTK+ Wayland tablet support is merged – Carlos Garnacho".
  94. "hutterer input". www.x.org.
  95. "Gtk 4.0 will not be stable until Gtk 4.6". 13 June 2016.
  96. "Gtk 5.0 will not be stable until Gtk 5.6". 14 June 2016.
  97. Clasen, Matthias (3 September 2018). "gtk+ 3.24.0". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  98. Clasen, Matthias (31 March 2017). "gtk+ 3.90.0". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  99. "Commits · master · GNOME / gtk". GitLab.
  100. Clasen, Matthias (18 October 2017). "gtk+ 3.92.1". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  101. Clasen, Matthias (23 October 2017). "GTK+ 3.92". GTK Development Blog. Retrieved 25 May 2019.
  102. "GNOME 3.26 Released". 13 September 2017.
  103. Clasen, Matthias (26 June 2018). "gtk+ 3.94.0". GNOME Mail Services (Mailing list). Retrieved 20 May 2019.
  104. Clasen, Matthias (7 May 2019). "gtk 3.96". GNOME Mail Services (Mailing list). Retrieved 28 May 2019.
  105. "Introducing amtk".
  106. Clasen, Matthias (13 February 2020). "GTK 3.98". GTK+ Development Blog. Retrieved 18 February 2020.
  107. Clasen, Matthias (9 June 2021). "gtk 4.3.1". FTP Releases (Mailing list). Retrieved 10 July 2021.
  108. "Emmanuele Bassi / guadec-2020". GitLab.
  109. Clasen, Matthias (16 December 2020). "gtk 4.0.0". GNOME Mail Services (Mailing list). Retrieved 16 December 2020.
  110. Clasen, Matthias (30 March 2021). "gtk 4.2.0". GNOME Mail Services (Mailing list). Retrieved 30 March 2021.
  111. Clasen, Matthias (23 August 2021). "gtk 4.4.0". GNOME Mail Services (Mailing list). Retrieved 23 January 2022.
  112. Clasen, Matthias (30 December 2021). "gtk 4.6.0". FTP Releases (Mailing list). Retrieved 23 January 2022.

Bibliography

This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.