[PATCH 0/2] docs: Improve ability to select proper API/XML section

Browse the result at: https://pipo.sk.gitlab.io/-/libvirt/-/jobs/9603174377/artifacts/website/docs... (The security warning happens as my username on gitlab contains a dot.) Peter Krempa (2): docs: Re-order XML schema after API documentation on 'docs' page docs: Render API and XML sections one per line in HTML docs/css/libvirt.css | 11 +++++++ docs/docs.rst | 75 +++++++++++++++++++++++--------------------- 2 files changed, 51 insertions(+), 35 deletions(-) -- 2.49.0

From: Peter Krempa <pkrempa@redhat.com> Swap the order of links to XML schema docs and to the other language docs. The XML schema is usually accessed more. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- docs/docs.rst | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/docs/docs.rst b/docs/docs.rst index 1a958e9cc7..1f16a11e90 100644 --- a/docs/docs.rst +++ b/docs/docs.rst @@ -79,19 +79,6 @@ Application development `QEMU <html/libvirt-libvirt-qemu.html>`__, `LXC <html/libvirt-libvirt-lxc.html>`__ libs -`Language bindings and API modules <bindings.html>`__ - Bindings of the libvirt API for - `c# <csharp.html>`__, - `go <https://pkg.go.dev/libvirt.org/go/libvirt>`__ (`all go modules <golang.html>`__), - `java <https://java.libvirt.org/>`__, - `ocaml <https://ocaml.libvirt.org/>`__, - `perl <https://search.cpan.org/dist/Sys-Virt/>`__, - `python <python.html>`__, - `php <https://php.libvirt.org>`__, - `ruby <https://ruby.libvirt.org/>`__ - and integration API modules for - `D-Bus <dbus.html>`__ - `XML schemas <format.html>`__ Description of the XML schemas for `domains <formatdomain.html>`__, @@ -109,6 +96,19 @@ Application development `checkpoints <formatcheckpoint.html>`__, `backup jobs <formatbackup.html>`__ +`Language bindings and API modules <bindings.html>`__ + Bindings of the libvirt API for + `c# <csharp.html>`__, + `go <https://pkg.go.dev/libvirt.org/go/libvirt>`__ (`all go modules <golang.html>`__), + `java <https://java.libvirt.org/>`__, + `ocaml <https://ocaml.libvirt.org/>`__, + `perl <https://search.cpan.org/dist/Sys-Virt/>`__, + `python <python.html>`__, + `php <https://php.libvirt.org>`__, + `ruby <https://ruby.libvirt.org/>`__ + and integration API modules for + `D-Bus <dbus.html>`__ + `URI format <uri.html>`__ The URI formats used for connecting to libvirt -- 2.49.0

