lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <0e610cbb57e85864b23d2b8fffa65c6b137daaac.1607597287.git.mchehab+huawei@kernel.org>
Date:   Thu, 10 Dec 2020 11:55:40 +0100
From:   Mauro Carvalho Chehab <mchehab+huawei@...nel.org>
To:     Linux Media Mailing List <linux-media@...r.kernel.org>
Cc:     linuxarm@...wei.com, mauro.chehab@...wei.com,
        Mauro Carvalho Chehab <mchehab+huawei@...nel.org>,
        Jonathan Corbet <corbet@....net>, linux-doc@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: [PATCH 01/13] docs: conf.py: fix sphinx version detection for margin set

The PDF generator has a logic to detect the proper way to
setup the page margins. By default, the page has about
14.8 cm, which is too short to display some tables and literal
blocks. So, previous patches changed it to be around 17.5 cm,
but the logic only works with Sphinx version 1.x.x.

Fix it.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@...nel.org>
---
 Documentation/conf.py | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/Documentation/conf.py b/Documentation/conf.py
index ed2b43ec7754..66e121df59cd 100644
--- a/Documentation/conf.py
+++ b/Documentation/conf.py
@@ -375,9 +375,10 @@ if cjk_cmd.find("Noto Sans CJK SC") >= 0:
 if major == 1 and minor > 3:
     latex_elements['preamble']  += '\\renewcommand*{\\DUrole}[2]{ #2 }\n'
 
+# Set page margins
 if major == 1 and minor <= 4:
     latex_elements['preamble']  += '\\usepackage[margin=0.5in, top=1in, bottom=1in]{geometry}'
-elif major == 1 and (minor > 5 or (minor == 5 and patch >= 3)):
+elif (major == 1 and (minor > 5 or (minor == 5 and patch >= 3))) or (major > 1):
     latex_elements['sphinxsetup'] = 'hmargin=0.5in, vmargin=1in'
     latex_elements['preamble']  += '\\fvset{fontsize=auto}\n'
 
-- 
2.29.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