GTK+
From ArchWiki
i18n |
---|
English |
简体中文 |
GTK, The GIMP Toolkit, was initially made for Gimp but is now a very popular toolkit with bindings for a lot of languages.
Contents |
Tips
Look & Feel
If you'd like to change the appearance of your GTK applications, learn Howto make GTK apps look nice. If you'd like to make the appearance of your QT and GTK applications look similar, please see Uniform_look_for_QT_and_GTK_apps.
Configuration
If you are not using one of the major Desktop Environments and thus are unable to configure GTK using the respective configuration tools, you may want to tweak your GTK settings manually. This can be done by editing ~/.gtkrc-2.0 (which can be automated by tools such as cog or gtk2_prefs).
You might want to take a look at our Collection of Useful GTK Settings.
Compiling GTK+ programs
One better be noticed that when writing a start-from-scratch GTK+ program with C, it's necessary to add CFLAGS for gcc (the code was adopted from ubuntu forum):
gcc -g -Wall `pkg-config --cflags --libs gtk+-2.0` -o base base.c
-g and -Wall parameters are not necessary since they are only for verbose debugging outputs. You may try out the official Hello World example provided by the gtk.org.