docs: pdfdocs: Pull LaTeX preamble part out of conf.py
Quote from Jon's remark [1]:
I do notice that Documentation/conf.py is getting large and
unapproachable. At some future point, it might be nice to pull
all of the latex stuff out into a separate file where it won't
scare people who stumble into it by accident.
Pull LaTeX preamble settings added since commit
8b28dabcb401 ("docs:
conf.py: adjust the LaTeX document output") out into
sphinx/kerneldoc-preamble.sty.
It will be copied to the build directory by the added
"latex_additional_files" setting in conf.py.
As a bonus, LaTeX/TeX code can be maintained without escaping backslashes.
To compensate the loss of change history in sphinx/kerneldoc-preamble.sty,
here is a list of changes made in conf.py:
-
3f952dd98450 ("docs: Activate exCJK only in CJK chapters")
-
72fcf0685e87 ("docs: pdfdocs: Prevent column squeezing by tabulary")
-
2807c9430674 ("docs: pdfdocs: Refactor config for CJK document")
-
bdfff457795b ("docs: pdfdocs: Add CJK-language-specific font settings")
-
7c5bb27ea521 ("docs: pdfdocs: Choose Serif font as CJK mainfont if possible")
-
6bfa2b516c26 ("docs: pdfdocs: Preserve inter-phrase space in Korean translations")
-
f144ef5bb8d5 ("docs: pdfdocs: One-half spacing for CJK translations")
-
7d3c799ed4b1 ("docs: pdfdocs: Permit AutoFakeSlant for CJK fonts")
-
34a451fea144 ("docs: pdfdocs: Teach xeCJK about character classes of quotation marks")
-
4d9d28f1b8b7 ("docs: pdfdocs: Fix typo in CJK-language specific font settings")
-
8f48cb2ed89e ("docs: pdfdocs: Adjust \headheight for fancyhdr")
-
3f48a1a2d9dc ("docs: pdfdocs: Tweak width params of TOC")
-
9f213dbba7bc ("docs: pdfdocs: Switch default CJK font to KR variants")
-
25b52a42ce1e ("docs: pdfdocs: Enable CJKspace in TOC for Korean titles")
-
132b58368ad4 ("docs/translations: Skip CJK contents if suitable fonts not found")
-
85ebdf00e282 ("docs: pdfdocs: Move CJK monospace font setting to main conf.py")
[1]: https://lore.kernel.org/all/87zgmr66cn.fsf@meer.lwn.net/
Suggested-by: Jonathan Corbet <corbet@lwn.net>
Signed-off-by: Akira Yokosawa <akiyks@gmail.com>
Link: https://lore.kernel.org/r/aaa9dca1-27c0-c414-77f3-c5587db0cc5b@gmail.com
Signed-off-by: Jonathan Corbet <corbet@lwn.net>