From: Peter Krempa <pkrempa@redhat.com> Finding the correct link to a XML description or API reference section in a big blob of links concatenated in a paragraph is unpleasand and especially for 'capabilities' and 'domain capabilities' following each other. Turn the API and XML reference sections into a list in RST and add CSS to fromat it a bit more compact. Signed-off-by: Peter Krempa <pkrempa@redhat.com> --- docs/css/libvirt.css | 11 +++++++ docs/docs.rst | 69 ++++++++++++++++++++++++-------------------- 2 files changed, 48 insertions(+), 32 deletions(-) diff --git a/docs/css/libvirt.css b/docs/css/libvirt.css index 58ac1d385b..c80b1a54f6 100644 --- a/docs/css/libvirt.css +++ b/docs/css/libvirt.css @@ -123,6 +123,17 @@ img.diagram { margin-bottom: 1em; } +#documentation #application-development ul li p { + padding-bottom: 0px; + padding-top: 0px; +} + +#documentation #application-development ul { + margin-left: 2em; + padding-top: 0px; + padding-bottom: 0px; +} + .removedhv { color: darkred; } diff --git a/docs/docs.rst b/docs/docs.rst index 1f16a11e90..09939c1201 100644 --- a/docs/docs.rst +++ b/docs/docs.rst @@ -60,41 +60,46 @@ Application development ----------------------- `API reference <html/index.html>`__ - Reference manual for the C public API, split in - `common <html/libvirt-libvirt-common.html>`__, - `domain <html/libvirt-libvirt-domain.html>`__, - `domain checkpoint <html/libvirt-libvirt-domain-checkpoint.html>`__, - `domain snapshot <html/libvirt-libvirt-domain-snapshot.html>`__, - `error <html/libvirt-virterror.html>`__, - `event <html/libvirt-libvirt-event.html>`__, - `host <html/libvirt-libvirt-host.html>`__, - `interface <html/libvirt-libvirt-interface.html>`__, - `network <html/libvirt-libvirt-network.html>`__, - `node device <html/libvirt-libvirt-nodedev.html>`__, - `network filter <html/libvirt-libvirt-nwfilter.html>`__, - `secret <html/libvirt-libvirt-secret.html>`__, - `storage <html/libvirt-libvirt-storage.html>`__, - `stream <html/libvirt-libvirt-stream.html>`__ and - `admin <html/libvirt-libvirt-admin.html>`__, - `QEMU <html/libvirt-libvirt-qemu.html>`__, - `LXC <html/libvirt-libvirt-lxc.html>`__ libs + Reference manual for the C public API, split in: + + * `common <html/libvirt-libvirt-common.html>`__ + * `domain <html/libvirt-libvirt-domain.html>`__ + * `domain checkpoint <html/libvirt-libvirt-domain-checkpoint.html>`__ + * `domain snapshot <html/libvirt-libvirt-domain-snapshot.html>`__ + * `error <html/libvirt-virterror.html>`__ + * `event <html/libvirt-libvirt-event.html>`__ + * `host <html/libvirt-libvirt-host.html>`__ + * `interface <html/libvirt-libvirt-interface.html>`__ + * `network <html/libvirt-libvirt-network.html>`__ + * `node device <html/libvirt-libvirt-nodedev.html>`__ + * `network filter <html/libvirt-libvirt-nwfilter.html>`__ + * `secret <html/libvirt-libvirt-secret.html>`__ + * `storage <html/libvirt-libvirt-storage.html>`__ + * `stream <html/libvirt-libvirt-stream.html>`__ + + and the documentation for the API of the additional libs: + + * `admin <html/libvirt-libvirt-admin.html>`__ + * `QEMU <html/libvirt-libvirt-qemu.html>`__ + * `LXC <html/libvirt-libvirt-lxc.html>`__ `XML schemas <format.html>`__ Description of the XML schemas for - `domains <formatdomain.html>`__, - `networks <formatnetwork.html>`__, - `network ports <formatnetworkport.html>`__, - `network filtering <formatnwfilter.html>`__, - `storage <formatstorage.html>`__, - `storage encryption <formatstorageencryption.html>`__, - `capabilities <formatcaps.html>`__, - `domain capabilities <formatdomaincaps.html>`__, - `storage pool capabilities <formatstoragecaps.html>`__, - `node devices <formatnode.html>`__, - `secrets <formatsecret.html>`__, - `snapshots <formatsnapshot.html>`__, - `checkpoints <formatcheckpoint.html>`__, - `backup jobs <formatbackup.html>`__ + + * `domains <formatdomain.html>`__ + * `networks <formatnetwork.html>`__ + * `network ports <formatnetworkport.html>`__ + * `network filtering <formatnwfilter.html>`__ + * `storage <formatstorage.html>`__ + * `storage encryption <formatstorageencryption.html>`__ + * `capabilities <formatcaps.html>`__ + * `domain capabilities <formatdomaincaps.html>`__ + * `storage pool capabilities <formatstoragecaps.html>`__ + * `node devices <formatnode.html>`__ + * `secrets <formatsecret.html>`__ + * `snapshots <formatsnapshot.html>`__ + * `checkpoints <formatcheckpoint.html>`__ + * `backup jobs <formatbackup.html>`__ `Language bindings and API modules <bindings.html>`__ Bindings of the libvirt API for -- 2.49.0

On a Wednesday in 2025, Peter Krempa via Devel wrote:
Browse the result at:
https://pipo.sk.gitlab.io/-/libvirt/-/jobs/9603174377/artifacts/website/docs...
(The security warning happens as my username on gitlab contains a dot.)
Have you considered changing it?
Peter Krempa (2): docs: Re-order XML schema after API documentation on 'docs' page docs: Render API and XML sections one per line in HTML
docs/css/libvirt.css | 11 +++++++ docs/docs.rst | 75 +++++++++++++++++++++++--------------------- 2 files changed, 51 insertions(+), 35 deletions(-)
Reviewed-by: Ján Tomko <jtomko@redhat.com> Jano

On Fri, Apr 04, 2025 at 14:41:13 +0200, Ján Tomko wrote:
On a Wednesday in 2025, Peter Krempa via Devel wrote:
Browse the result at:
https://pipo.sk.gitlab.io/-/libvirt/-/jobs/9603174377/artifacts/website/docs...
(The security warning happens as my username on gitlab contains a dot.)
Have you considered changing it?
Yes; and decided against.
Peter Krempa (2): docs: Re-order XML schema after API documentation on 'docs' page docs: Render API and XML sections one per line in HTML
docs/css/libvirt.css | 11 +++++++ docs/docs.rst | 75 +++++++++++++++++++++++--------------------- 2 files changed, 51 insertions(+), 35 deletions(-)
Reviewed-by: Ján Tomko <jtomko@redhat.com>
Jano
participants (2)
-
Ján Tomko
-
Peter Krempa