Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add user style sheet and conditional branch for appropriate Japanese …
…PDF typesetting * Japanese-specific style sheet for good Japanese typesetting. * conditional branch for using the style sheet if '--lang=ja-JP' specified.
- Loading branch information
AYANOKOUZI, Ryuunosuke
committed
Nov 3, 2015
1 parent
367fcfe
commit bcd1342
Showing
2 changed files
with
40 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -27,6 +27,12 @@ fi | |
cp -a build/dblatex tmp/$OPT_lang/xml/ | ||
cd tmp/$OPT_lang/xml/ | ||
|
||
if [ "${OPT_lang}" = "ja-JP" ]; | ||
then | ||
_XSL_USER_STYLESHEET=./dblatex/librement-ja-JP.xsl; | ||
OPT_opts="--backend=xetex --xsl-user=${_XSL_USER_STYLESHEET} "${OPT_opts}; | ||
This comment has been minimized.
Sorry, something went wrong. |
||
fi | ||
|
||
echo "RUN: dblatex -c dblatex/librement.conf $OPT_opts debian-handbook.xml" | ||
if dblatex -c dblatex/librement.conf $OPT_opts debian-handbook.xml; then | ||
This comment has been minimized.
Sorry, something went wrong.
rhertzog
|
||
targetdir="$topdir/publish/$OPT_lang/Debian/$version/pdf/debian-handbook" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> | ||
<xsl:param name="latex.engine.options"> | ||
<xsl:text>-output-driver='xdvipdfmx'</xsl:text> | ||
<!-- | ||
This is for overriding xelatex's default | ||
-output-driver option 'xdvipdfmx -q -E'. | ||
xdvipdfmx should respect to the Font Embedding Permissions, | ||
'-E' option neglects this behavior and | ||
'-q' will suppress showing the warning. | ||
--> | ||
</xsl:param> | ||
<xsl:param name="xetex.font"> | ||
<xsl:text> | ||
\XeTeXtracingfonts=1 | ||
\defaultfontfeatures+{Scale=0.8} | ||
\setmainfont{DejaVu Serif} | ||
\setsansfont{DejaVu Sans} | ||
\setmonofont{DejaVu Sans Mono} | ||
\usepackage[AutoFallBack=true]{zxjatype} | ||
\usepackage[ipa,scale=0.8]{zxjafont} | ||
% | ||
% Please don't use IPAex family fonts like IPAexMincho and/or IPAexGothic. | ||
% Because some characters are converted into Kangxi radical. | ||
% Example: | ||
% 一 (U+4E00) -> ⼀ (U+2F00), | ||
% 人 (U+4EBA) -> ⼈ (U+2F08), | ||
% 非 (U+975E) -> ⾮ (U+2FAE), | ||
% 高 (U+9AD8) -> ⾼ (U+2FBC) etc... | ||
% This conversion is not problem for printing, but | ||
% is problem for searching pdf and converting pdf into text. | ||
</xsl:text> | ||
</xsl:param> | ||
</xsl:stylesheet> |
Note that --backend=xetex is already set via build/dblatex/librement.conf ("Options: -b xetex").