![{pdf-,Xe-}TeX でページ余白を変更する](https://rvso.com/image/281587/%7Bpdf-%2CXe-%7DTeX%20%E3%81%A7%E3%83%9A%E3%83%BC%E3%82%B8%E4%BD%99%E7%99%BD%E3%82%92%E5%A4%89%E6%9B%B4%E3%81%99%E3%82%8B.png)
TeX では、 と を変更する\hsize
と、\vsize
メインのテキスト サイズと dvi 出力のページ サイズが変更されます。pdftex または xetex を使用してドキュメントをコンパイルすると、ページ サイズは A4 のままになります。ページ余白を変更するにはどうすればよいですか?
最小限の例:
\hsize=5cm \vsize=4cm
\footline{\hfil The page ends here!\hfil\the\pageno}
This document leaves much white space when {\tt pdftex\/}ed or {\tt xetex\/}ed.
\bye
答え1
{Lua-、pdf-、Xe-}TeX のソリューション
\hsize=2in \vsize=3in
\pdfpagewidth=4in
\pdfpageheight=5in
\footline{\hfil The page ends here!\hfil\the\pageno}
This document is by far better! Notice that \TeX{} starts every page
one inch away from the upper and left margin.
This example doesn't compile with {\tt tex} anymore.
\bye