Commit 1767e1a0 authored by David Boddie's avatar David Boddie

Rename GTK+ to GTK, declare minimum version of GTK as 3.32

parent 367c1132
Pipeline #31133 passed with stage
in 1 minute and 1 second
......@@ -108,7 +108,7 @@ The ``show_details`` method loads an image at its full size for display in the d
:start-at: def show_details
:end-at: self.pages.show_page
We use the `Gtk.TreePath`_ passed to this method, along with a `Gtk.TreeIter`_ object, to obtain the file name of the image from the model. A good introduction to this class is provided by the `Tree and List Widgets`_ chapter of the `Python GTK+ 3 Tutorial`_.
We use the `Gtk.TreePath`_ passed to this method, along with a `Gtk.TreeIter`_ object, to obtain the file name of the image from the model. A good introduction to this class is provided by the `Tree and List Widgets`_ chapter of the `Python GTK 3 Tutorial`_.
Summary
-------
......
......@@ -64,6 +64,6 @@ Care must be taken to avoid applying too many rules to the widgets in your appli
Further Reading
---------------
The `GTK+ CSS Overview`_ and `GTK+ CSS Properties`_ documents on the GNOME developer site are useful for determining which parts of the standard widgets can be styled, and what changes they support.
The `GTK CSS Overview`_ and `GTK CSS Properties`_ documents on the GNOME developer site are useful for determining which parts of the standard widgets can be styled, and what changes they support.
.. include:: /links.txt
......@@ -24,7 +24,7 @@ We also import modules that allow us to create user interfaces:
:start-at: import gi
:end-at: Handy.init
These are standard modules for accessing GTK+ and GNOME features, plus the ``Handy`` module that helps us to create adaptive user interfaces.
These are standard modules for accessing GTK and GNOME features, plus the ``Handy`` module that helps us to create adaptive user interfaces.
The Application Class
---------------------
......
......@@ -39,6 +39,6 @@ Unlike the user interface for the window, the menu's UI file was defined in a te
.. literalinclude:: ../app/src/ui/menus.ui
The actions are defined to be application-wide: each has the ``app.`` prefix. Their strings are marked as translatable so that they will be included in the message catalogs described in :ref:`examples_Treasure_po_dir`. Actions are described in more details in the `Actions section`_ of the `Python GTK+ 3 Tutorial`_.
The actions are defined to be application-wide: each has the ``app.`` prefix. Their strings are marked as translatable so that they will be included in the message catalogs described in :ref:`examples_Treasure_po_dir`. Actions are described in more details in the `Actions section`_ of the `Python GTK 3 Tutorial`_.
.. include:: /links.txt
......@@ -11,7 +11,7 @@ This section will show you how to use GNOME Builder for developing, building,
and deploying app flatpaks to a phone shell environment. Apps built from GNOME
Builder can theoretically be deployed on Plasma Mobile as well.
Builder is a fantastic IDE traditionally used for building GNOME GTK+ apps however the fun doesn't have to stop there. It can build KDE apps as long as there is flatpak metadata for the application - more on that later.
Builder is a fantastic IDE traditionally used for building GNOME GTK apps however the fun doesn't have to stop there. It can build KDE apps as long as there is flatpak metadata for the application - more on that later.
First, checkout the `GNOME Builder documentation`_.
......@@ -74,7 +74,7 @@ qemu-aarch64::
********************************************************
Building a C/GTK+3 (libhandy) flatpak with GNOME Builder
Building a C/GTK 3 (libhandy) flatpak with GNOME Builder
********************************************************
For this example, the `geary <https://gitlab.gnome.org/aplazas/geary/tree/wip/aplazas/stackablebox>`_ application will be built (written in C and available in Debian apt repositories). This build was done on an x86 system running Debian testing.
......@@ -127,7 +127,7 @@ Alternatively, you can click the omnibar in Builder and select the "Export Bundl
When the flatpak creation is finished, a nautilus window will pop up in the directory where the sm.puri.Handy.Example.flatpak is located. In this example, the flatpak can be found here: ~/.var/app/org.gnome.Builder/cache/gnome-builder/projects/libhandy/flatpak/staging/arm-wip-stackablebox/sm.puri.Handy.Example.flatpak
**********************************************************************
Deploying a C/GTK+3 (libhandy) flatpak to Phosh running on i.MX6 board
Deploying a C/GTK 3 (libhandy) flatpak to Phosh running on i.MX6 board
**********************************************************************
To run this flatpak you must first get the flatpak onto the dev board and install it.
......
.. _gtk_adaptive_overview:
GTK+
====
GTK
===
`GTK+ <GTK+ website_>`_ is the graphical application framework used to develop all GNOME applications. This guide aims to provide a brief overview of GTK+ applications and tools that can assist in their development.
Applications (apps) for the Librem 5 will typically be built using the
`GTK toolkit`_. In fact many of the apps available will have been ported from
existing apps which are part of the GNOME environment.
This guide aims to provide a brief overview of GTK 3 applications and the tools that can assist in their development. GTK 3.32 is the minimum version that applications on the Librem 5 are expected to use.
.. contents::
:local:
......@@ -57,12 +61,12 @@ Debugging
It can be useful to examine the user interface of a running application for debugging or diagnostic purposes.
The GTK+ Inspector
~~~~~~~~~~~~~~~~~~
The GTK Inspector
~~~~~~~~~~~~~~~~~
The `GTK+ Inspector`_ is a tool giving you direct and dynamic access to the internal state of the user interface of your GTK+ application at runtime. It is similar in concept to a web inspector.
The `GTK Inspector`_ is a tool giving you direct and dynamic access to the internal state of the user interface of your GTK application at runtime. It is similar in concept to a web inspector.
The GTK+ Inspector is an extremely convenient tool to help with debugging your GTK+ application. To use it you first need to enable it via GSettings::
The GTK Inspector is an extremely convenient tool to help with debugging your GTK application. To use it you first need to enable it via GSettings::
$ gsettings set org.gtk.Settings.Debug enable-inspector-keybinding true
......@@ -72,7 +76,7 @@ Alternatively you can set the ``GTK_DEBUG`` environment variable to ``interactiv
$ GTK_DEBUG=interactive your-application
.. note:: For the GTK+ Inspector to work in your flatpaked application, see how to `enable dconf access`_ in the the Flatpak documentation.
.. note:: For the GTK Inspector to work in your flatpaked application, see how to `enable dconf access`_ in the the Flatpak documentation.
.. include:: /links.txt
......
......@@ -3,7 +3,7 @@
Glade
=====
`Glade`_ is a Rapid Application Development (RAD) tool for designing GTK+ based
`Glade`_ is a Rapid Application Development (RAD) tool for designing GTK based
user interfaces (UIs). It provides a visual environment that enables developers
to design UIs for their applications that can be easily accessed by the code
that handles the application logic.
......
.. _gnome_resources:
GTK+/GNOME Resources
====================
GTK/GNOME Resources
===================
When developing an application for the GNOME environment running on a Librem 5
phone, the following resources may contain useful information and advice:
......
......@@ -3,14 +3,7 @@
Developing for GNOME
====================
Applications (apps) for the Librem 5 will typically be built using the
`GTK+ toolkit`_. In fact many of the apps available will have been ported from
existing apps which are part of the GNOME environment. When you write an app or
port a current app to the Librem 5, you are likely going to use tools and
libraries from the GNOME Desktop Environment, building user interfaces
based on GTK+ using the GObject model. There are many supporting libraries
like libsoup for HTTP access or GSettings for settings management, D-Bus
interaction and lower level I/O.
When you write an app or port a current app to the Librem 5, you are likely going to use tools and libraries from the GNOME Desktop Environment, building user interfaces based on GTK using the GObject model. There are many supporting libraries like libsoup for HTTP access or GSettings for settings management, D-Bus interaction and lower level I/O.
See the :ref:`development_environment` chapter of this manual, and especially
the :ref:`workstation` section for an overview of the tools that make up
......@@ -22,7 +15,7 @@ these tools in more detail.
GNOME/Flatpak_setup
GNOME/GBuilder
GNOME/Gtk+
GNOME/GTK
GNOME/Glade
GNOME/Application_Resources
GNOME/Settings
......
......@@ -17,7 +17,7 @@ Introduction
This library is central to the way that adaptive applications are created using GTK. The following sections show how each of its components are employed to make new or existing GTK-based user interfaces adaptable. The :ref:`porting_gnome_apps_guide` guide covers more specific issues related to converting traditional applications to fit the adaptive paradigm.
For general GTK+ and GNOME development resources please consult the :ref:`gnome_resources` page and the `GTK+ 3 documentation`_.
For general GTK and GNOME development resources please consult the :ref:`gnome_resources` page and the `GTK 3 documentation`_.
Style Guidelines
----------------
......
......@@ -29,7 +29,7 @@ A typical developer workflow for porting will involve something like this:
Hints and Tips
--------------
There are some UI elements in GTK+ that are touch-friendly, and therefore ready to use on a phone, while others are not.
There are some UI elements in GTK that are touch-friendly, and therefore ready to use on a phone, while others are not.
A collection of `application mock-ups`_ for GNOME applications should help to give an overview of the presentation and user interface paradigms that developers are using.
......
......@@ -54,7 +54,7 @@ Note the ``id`` property on the object describing the `Gtk.ApplicationWindow`_ w
The ``id`` attribute allows the application code to refer to specific widgets. In this case, the main window of the application can be referred to using the ``window`` identifier.
The ``<requires>`` element contains information about the libraries that provide the components specified in the UI file. In the example, all the components can be provided by GTK+ version 3.20.
The ``<requires>`` element contains information about the libraries that provide the components specified in the UI file. In the example, all the components can be provided by GTK version 3.20.
Creating UI Files
-----------------
......
......@@ -59,7 +59,7 @@ Librem 5 specific:
ID: !CBfWYXjnVtAdBQWXVI:talk.puri.sm
`Libhandy <https://matrix.to/#/#libhandy:talk.puri.sm>`__
For discussions regarding the `libhandy <https://source.puri.sm/Librem5/libhandy>`__ GTK+ library |br|
For discussions regarding the `libhandy <https://source.puri.sm/Librem5/libhandy>`__ GTK library |br|
ID: !nrNOrVsRZxzaDdspgs:talk.puri.sm
`Chatty <https://matrix.to/#/#chatty:talk.puri.sm>`__
......
......@@ -38,7 +38,7 @@ The application should appear on the workstation's screen.
The GNOME Chess application running on the development board and shown on
the workstation's display (click to enlarge)
.. [#] Described in the `Running GTK+ Applications`_ GNOME developer document.
.. [#] Described in the `Running GTK Applications`_ GNOME developer document.
Running Phosh in an X Window
----------------------------
......
......@@ -6,7 +6,7 @@ GNOME
The default software stack for the Librem 5 is based on many of the
`technologies`_ from the `GNOME`_ desktop environment. The applications
supplied with the phone are also built using components from GNOME, such as the
`GTK+ toolkit`_. It can be useful to install the latest development packages in
`GTK toolkit`_. It can be useful to install the latest development packages in
order to get access to features which can help with building mobile
applications.
......
......@@ -4,7 +4,7 @@
Phosh
=====
The Phone's shell Phosh is based on GNOME_ technologies (GTK+, GSettings, DBus)
The Phone's shell Phosh is based on GNOME_ technologies (GTK, GSettings, DBus)
and uses a custom Wayland compositor.
.. image:: Phosh/images/phosh.jpg
......
......@@ -47,7 +47,7 @@
.. _`g_set_application_name`: https://developer.gnome.org/glib/stable/glib-Miscellaneous-Utility-Functions.html#g-set-application-name
.. _`GSimpleAction`: https://developer.gnome.org/gio/2.60/GSimpleAction.html
.. _`GSettings`: https://developer.gnome.org/gio/stable/GSettings.html
.. _`GTK+ 3 documentation`: https://developer.gnome.org/gtk3/stable/
.. _`GTK 3 documentation`: https://developer.gnome.org/gtk3/stable/
.. _GtkApplication: https://developer.gnome.org/gtk3/stable/GtkApplication.html
.. _`Gtk.Application`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Application.html
.. _`GtkApplicationWindow`: https://developer.gnome.org/gtk3/stable/GtkApplicationWindow.html
......@@ -58,14 +58,14 @@
.. _`Gtk.Builder`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Builder.html
.. _GtkButton : https://developer.gnome.org/gtk3/stable/GtkButton.html
.. _`Gtk.CssProvider`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/CssProvider.html
.. _`GTK+ CSS Overview`: https://developer.gnome.org/gtk3/stable/chap-css-overview.html
.. _`GTK+ CSS Properties`: https://developer.gnome.org/gtk3/stable/chap-css-properties.html
.. _`GTK CSS Overview`: https://developer.gnome.org/gtk3/stable/chap-css-overview.html
.. _`GTK CSS Properties`: https://developer.gnome.org/gtk3/stable/chap-css-properties.html
.. _`Gtk.Dialog`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Dialog.html
.. _GtkGrid: https://developer.gnome.org/gtk3/stable/GtkGrid.html
.. _GtkHeaderBar : https://developer.gnome.org/gtk3/stable/GtkHeaderBar.html
.. _`Gtk.IconView`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/IconView.html
.. _`Gtk.Image`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Image.html
.. _`GTK+ Inspector`: https://wiki.gnome.org/Projects/GTK+/Inspector
.. _`GTK Inspector`: https://wiki.gnome.org/Projects/GTK+/Inspector
.. _GtkLabel ellipsize property : https://developer.gnome.org/gtk3/stable/GtkLabel.html#GtkLabel--ellipsize
.. _GtkLabel: https://developer.gnome.org/gtk3/stable/GtkLabel.html
.. _`Gtk.Label`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Label.html
......@@ -85,8 +85,8 @@
.. _Gtk.TreeIter : https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/TreeIter.html
.. _Gtk.TreePath : https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/TreePath.html
.. _Gtk.TreeView : https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/TreeView.html
.. _`GTK+ toolkit`: https://www.gtk.org
.. _`GTK+ website`: https://www.gtk.org/
.. _`GTK toolkit`: https://www.gtk.org
.. _`GTK website`: https://www.gtk.org/
.. _`Gtk.Widget.get_style_context`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Widget.html#Gtk.Widget.get_style_context
.. _`Gtk.Window.set_transient_for`: https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Window.html#Gtk.Window.set_transient_for
.. _`Handy.Dialog`: https://lazka.github.io/pgi-docs/#Handy-0.0/classes/Dialog.html
......@@ -129,7 +129,7 @@
.. _`python-evdev`: https://python-evdev.readthedocs.io/en/latest/usage.html
.. _`python-evdev tutorial`: https://python-evdev.readthedocs.io/en/latest/tutorial.html
.. _`Python gettext module`: https://docs.python.org/3/library/gettext.html
.. _`Python GTK+ 3 Tutorial`: https://python-gtk-3-tutorial.readthedocs.io
.. _`Python GTK 3 Tutorial`: https://python-gtk-3-tutorial.readthedocs.io
.. _`Python locale module`: https://docs.python.org/3/library/locale.html
.. _`python-periphery`: https://python-periphery.readthedocs.io/en/latest/
.. _`qemu`: https://www.qemu.org
......@@ -138,7 +138,7 @@
.. _`Qt documentation`: https://doc.qt.io/qt-5
.. _`Qt Quick`: https://doc.qt.io/qt-5/qtquick-index.html
.. _`Qt Quick Controls 2`: https://doc.qt.io/qt-5/qtquickcontrols2-index.html
.. _`Running GTK+ Applications`: https://developer.gnome.org/gtk3/stable/gtk-running.html
.. _`Running GTK Applications`: https://developer.gnome.org/gtk3/stable/gtk-running.html
.. _`Sandbox Permissions`: http://docs.flatpak.org/en/latest/sandbox-permissions-reference.html
.. _`Scalable Vector Graphics`: https://www.w3.org/TR/SVG/
.. _`Sidebar lists`: https://developer.gnome.org/hig/stable/sidebar-lists.html.en
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment