All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Nicolas Dechesne" <nicolas.dechesne@linaro.org>
To: Paul Barker <pbarker@konsulko.com>
Cc: YP docs mailing list <docs@lists.yoctoproject.org>
Subject: Re: [PATCH] conf.py: Improve TOC and Outline depth in PDF output
Date: Fri, 13 Nov 2020 11:14:08 +0100	[thread overview]
Message-ID: <CAP71WjxRNQcppAtzJbHdu9wwzQVrWDc5wO=AyNJggCjY5=iC=A@mail.gmail.com> (raw)
In-Reply-To: <20201113095431.7425-1-pbarker@konsulko.com>

On Fri, Nov 13, 2020 at 10:54 AM Paul Barker <pbarker@konsulko.com> wrote:
>
> The default PDF output shows only chapter headings in the table of
> contents and in the outline (aka PDF bookmarks). We should override
> these defaults to set something more suitable.
>
> With a depth of 2 for the TOC we see both section and subsection
> headings which is enough to get the list of classes in the reference
> manual and the list of topics under "Common Tasks" in the development
> manual. Going to a deeper level would make the TOC unwieldy but we do
> want to make sure we can navigate more precisely using the outline
> (commonly shown in a left tab in PDF viewers) so we set the depth to 5
> for the outline.

thanks, it is indeed much better! I updated the file here so that
everyone can check it:
https://people.linaro.org/~nicolas.dechesne/theyoctoproject.pdf

>
> Signed-off-by: Paul Barker <pbarker@konsulko.com>
> ---
>  documentation/conf.py | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/documentation/conf.py b/documentation/conf.py
> index 9a0186f35..a8df6e8f8 100644
> --- a/documentation/conf.py
> +++ b/documentation/conf.py
> @@ -124,3 +124,8 @@ html_last_updated_fmt = '%b %d, %Y'
>
>  # Remove the trailing 'dot' in section numbers
>  html_secnumber_suffix = " "
> +
> +latex_elements = {
> +    'passoptionstopackages': '\PassOptionsToPackage{bookmarksdepth=5}{hyperref}',
> +    'preamble': '\setcounter{tocdepth}{2}',
> +}
> --
> 2.20.1
>

      reply	other threads:[~2020-11-13 10:14 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-13  9:54 [PATCH] conf.py: Improve TOC and Outline depth in PDF output Paul Barker
2020-11-13 10:14 ` Nicolas Dechesne [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAP71WjxRNQcppAtzJbHdu9wwzQVrWDc5wO=AyNJggCjY5=iC=A@mail.gmail.com' \
    --to=nicolas.dechesne@linaro.org \
    --cc=docs@lists.yoctoproject.org \
    --cc=pbarker@konsulko.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.