docs: Split dependencies from related libraries

We currently list everything as a dependencies, regardless of whether
it actually is; this is a source of confusion for users that read the
GTK documentation.

Gi-docgen has a new "related" key in the project configuration which
allows us to list libraries that are merely related to the namespace
we are documenting; the "dependencies" key is used to document the
actual namespace dependencies, now.
This commit is contained in:
Emmanuele Bassi 2022-02-12 17:03:22 +00:00
parent c400dce0b1
commit 7a608bda27
5 changed files with 50 additions and 38 deletions

View File

@ -7,13 +7,14 @@ authors = "GTK Development Team"
logo_url = "gtk-logo.svg" logo_url = "gtk-logo.svg"
license = "GPL-2.1-or-later" license = "GPL-2.1-or-later"
description = "The GTK toolkit" description = "The GTK toolkit"
dependencies = [ "GObject-2.0" ]
devhelp = true devhelp = true
[dependencies."GObject-2.0"] dependencies = ["Gdk-4.0"]
name = "GObject"
description = "The base type system library" [dependencies."Gdk-4.0"]
docs_url = "https://docs.gtk.org/gobject/" name = "GDK"
description = "The GTK drawing kit"
docs_url = "https://docs.gtk.org/gdk/"
[theme] [theme]
name = "basic" name = "basic"

View File

@ -7,13 +7,13 @@ authors = "GTK Development Team"
logo_url = "gtk-logo.svg" logo_url = "gtk-logo.svg"
license = "GPL-2.1-or-later" license = "GPL-2.1-or-later"
description = "The GTK toolkit" description = "The GTK toolkit"
dependencies = [ "GObject-2.0" ] dependencies = ["Gdk-4.0"]
devhelp = true devhelp = true
[dependencies."GObject-2.0"] [dependencies."Gdk-4.0"]
name = "GObject" name = "GDK"
description = "The base type system library" description = "The GTK drawing kit"
docs_url = "https://docs.gtk.org/gobject/" docs_url = "https://docs.gtk.org/gdk4/"
[theme] [theme]
name = "basic" name = "basic"

View File

@ -8,7 +8,7 @@ authors = "GTK Development Team"
logo_url = "gtk-logo.svg" logo_url = "gtk-logo.svg"
license = "LGPL-2.1-or-later" license = "LGPL-2.1-or-later"
description = "The GTK toolkit" description = "The GTK toolkit"
dependencies = [ "GObject-2.0", "cairo-1.0", "Pango-1.0", "GdkWayland-4.0", "GdkX11-4.0" ] dependencies = ["GObject-2.0", "Gio-2.0", "cairo-1.0", "Pango-1.0", "GdkPixbuf-2.0"]
devhelp = true devhelp = true
search_index = true search_index = true
@ -17,6 +17,11 @@ search_index = true
description = "The base type system library" description = "The base type system library"
docs_url = "https://docs.gtk.org/gobject/" docs_url = "https://docs.gtk.org/gobject/"
[dependencies."Gio-2.0"]
name = "GIO"
description = "GObject Interfaces and Objects, Networking, IPC, and I/O"
docs_url = "https://docs.gtk.org/gio/"
[dependencies."cairo-1.0"] [dependencies."cairo-1.0"]
name = "Cairo" name = "Cairo"
description = "A 2D graphics library with support for multiple output devices" description = "A 2D graphics library with support for multiple output devices"
@ -27,12 +32,19 @@ search_index = true
description = "Text shaping and rendering" description = "Text shaping and rendering"
docs_url = "https://docs.gtk.org/Pango/" docs_url = "https://docs.gtk.org/Pango/"
[dependencies."GdkWayland-4.0"] [dependencies."GdkPixbuf-2.0"]
name = "GdkPixbuf"
description = "Image data loading"
docs_url = "https://docs.gtk.org/gdk-pixbuf/"
related = ["GdkWayland-4.0", "GdkX11-4.0"]
[related."GdkWayland-4.0"]
name = "GdkWayland" name = "GdkWayland"
description = "GDK Wayland Backend" description = "GDK Wayland Backend"
docs_url = "https://docs.gtk.org/gdk4-wayland/" docs_url = "https://docs.gtk.org/gdk4-wayland/"
[dependencies."GdkX11-4.0"] [related."GdkX11-4.0"]
name = "GdkX11" name = "GdkX11"
description = "GDK X11 Backend" description = "GDK X11 Backend"
docs_url = "https://docs.gtk.org/gdk4-x11/" docs_url = "https://docs.gtk.org/gdk4-x11/"

