<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="zh">
	<id>https://arolstar52-zhtest.hf.space/index.php?action=history&amp;feed=atom&amp;title=GTK</id>
	<title>GTK - 版本历史</title>
	<link rel="self" type="application/atom+xml" href="https://arolstar52-zhtest.hf.space/index.php?action=history&amp;feed=atom&amp;title=GTK"/>
	<link rel="alternate" type="text/html" href="https://arolstar52-zhtest.hf.space/index.php?title=GTK&amp;action=history"/>
	<updated>2026-07-17T21:48:51Z</updated>
	<subtitle>在这个wiki上该页的修订历史</subtitle>
	<generator>MediaWiki 1.43.9</generator>
	<entry>
		<id>https://arolstar52-zhtest.hf.space/index.php?title=GTK&amp;diff=341&amp;oldid=prev</id>
		<title>imported&gt;Wolfch：​/* 软件架构 */</title>
		<link rel="alternate" type="text/html" href="https://arolstar52-zhtest.hf.space/index.php?title=GTK&amp;diff=341&amp;oldid=prev"/>
		<updated>2025-12-03T08:40:41Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;软件架构&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新页面&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{NoteTA|G1=IT|G2=FL}}&lt;br /&gt;
{{Technical reasons|Gtk#|.NET的-{zh-cn:库; zh-tw:函式庫;}-|Gtk♯}}&lt;br /&gt;
{{Infobox software&lt;br /&gt;
| name                   = GTK&lt;br /&gt;
| title                  = &lt;br /&gt;
| logo                   = GTK logo.svg&lt;br /&gt;
| screenshot             = Gtk3-widget-factory-3.16.0.png&lt;br /&gt;
| caption                = [https://developer.gnome.org/gtk3/stable/gtk3-widget-factory.html gtk3-widget-factory]是展示GTK +版本3中許多GUI小[[控件]]示例的集合&lt;br /&gt;
| collapsible            = &lt;br /&gt;
| author                 = {{tsl|en|Spencer Kimball (computer programmer)|Spencer Kimball}}、{{tsl|en|Peter Mattis}}、{{tsl|en|eXperimental Computing Facility}}&lt;br /&gt;
| developer              = [[GNOME計劃]]&lt;br /&gt;
| released               = {{Start date and age|1998|04|14}}&lt;br /&gt;
| programming language   = [[C语言]]&amp;lt;ref&amp;gt;{{cite web |url=http://www.ohloh.net/p/gtk |title=The GTK Open Source Project on Ohloh |publisher=Ohloh.net |date= |accessdate=2014-02-17 |archive-date=2013-12-08 |archive-url=https://web.archive.org/web/20131208170758/http://www.ohloh.net/p/gtk |dead-url=no }}&amp;lt;/ref&amp;gt;&lt;br /&gt;
| operating system       = [[Linux]]、[[类Unix系统]]、[[macOS]]、[[Microsoft Windows]]&lt;br /&gt;
| platform               = &lt;br /&gt;
| size                   = &lt;br /&gt;
| genre                  = [[部件工具箱]]&lt;br /&gt;
| license                = [[GNU宽通用公共许可证]]2.1&lt;br /&gt;
| website                = {{URL|https://gtk.org}}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
&amp;#039;&amp;#039;&amp;#039;{{lang|en|GTK}}&amp;#039;&amp;#039;&amp;#039;（原名&amp;#039;&amp;#039;&amp;#039;{{lang|en|GTK+}}&amp;#039;&amp;#039;&amp;#039;）最初是[[GIMP]]的专用开发库（{{lang|en|GIMP Toolkit}}），后来发展为[[Unix-like]]系統下开发[[图形界面]]的应用程序的主流开发工具之一。GTK是[[自由软件]]，并且是[[GNU计划]]的一部分。自2019年2月6日起，GTK+改名为GTK。&amp;lt;ref&amp;gt;{{Cite web|title=Project rename to &amp;quot;GTK&amp;quot;|url=https://mail.gnome.org/archives/gtk-devel-list/2019-February/msg00000.html|work=mail.gnome.org|accessdate=2019-02-10|archive-date=2020-11-07|archive-url=https://web.archive.org/web/20201107233352/https://mail.gnome.org/archives/gtk-devel-list/2019-February/msg00000.html|dead-url=no}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==软件架构==&lt;br /&gt;
&lt;br /&gt;
[[File:The GTK toolkit.png|thumb|GTK工具包]] [[File:GTK+ software architecture.svg|thumb|GTK的简化软件架构。[[Pango]], [[GDK]], [[Accessibility Toolkit|ATK]], [[GIO (software)|GIO]], [[Cairo (graphics)|Cairo]] 和 [[GLib]] ]] [[File:GDK software architecture.svg|thumb|[[GDK]]包含了对[[X11]], [[Wayland (display server protocol)|Wayland]], Broadway ([[Hypertext Transfer Protocol|HTTP]]), [[Quartz Compositor|Quartz]], 和 [[Graphics Device Interface|GDI]]的后端，并依赖于[[Cairo (graphics)|Cairo]]进行渲染。它的新SceneGraph还在开发中。]]&lt;br /&gt;
&lt;br /&gt;
GTK 包含了一组图形控制元素（[[部件]]）；版本3.22.16包含了186个活跃的和36个废弃的部件。&amp;lt;ref&amp;gt;{{cite web |title=GTK+ 3 Reference Manual |url=https://developer.gnome.org/gtk3/stable/ |access-date=2017-07-15 |archive-date=2021-06-23 |archive-url=https://web.archive.org/web/20210623002412/https://developer.gnome.org/gtk3/stable/ |dead-url=no }}&amp;lt;/ref&amp;gt; GTK是用[[C语言]]编写的一个[[面向对象程序设计|面向对象]]的[[widget toolkit|部件工具]]；它使用[[GObject]]，即[[GLib]]对象系统，来实现面向对象。虽然GTK主要是为基于[[X視窗系統|X11]]和[[Wayland]]的窗口系统设计的，但它也可以在其他平台上运行，包括[[Microsoft Windows]]（与[[Windows API]]接口），和[[macOS]]（与[[Quartz]]接口）。还有一个名为Broadway的[[HTML5]]后端。&amp;lt;ref&amp;gt;{{cite web |url=https://developer.gnome.org/gtk3/stable/gtk-broadway.html |title=Using GTK+ with Broadway |website=GNOME Developer |publisher=GNOME |access-date=6 March 2018 |archive-date=2021-06-14 |archive-url=https://web.archive.org/web/20210614021102/https://developer.gnome.org/gtk3/stable/gtk-broadway.html |dead-url=no }}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{cite web|title=Broadway - GitHub symbiose/symbiose Wiki|url=https://github.com/symbiose/symbiose/wiki/Broadway|website=GitHub|access-date=6 March 2018|archive-date=2023-06-28|archive-url=https://web.archive.org/web/20230628094731/https://github.com/symbiose/symbiose/wiki/Broadway|dead-url=no}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
GTK可以配置不同的显示引擎来改变绘制部件的外观。有几种显示引擎可以模仿所使用平台上的原生部件的外观。&lt;br /&gt;
&lt;br /&gt;
从2005年发布的版本2.8开始，GTK开始使用[[Cairo]]来[[渲染]]大多数图形控制元素（部件）。&amp;lt;ref&amp;gt;{{cite web |url=http://developers.slashdot.org/article.pl?sid=05/02/04/2021236 |title=GTK+ to Use Cairo Vector Engine |access-date=2009-12-27}}&amp;lt;/ref&amp;gt;自从GTK版本3.0开始，所有的渲染都是使用Cairo完成的。&amp;lt;ref&amp;gt;{{Cite web |title=Gtk: Migrating from GTK 2.x to GTK 3 |url=https://docs.gtk.org/gtk3/migrating-2to3.html |access-date=2022-06-16 |website=docs.gtk.org |language=en |quote=All drawing in GTK 3 is done via Cairo. |archive-date=2023-05-26 |archive-url=https://web.archive.org/web/20230526073106/https://docs.gtk.org/gtk3/migrating-2to3.html |dead-url=no }}&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
在2018年1月26日的DevConf.cz上，GTK重要开发者Matthias Clasen介绍了GTK 4开发的当前状态，包括对GTK 3中渲染和输入工作方式的高层次解释，GTK 4 (&amp;gt;3.90)中正在进行的变化以及原因。&amp;lt;ref&amp;gt;{{cite web |url=https://mclasen.fedorapeople.org/gtk4-devconf2018.pdf |title=Matthias Clasen DevConf.cz 2018 talk about GTK+ 4 |date=2018-01-26 |access-date=2023-06-28 |archive-date=2012-08-28 |archive-url=https://web.archive.org/web/20120828170152/http://www.gnomejournal.org/article/80/writing-multimedia-applications-with-vala |dead-url=no }}&amp;lt;/ref&amp;gt;在2019年2月6日，宣布GTK 4将从项目名称中去掉“+”号。&lt;br /&gt;
&lt;br /&gt;
===GTK绘图工具包（GDK）===&lt;br /&gt;
&lt;br /&gt;
GDK是对底层窗口系统和图形系统提供的低级函数的封装。&lt;br /&gt;
&lt;br /&gt;
===GTK场景图工具包（GSK）===&lt;br /&gt;
&lt;br /&gt;
GSK是GTK的渲染和场景图API。GSK位于图形控制元素（部件）和渲染之间。GSK最终在2017年3月发布的GTK版本3.90中合并。&lt;br /&gt;
&lt;br /&gt;
===GtkInspector===&lt;br /&gt;
&lt;br /&gt;
GtkInspector在版本3.14中引入。&amp;lt;ref&amp;gt;{{cite web |url=http://blogs.gnome.org/mclasen/2014/05/15/introducing-gtkinspector/ |title=Introducing GtkInspector |date=2014-05-15 |access-date=2023-06-28 |archive-date=2014-05-17 |archive-url=https://web.archive.org/web/20140517185349/http://blogs.gnome.org/mclasen/2014/05/15/introducing-gtkinspector/ |dead-url=no }}&amp;lt;/ref&amp;gt;&amp;lt;ref&amp;gt;{{cite web |url=http://blogs.gnome.org/mclasen/2014/07/11/another-gtkinspector-update/ |title=Another GtkInspector update |date=2014-07-11 |access-date=2023-06-28 |archive-date=2014-07-14 |archive-url=https://web.archive.org/web/20140714164943/http://blogs.gnome.org/mclasen/2014/07/11/another-gtkinspector-update/ |dead-url=no }}&amp;lt;/ref&amp;gt; GtkInspector只能在安装了开发包libgtk-3-dev/gtk±devel后调用。&lt;br /&gt;
&lt;br /&gt;
===GUI设计器===&lt;br /&gt;
&lt;br /&gt;
有几个[[GUI设计器]]可用于GTK。以下项目截至2011年7月仍在活跃：&lt;br /&gt;
&lt;br /&gt;
* [[Glade]]，支持[[#GtkBuilder|GtkBuilder]]，这是一个GTK内置的GUI描述格式。&lt;br /&gt;
* [[Gazpacho]]，用Python&amp;lt;ref&amp;gt;{{Cite web|url=https://packages.debian.org/search?keywords=gazpacho|title=Debian – Package Search Results – gazpacho|website=packages.debian.org|access-date=2023-06-28|archive-date=2023-06-28|archive-url=https://web.archive.org/web/20230628022158/https://packages.debian.org/search?keywords=gazpacho|dead-url=no}}&amp;lt;/ref&amp;gt;编写的GTK工具包的GUI构建器&lt;br /&gt;
* Crow Designer，依赖于它自己的GuiXml格式和GuiLoader库。&amp;lt;ref&amp;gt;{{cite web |url=http://nothing-personal.googlecode.com/ |archive-url=https://archive.today/20130124182138/http://nothing-personal.googlecode.com/ |url-status=dead |archive-date=2013-01-24 |title=Nothing-personal - A development site for Crow Designer, GuiLoader and Rally - Google Project Hosting |access-date=2014-02-17 }}&amp;lt;/ref&amp;gt;&lt;br /&gt;
* [[Stetic]]，作为[[MonoDevelop]]的一部分，面向[[Gtk Sharp|Gtk#]]。&lt;br /&gt;
* [[Gambas]]自版本2.0开始基于[[BASIC]]&lt;br /&gt;
* [[Xojo]]在[[Linux]]&lt;br /&gt;
* [[Lazarus (IDE)|Lazarus]]在Linux上默认与GTK 2接口&lt;br /&gt;
&lt;br /&gt;
====GtkBuilder====&lt;br /&gt;
&lt;br /&gt;
GtkBuilder允许在不编写代码的情况下设计用户界面。界面在XML文件中描述，然后在运行时加载并自动创建对象。Glade界面设计器允许以“所见即所得”（[[WYSIWYG]]）的方式创建用户界面。用户界面的描述与使用的编程语言无关。&lt;br /&gt;
&lt;br /&gt;
== 编程语言 ==&lt;br /&gt;
&lt;br /&gt;
GTK使用[[C语言]]开发，但是其设计者使用面向对象技术。也提供了[[Vala]]、[[C++]]（[[gtkmm]]）、[[Perl]]、[[Ruby]]、[[Java]]和[[Python]]（PyGObject）绑定，其他的绑定有[[Ada]]、[[D語言|D]]、[[Haskell]]、[[PHP]]和所有的[[.NET]]编程语言。&lt;br /&gt;
&lt;br /&gt;
与其他很多[[部件工具箱]]不同，GTK并不基于[[X Toolkit Intrinsics|Xt]]。这一决策优劣互见：优点是GTK可以应用于其他系统，其灵活性也很强；而缺点就是它无法利用以传统方法为[[X11]]定制的X资源数据库。GTK最早應用於X Window System，如今已移植至其他平台，諸如[[Microsoft Windows]]、[[DirectFB]]，以及[[Mac OS X]]平台上的[[Quartz]].&lt;br /&gt;
&lt;br /&gt;
[[Glade]]是一个界面设计工具，但是它也包含了一种描述GUI界面的[[XML]]语言，它和[[libglade]]一起工作就可以直接使用GTK和GNOME控件；新的Glade-3不再直接支持生成编程语言[[源代码]]。&lt;br /&gt;
&lt;br /&gt;
== 外观和视觉 ==&lt;br /&gt;
&lt;br /&gt;
提供不同的显示引擎使得最终用户可以定制外观和视觉。目前已经有一些可以模仿其他流行的平台或者工具箱（例如[[Windows 95]]、[[Motif]]、[[Qt]]或者[[NEXTSTEP]]）的引擎。&lt;br /&gt;
&lt;br /&gt;
[[File:gimp2-2.png|thumb|300px|运行在[[Xfce|Xfce4]]上的[[GIMP]] 2.0的快照]]&lt;br /&gt;
&lt;br /&gt;
== 使用 ==&lt;br /&gt;
;使用GTK的環境&lt;br /&gt;
&lt;br /&gt;
* [[GNOME]]是以GTK為基礎，就是說為GNOME編寫的程式使用GTK做為其工具箱。&lt;br /&gt;
* [[Xfce]]也基於GTK，但是它的應用程式並不對很多其他程式有依賴。（這就是&amp;quot;GNOME程式&amp;quot;和&amp;quot;GTK程式&amp;quot;的不同。）&lt;br /&gt;
* [[LXDE]]也基於GTK，一個盡可能減少套件相依性的桌面環境。&lt;br /&gt;
* [[GPE]] Palmtop環境和[[Nokia]]的[[互聯網]][[平板電腦]]的框架[[Maemo]]基於GTK。&lt;br /&gt;
&lt;br /&gt;
這只是一部分，另外，GTK也可以運行在[[KDE]]的環境下。而且GTK也可以在[[Microsoft Windows]]運行，另外還有[[DirectFB]]和[[ncurses]]。&lt;br /&gt;
&lt;br /&gt;
;使用GTK的窗口管理器&lt;br /&gt;
* [[Mutter]]&lt;br /&gt;
* [[Metacity]]&lt;br /&gt;
* [[Marco（窗口管理器）|Marco]]&amp;lt;ref&amp;gt;{{Citation|title=Marco|url=https://github.com/mate-desktop/marco|publisher=MATE Desktop|date=2022-12-21|accessdate=2023-01-19|archive-date=2022-12-05|archive-url=https://web.archive.org/web/20221205093011/https://github.com/mate-desktop/marco|dead-url=no}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
* [[Xfwm4]]&lt;br /&gt;
* [[Muffin]]&amp;lt;ref&amp;gt;{{Citation|title=Mutter|url=https://github.com/linuxmint/muffin|publisher=Linux Mint|date=2022-12-15|accessdate=2023-01-19|archive-date=2023-01-04|archive-url=https://web.archive.org/web/20230104125524/https://github.com/linuxmint/muffin/|dead-url=no}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
* [[Gala]]&amp;lt;ref&amp;gt;{{Citation|title=Gala|url=https://github.com/elementary/gala|publisher=elementary|date=2023-01-15|accessdate=2023-01-19|archive-date=2019-02-26|archive-url=https://web.archive.org/web/20190226011018/https://github.com/elementary/gala|dead-url=no}}&amp;lt;/ref&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== GTK应用程序 ===&lt;br /&gt;
以下程序都是使用GTK开发、属于[[开源软件]]，可以运行于[[Linux]]/[[Unix]]，[[Windows]]，[[macOS]]等多种操作系统平台上。&lt;br /&gt;
* [[Firefox]]－Mozilla基金會的網頁瀏覽器，在Linux下使用GTK。&lt;br /&gt;
* [[Geany]]－代码编辑器&lt;br /&gt;
* [[GIMP]]－类似于[[Photoshop]]的图像处理程序&lt;br /&gt;
* [[Inkscape]]－类似于[[Illustrator]]、[[CorelDraw]]的矢量图形绘制工具&lt;br /&gt;
* [[Pidgin]]－支持多种协议（IRC、Gtalk、Yahoo Talk、MSN等等）的聊天工具&lt;br /&gt;
* [[gcin]]－一種在Linux、Windows系統上常見的輸入法平台&lt;br /&gt;
&lt;br /&gt;
== 版本歷史 ==&lt;br /&gt;
{|class=&amp;quot;wikitable mw-collapsible mw-collapsed&amp;quot; style=&amp;quot;width:100%;&amp;quot;&lt;br /&gt;
! 主要版本&lt;br /&gt;
! 發佈日期&lt;br /&gt;
! 主要增強&lt;br /&gt;
! 最後次要版本&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/Public/gimp/gtk/v1.0/ 1.0] {{Wayback|url=http://ftp.gnome.org/Public/gimp/gtk/v1.0/ |date=20120222031330 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 1998年4月14日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 第一個穩定版本&lt;br /&gt;
|1.0.6&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/1.2/ 1.2] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/1.2/ |date=20200725232123 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 1999年2月27日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 新增部件（{{spml|GtkFontSelector|GtkPacker|GtkItemFactory|GtkCTree|GtkInvisible|GtkCalendar、GtkLayout|GtkPlug|GtkSocket}}）&lt;br /&gt;
|[http://mail.gnome.org/archives/gtk-devel-list/2001-April/msg00049.html 1.2.10] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2001-April/msg00049.html |date=20200623013353 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.0/ 2.0] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.0/ |date=20200927150349 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2002年3月11日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| GObject, [[Unicode]]（[[UTF-8]]）支援&lt;br /&gt;
|2.0.9&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.2/ 2.2] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.2/ |date=20200927135426 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2002年12月22日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| Multihead support&lt;br /&gt;
|2.2.4&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.4/ 2.4] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.4/ |date=20200927150152 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2004年3月16日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 新增部件（GtkFileChooser、GtkComboBox、GtkComboBoxEntry、GtkExpander、GtkFontButton、GtkColorButton）&lt;br /&gt;
|[http://mail.gnome.org/archives/gtk-devel-list/2004-December/msg00018.html 2.4.14] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2004-December/msg00018.html |date=20160915193228 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.6/ 2.6] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.6/ |date=20201028211422 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2004年12月16日&lt;br /&gt;
|New widgets（GtkIconView, GtkAboutDialog, GtkCellView）.&amp;lt;br /&amp;gt;最後一個支援[[Windows 98]]/[[Windows Me|Me]]的版本&lt;br /&gt;
|[http://mail.gnome.org/archives/gtk-devel-list/2005-August/msg00097.html 2.6.10] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2005-August/msg00097.html |date=20160916040649 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.8/ 2.8] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.8/ |date=20201028211421 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2005年8月13日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [[Cairo (graphics)|Cairo]] integration&lt;br /&gt;
| [http://mail.gnome.org/archives/gtk-devel-list/2006-July/msg00002.html 2.8.20] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2006-July/msg00002.html |date=20160916040651 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.10/ 2.10] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.10/ |date=20200922183301 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2006年7月3日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 新增部件（GtkStatusIcon、GtkAssistant、GtkLinkButton、GtkRecentChooser）以及列印支援（GtkPrintOperation）&lt;br /&gt;
|[http://mail.gnome.org/archives/gtk-devel-list/2007-July/msg00058.html 2.10.14] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2007-July/msg00058.html |date=20190508090510 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.12/ 2.12] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.12/ |date=20200928064513 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2007年9月14日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| GtkBuilder&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gtk-devel-list/2008-September/msg00069.html 2.12.12] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2008-September/msg00069.html |date=20160916041314 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.14/ 2.14] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.14/ |date=20201019154950 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2008年9月4日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [[Jpeg2000]] load support&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gtk-devel-list/2009-January/msg00031.html 2.14.7] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2009-January/msg00031.html |date=20190508221933 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.16/ 2.16] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.16/ |date=20200927150024 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2009年3月13日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| New GtkOrientable, Caps Lock warning in password Entry.&amp;lt;br /&amp;gt;Improvement on GtkScale, GtkStatusIcon, GtkFileChooser.&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gtk-devel-list/2009-August/msg00176.html 2.16.6] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2009-August/msg00176.html |date=20160304195557 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.18/ 2.18] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.18/ |date=20200411012206 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2009年9月23日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| New GtkInfoBar. Improvement on file chooser, printing.&amp;lt;br/&amp;gt;GDK has been rewritten to use &amp;#039;client-side windows&amp;#039;&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gtk-devel-list/2010-March/msg00115.html 2.18.9] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2010-March/msg00115.html |date=20160304112308 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.20/ 2.20] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.20/ |date=20200411012359 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2010年3月23日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| New GtkSpinner and GtkToolPalette, GtkOffscreenWindow. Improvement on file chooser,&amp;lt;br/&amp;gt;keyboard handling, GDK.Introspection data is now included in GTK&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gtk-devel-list/2010-May/msg00004.html 2.20.1] {{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2010-May/msg00004.html |date=20190509212736 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gnome.org/pub/gnome/sources/gtk+/2.22/ 2.22] {{Wayback|url=http://ftp.gnome.org/pub/gnome/sources/gtk+/2.22/ |date=20200927150814 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2010年9月23日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| gdk-pixbuf moved to separate module, most GDK drawing are based on Cairo,&amp;lt;br/&amp;gt;many internal data are now private and can be &amp;#039;&amp;#039;sealed&amp;#039;&amp;#039; in preparation to GTK3&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/ftp-release-list/2010-November/msg00145.html 2.22.1] {{Wayback|url=http://mail.gnome.org/archives/ftp-release-list/2010-November/msg00145.html |date=20190508183904 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gtk.org/pub/gtk/2.24/ 2.24] {{Wayback|url=http://ftp.gtk.org/pub/gtk/2.24/ |date=20190510002612 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2011年1月30日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| New simple combo box widget (GtkComboBoxText) added, the cups print backend can send print jobs as PDF,&amp;lt;br/&amp;gt;GtkBuilder has gained support for text tags and menu toolbuttons and many introspection annotation fixes were added&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gtk-devel-list/2011-January/msg00042.html 2.24.0]{{Wayback|url=http://mail.gnome.org/archives/gtk-devel-list/2011-January/msg00042.html |date=20110405014901 }}&lt;br /&gt;
|-&lt;br /&gt;
![http://ftp.gtk.org/pub/gtk/3.0/ 3.0]{{Wayback|url=http://ftp.gtk.org/pub/gtk/3.0/ |date=20160803184536 }}&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| 2011年2月10日&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| Cairo, more X11 agnostic, XInput2, CSS-based theme API&lt;br /&gt;
|style=&amp;quot;white-space: nowrap;&amp;quot;| [http://mail.gnome.org/archives/gnome-announce-list/2011-February/msg00022.html 3.0.0] {{Wayback|url=http://mail.gnome.org/archives/gnome-announce-list/2011-February/msg00022.html |date=20180731022449 }}&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
== 图形无关代码 ==&lt;br /&gt;
&lt;br /&gt;
最初GTK包括一些和图形无关的常规功能，如[[链表]]和[[二叉树]]等[[数据结构]]。这些基本功能和对象系统GObject已经合并到独立的[[函式庫|库]][[Glib]]，它被程序员专门用于开发不需要[[图形界面]]的代码。&lt;br /&gt;
&lt;br /&gt;
== GTK 2 ==&lt;br /&gt;
&lt;br /&gt;
2002年3月11日，GTK2.0版正式发布。GTK 2是GTK后继版本，其新特性包括使用[[Pango]]改进的文本渲染、新主题引擎、使用[[ATK]]改进的可达性、完全转换到使用[[UTF-8]]的[[Unicode]]和更灵活的[[API]]。但是它和GTK 1不完全兼容，因此必须由程序员做移植工作。由于GTK 1更快、相对更简单或更加适合[[嵌入式应用]]，所以还被继续使用。&lt;br /&gt;
&lt;br /&gt;
从GTK 2的2.8版起，它依靠[[程式庫]][[Cairo]]完成[[渲染]]，而这引入了[[矢量图形]]的支持。&lt;br /&gt;
&lt;br /&gt;
== 发展 ==&lt;br /&gt;
&lt;br /&gt;
[[Ridley]]项目正在尝试统一一系列和GTK相关的库，包括libgnome、libgnomeui、libgnomeprint、libgnomeprintui、libglade、libgnomecanvas、libegg、libeel和gtkglext。&lt;br /&gt;
&lt;br /&gt;
== GTK hello world ==&lt;br /&gt;
GTK [[hello world]]以C撰写，本程序含有窗口，标题是&amp;quot;Hello, World&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;c&amp;quot;&amp;gt;&lt;br /&gt;
 #include &amp;lt;gtk/gtk.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 int main (int argc, char *argv[])&lt;br /&gt;
 {&lt;br /&gt;
    GtkWidget *window;&lt;br /&gt;
    GtkWidget *label;&lt;br /&gt;
&lt;br /&gt;
    gtk_init (&amp;amp;argc, &amp;amp;argv);&lt;br /&gt;
&lt;br /&gt;
    /* create the main, top level, window */&lt;br /&gt;
    window = gtk_window_new (GTK_WINDOW_TOPLEVEL);&lt;br /&gt;
&lt;br /&gt;
    /* give it the title */&lt;br /&gt;
    gtk_window_set_title (GTK_WINDOW (window), &amp;quot;Hello World&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    /* Connect the destroy signal of the window to gtk_main_quit&lt;br /&gt;
     * When the window is about to be destroyed we get a notification and&lt;br /&gt;
     * stop the main GTK loop&lt;br /&gt;
     */&lt;br /&gt;
    g_signal_connect (window, &amp;quot;destroy&amp;quot;,&lt;br /&gt;
                      G_CALLBACK (gtk_main_quit), NULL);&lt;br /&gt;
&lt;br /&gt;
    /* Create the &amp;quot;Hello, World&amp;quot; label  */&lt;br /&gt;
    label = gtk_label_new (&amp;quot;Hello, World&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
    /* and insert it into the main window  */&lt;br /&gt;
    gtk_container_add (GTK_CONTAINER (window), label);&lt;br /&gt;
&lt;br /&gt;
    /* make sure that everything, window and label, are visible */&lt;br /&gt;
    gtk_widget_show_all (window);&lt;br /&gt;
&lt;br /&gt;
    /* start the main loop, and let it rest there until the application is closed */&lt;br /&gt;
    gtk_main ();&lt;br /&gt;
&lt;br /&gt;
    return 0;&lt;br /&gt;
 }&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== GTK Runtime Environment for Windows ==&lt;br /&gt;
由於GTK主要是作為Unix-like系統底下的介面，在Windows使用該系統所開發的軟體時就需要用到GTK執行環境，即GTK Runtime Environment for Windows。這個軟體與GTK不同的地方在於它僅僅是為了執行軟體用途而製作，以解決Windows沒有內建GTK函式庫的問題。&lt;br /&gt;
&lt;br /&gt;
== 参见 ==&lt;br /&gt;
* [[Gtk Sharp|Gtk#]]，GTK的.NET API。&lt;br /&gt;
* [[PyGTK]]，GTK的Python API。&lt;br /&gt;
* [[Qt]]&lt;br /&gt;
* [[Motif]]&lt;br /&gt;
* [[wxWidgets]]&lt;br /&gt;
&lt;br /&gt;
== 參考資料 ==&lt;br /&gt;
{{reflist|2}}&lt;br /&gt;
&lt;br /&gt;
== 外部链接 ==&lt;br /&gt;
{{commons|GTK}}&lt;br /&gt;
* [http://www.gtk.org GTK主页]{{Wayback|url=http://www.gtk.org/ |date=20110222211023 }}&lt;br /&gt;
* {{dmoz|Computers/Software/Operating_Systems/Graphic_Subsystems/Toolkits/Gtk/}}&lt;br /&gt;
&lt;br /&gt;
{{GTK|state=collapsed}}&lt;br /&gt;
[[Category:应用程序接口]]&lt;br /&gt;
[[Category:GNU]]&lt;br /&gt;
[[Category:GNU計劃軟體]]&lt;br /&gt;
[[Category:使用LGPL许可证的软件]]&lt;br /&gt;
[[Category:部件工具箱]]&lt;br /&gt;
[[Category:软件开发]]&lt;br /&gt;
[[Category:GTK| ]]&lt;/div&gt;</summary>
		<author><name>imported&gt;Wolfch</name></author>
	</entry>
</feed>