GTK+-3.24.10

#### Beyond Linux® From Scratch (systemd Edition) - Version 9.0

### Chapter 25. X Libraries

- Prev

  GTK+-2.24.32

- Next

  GTK Engines-2.20.2

- Up
- Home

# GTK+-3.24.10

## Introduction to GTK+ 3

The GTK+ 3 package contains libraries used for creating graphical user interfaces for applications.

This package is known to build and work properly using an LFS-9.0 platform.

### Package Information

- Download (HTTP): http://ftp.gnome.org/pub/gnome/sources/gtk+/3.24/gtk+-3.24.10.tar.xz

- Download (FTP): ftp://ftp.gnome.org/pub/gnome/sources/gtk+/3.24/gtk+-3.24.10.tar.xz

- Download MD5 sum: 1b9f49a500a104a3e40f8d8eb7e6ce96

- Download size: 20 MB

- Estimated disk space required: 459 MB (including tests; add 2 MB for tests)

- Estimated build time: 0.8 SBU (using parallelism=4, add 0.1 SBU for tests)

### GTK+ 3 Dependencies

#### Required

at-spi2-atk-2.32.0, FriBidi-1.0.5, gdk-pixbuf-2.38.1, libepoxy-1.5.3, and Pango-1.42.4

#### Recommended

adwaita-icon-theme-3.32.0 (default for some gtk+3 settings keys, also needed for tests), hicolor-icon-theme-0.17 (needed for tests), ISO Codes-4.3, libxkbcommon-0.8.4, sassc-3.6.1, Wayland-1.17.0, and wayland-protocols-1.18

#### Recommended (Required if building GNOME)

gobject-introspection-1.60.2

#### Optional

colord-1.4.4, Cups-2.2.12, DocBook-utils-0.6.14, GTK-Doc-1.32, JSON-GLib-1.4.4, PyAtSpi2-2.32.1 (for tests), rest-0.8.1, and PAPI

User Notes: http://wiki.linuxfromscratch.org/blfs/wiki/gtk3

## Installation of GTK+ 3

### Caution

If you are upgrading from a version of GTK+3 prior to 3.24.9, you must run the `remove-la-files.sh` script from Libtool archive (.la) files after installing GTK+.

Install GTK+ 3 by running the following commands:

    cd build &&
    meson --prefix=/usr     \
          -Dcolord=yes      \
          -Dgtk_doc=false   \
          -Dman=true        \
          -Dbroadway_backend=true .. &&
    ninja

Some tests fail if `/usr/share/glib-2.0/schemas/gschemas.compiled` is not found. If you wish to run the test suite, create (or update) the file using the following command as the `root` user: glib-compile-schemas /usr/share/glib-2.0/schemas.

To test the results you need a graphical session, then issue ninja test. six tests are known to fail in the a11y suite.

Now, as the `root` user:

    ninja install

### Note

If you installed the package on to your system using a “DESTDIR” method, an important file was not installed and must be copied and/or generated. Generate it using the following command as the `root` user:

    gtk-query-immodules-3.0 --update-cache

### Note

If you installed the package to your system using a “DESTDIR” method, `/usr/share/glib-2.0/schemas/gschemas.compiled` was not updated/created. Create (or update) the file using the following command as the `root` user:

    glib-compile-schemas /usr/share/glib-2.0/schemas

## Command Explanations

`-Dbroadway_backend=true`: This switch enables the HTML5 GTK backend.

`-Dcolord=yes`: This switch allows color support in the GTK+ printing backend.

`-Dman=true`: This switch allows generating manual pages.

`-Dgtk_doc=false`: This switch disables building documentation. Replace with -Dgtk_doc=true if you have GTK-Doc-1.32 installed and wish to generate documentation.

## Configuring GTK+ 3

### Config Files

`~/.config/gtk-3.0/settings.ini` and `/etc/gtk-3.0/settings.ini`

### Configuration Information

GTK+ 3 themes change the way a GTK+ 3 application looks. An icon theme can be used to change the icons that appear on the application's toolbar. If you have installed a GTK+ 3 theme (e.g. gnome-themes-extra-3.28), an icon theme (such as oxygen-icons5-5.61.0) and/or a font (Dejavu fonts), you can set your preferences in `~/.config/gtk-3.0/settings.ini`, or the default system wide configuration file (as the `root` user), in `/etc/gtk-3.0/settings.ini`. For the local user an example is:

    mkdir -vp ~/.config/gtk-3.0
    cat > ~/.config/gtk-3.0/settings.ini << "EOF"
    [Settings]
    gtk-theme-name = Adwaita
    gtk-icon-theme-name = oxygen
    gtk-font-name = DejaVu Sans 12
    gtk-cursor-theme-size = 18
    gtk-toolbar-style = GTK_TOOLBAR_BOTH_HORIZ
    gtk-xft-antialias = 1
    gtk-xft-hinting = 1
    gtk-xft-hintstyle = hintslight
    gtk-xft-rgba = rgb
    gtk-cursor-theme-name = Adwaita
    EOF

There are many settings keys, some with default values. You can find them at Settings: GTK+ 3 Reference Manual. There are many more themes available at http://gnome-look.org/ and other places.

## Contents

Installed Programs: broadwayd, gtk3-demo, gtk3-demo-application, gtk3-icon-browser, gtk3-widget-factory, gtk-builder-tool, gtk-encode-symbolic-svg, gtk-launch, gtk-query-immodules-3.0, gtk-query-settings, and gtk-update-icon-cache
Installed Libraries: libgailutil-3.so, libgdk-3.so, and libgtk-3.so
Installed Directories: /etc/gtk-3.0, /usr/include/{gail,gtk}-3.0, /usr/{lib,share}/gtk-3.0, /usr/share/gtk-doc/html/{gail-libgail-util,gdk,gtk}3, and /usr/share/themes/{Default,Emacs}/gtk-3.0

### Short Descriptions

broadwayd | provides support for displaying GTK+ 3 applications in a web browser, using HTML5 and web sockets.
gtk3-demo | is a simple program that demonstrates some of the tasks that can be done with GTK+ 3
gtk3-demo-application | is a simple GTK+ 3 application.
gtk3-icon-browser | is a utility to explore the icons in the current icon theme. It shows icons in various sizes, their symbolic variants where available, as well as a description of the icon and its context.
gtk3-widget-factory | is a program to view GTK+ 3 themes and widgets.
gtk-builder-tool | can perform various operations on GtkBuilder .ui files.
gtk-encode-symbolic-svg | converts symbolic svg icons into specially prepared png files. GTK+ 3 can load and recolor these pngs, just like original svgs, but loading them is much faster.
gtk-launch | launches an application using the given name. The name should match the application desktop file name, as residing in `/usr/share/applications`, with or without the '.desktop' suffix.
gtk-query-immodules-3.0 | collects information about loadable input method modules for GTK+ 3 and writes it to the default cache file location, or to standard output.
gtk-query-settings | provides a complete listing of all settings related to GTK+ 3
gtk-update-icon-cache | is an icon theme caching utility that creates mmap()able cache files for icon themes.
`libgailutil-3.so` | contains functions that implement the accessibility interfaces defined by the GNOME Accessibility Toolkit.
`libgdk-3.so` | contains functions that act as a wrapper around the low-level drawing and windowing functions provided by the underlying graphics system.
`libgtk-3.so` | contains functions that provide an API to implement graphical user interfaces.

Last updated on 2019-08-16 20:24:05 -0700

- Prev

  GTK+-2.24.32

- Next

  GTK Engines-2.20.2

- Up
- Home