View File

@ -8,25 +8,16 @@ authors = "GTK Development Team"
logo_url = "gtk-logo.svg" logo_url = "gtk-logo.svg"
license = "LGPL-2.1-or-later" license = "LGPL-2.1-or-later"
description = "The GTK toolkit" description = "The GTK toolkit"
dependencies = [ "GObject-2.0", "Graphene-1.0", "Pango-1.0", "Gdk-4.0" ]
devhelp = true devhelp = true
search_index = true search_index = true
[dependencies."GObject-2.0"] dependencies = ["Graphene-1.0", "Gdk-4.0"]
name = "GObject"
description = "The base type system library"
docs_url = "https://docs.gtk.org/gobject/"
[dependencies."Graphene-1.0"] [dependencies."Graphene-1.0"]
name = "Graphene" name = "Graphene"
description = "A thin layer of mathematical types for 3D libraries" description = "A thin layer of mathematical types for 3D libraries"
docs_url = "https://ebassi.github.io/graphene/docs/" docs_url = "https://ebassi.github.io/graphene/docs/"
[dependencies."Pango-1.0"]
name = "Pango"
description = "Text shaping and rendering"
docs_url = "https://docs.gtk.org/Pango/"
[dependencies."Gdk-4.0"] [dependencies."Gdk-4.0"]
name = "GDK" name = "GDK"
description = "The GTK windowing system abstraction" description = "The GTK windowing system abstraction"

View File

@ -8,24 +8,10 @@ authors = "GTK Development Team"
logo_url = "gtk-logo.svg" logo_url = "gtk-logo.svg"
license = "LGPL-2.1-or-later" license = "LGPL-2.1-or-later"
description = "The GTK toolkit" description = "The GTK toolkit"
dependencies = [ "GObject-2.0", "Graphene-1.0", "Pango-1.0", "Gdk-4.0", "Gsk-4.0" ]
devhelp = true devhelp = true
search_index = true search_index = true
[dependencies."GObject-2.0"] dependencies = ["Gdk-4.0", "Gsk-4.0"]
name = "GObject"
description = "The base type system library"
docs_url = "https://docs.gtk.org/gobject/"
[dependencies."Graphene-1.0"]
name = "Graphene"
description = "A thin layer of mathematical types for 3D libraries"
docs_url = "https://ebassi.github.io/graphene/docs"
[dependencies."Pango-1.0"]
name = "Pango"
description = "Text shaping and rendering"
docs_url = "https://docs.gtk.org/Pango/"
[dependencies."Gdk-4.0"] [dependencies."Gdk-4.0"]
name = "GDK" name = "GDK"
@ -37,6 +23,28 @@ search_index = true
description = "The GTK rendering abstraction" description = "The GTK rendering abstraction"
docs_url = "https://docs.gtk.org/gsk4/" docs_url = "https://docs.gtk.org/gsk4/"
related = ["Pango-1.0", "Graphene-1.0", "GObject-2.0", "Gio-2.0"]
[related."GObject-2.0"]
name = "GObject"
description = "The base type system library"
docs_url = "https://docs.gtk.org/gobject/"
[related."Gio-2.0"]
name = "GIO"
description = "GObject Interfaces and Objects, Networking, IPC, and I/O"
docs_url = "https://docs.gtk.org/gio/"
[related."Graphene-1.0"]
name = "Graphene"
description = "A thin layer of mathematical types for 3D libraries"
docs_url = "https://ebassi.github.io/graphene/docs"
[related."Pango-1.0"]
name = "Pango"
description = "Text shaping and rendering"
docs_url = "https://docs.gtk.org/Pango/"
[theme] [theme]
name = "basic" name = "basic"
show_index_summary = true show_index_summary = true