增加文本主体以拉动页面宽度和高度

增加文本主体以拉动页面宽度和高度

我正在使用fancyhdrgeometry创建一个自定义页面,其中文本将尽可能填充页面。该文档还有其他页面,但由于不相关而被省略。我希望这一页能够最大限度地扩大文本从一侧到另一侧、从上到下的分布。但是,我无法让我的文本跨越整个页面的宽度或高度。这是我迄今为止的代码:

\documentclass[10pt]{article}
\usepackage[paperwidth=8.5in, paperheight=11in, margin=0.5in,showframe]{geometry}

%\usepackage[T1]{fontenc}
%\usepackage[utf8]{inputenc}
%\usepackage{lmodern}
%\usepackage{showframe}

\setlength{\headheight}{64pt}
\setlength{\marginparwidth}{0pt}
\setlength{\textheight}{650pt}
\usepackage{graphicx}
\usepackage{xcolor,colortbl}
%\usepackage{stfloats}
%\usepackage{array}
\usepackage{fancyhdr}
\usepackage{lastpage}
\usepackage{enumitem}
\usepackage{tabularx}

\pagestyle{fancy}

\fancyhf{}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\floatsep}{0pt}
\renewcommand{\textfloatsep}{0pt}
\renewcommand{\intextsep}{0pt}

\chead{

    {\huge \textbf{Some header for other pages} }
}

\cfoot{ {\footnotesize Page \thepage \hspace{1pt} of \pageref{LastPage}}}
\hyphenpenalty=10000

\fancypagestyle{plain}{%
    \fancyhf{} % clear all header and footer fields
    \fancyhead{}% Remove all header contents
    \fancyfoot[C]{{\footnotesize Page \thepage \hspace{1pt} of \pageref{LastPage}}} % except the center
    \renewcommand{\headrulewidth}{0pt}
    \renewcommand{\footrulewidth}{0pt}
    \newgeometry{left=1mm, lmargin=1mm,inner=1mm,right=1mm, rmargin=1mm,outer=1mm, top=1mm, tmargin=1mm,marginparwidth=1mm, marginpar=1mm,papersize={9in,12in}}

}

\begin{document}
\thispagestyle{plain}
\begin{enumerate}[noitemsep]
 \item This is a day of national consecration. And I am certain that on this day my fellow Americans expect that on my induction into the Presidency, I will address them with a candor and a decision which the present situation of our people impels.

\item This is preeminently the time to speak the truth, the whole truth, frankly and boldly. Nor need we shrink from honestly facing conditions in our country today. This great Nation will endure, as it has endured, will revive and will prosper.

\item So, first of all, let me assert my firm belief that the only thing we have to fear is fear itself -- nameless, unreasoning, unjustified terror which paralyzes needed efforts to convert retreat into advance. In every dark hour of our national life, a leadership of frankness and of vigor has met with that understanding and support of the people themselves which is essential to victory. And I am convinced that you will again give that support to leadership in these critical days.

\item In such a spirit on my part and on yours we face our common difficulties. They concern, thank God, only material things. Values have shrunk to fantastic levels; taxes have risen; our ability to pay has fallen; government of all kinds is faced by serious curtailment of income; the means of exchange are frozen in the currents of trade; the withered leaves of industrial enterprise lie on every side; farmers find no markets for their produce; and the savings of many years in thousands of families are gone. More important, a host of unemployed citizens face the grim problem of existence, and an equally great number toil with little return. Only a foolish optimist can deny the dark realities of the moment.

\item And yet our distress comes from no failure of substance. We are stricken by no plague of locusts. Compared with the perils which our forefathers conquered, because they believed and were not afraid, we have still much to be thankful for. Nature still offers her bounty and human efforts have multiplied it. Plenty is at our doorstep, but a generous use of it languishes in the very sight of the supply.

\item Primarily, this is because the rulers of the exchange of mankind's goods have failed, through their own stubbornness and their own incompetence, have admitted their failure, and have abdicated. Practices of the unscrupulous money changers stand indicted in the court of public opinion, rejected by the hearts and minds of men.

\item True, they have tried. But their efforts have been cast in the pattern of an outworn tradition. Faced by failure of credit, they have proposed only the lending of more money. Stripped of the lure of profit by which to induce our people to follow their false leadership, they have resorted to exhortations, pleading tearfully for restored confidence. They only know the rules of a generation of self-seekers. They have no vision, and when there is no vision the people perish.

\item Yes, the money changers have fled from their high seats in the temple of our civilization. We may now restore that temple to the ancient truths. The measure of that restoration lies in the extent to which we apply social values more noble than mere monetary profit.

\item Happiness lies not in the mere possession of money; it lies in the joy of achievement, in the thrill of creative effort. The joy, the moral stimulation of work no longer must be forgotten in the mad chase of evanescent profits. These dark days, my friends, will be worth all they cost us if they teach us that our true destiny is not to be ministered unto but to minister to ourselves, to our fellow men.

\item Recognition of that falsity of material wealth as the standard of success goes hand in hand with the abandonment of the false belief that public office and high political position are to be valued only by the standards of pride of place and personal profit; and there must be an end to a conduct in banking and in business which too often has given to a sacred trust the likeness of callous and selfish wrongdoing. Small wonder that confidence languishes, for it thrives only on honesty, on honor, on the sacredness of obligations, on faithful protection, and on unselfish performance; without them it cannot live.



\end{enumerate}
\end{document}

答案1

newgeometry从页面样式定义中删除plain,并将其放在要修改的页面中。在页面末尾,放置一个,\restoregeometry以便恢复原始页面设置。

\documentclass[10pt]{article}
\usepackage[paperwidth=8.5in, paperheight=11in, margin=0.5in,headheight=64pt,marginparwidth=0pt,textheight=650pt,showframe]{geometry}

%\usepackage[T1]{fontenc}
%\usepackage[utf8]{inputenc}
%\usepackage{lmodern}
%\usepackage{showframe}


%%The following 3 lines are better set in geometry way as above (options to geometry)
%\setlength{\headheight}{64pt}
%\setlength{\marginparwidth}{0pt}
%\setlength{\textheight}{650pt}
\usepackage{graphicx}
\usepackage{xcolor,colortbl}
%\usepackage{stfloats}
%\usepackage{array}
\usepackage{fancyhdr}
\usepackage{lastpage}
\usepackage{enumitem}
\usepackage{tabularx}

\pagestyle{fancy}

\fancyhf{}
\renewcommand{\headrulewidth}{0pt}
\renewcommand{\floatsep}{0pt}
\renewcommand{\textfloatsep}{0pt}
\renewcommand{\intextsep}{0pt}

\chead{
    {\huge \textbf{Some header for other pages} }
}

\cfoot{ {\footnotesize Page \thepage \hspace{1pt} of \pageref{LastPage}}}
\hyphenpenalty=10000

\fancypagestyle{plain}{%
    \fancyhf{} % clear all header and footer fields
    \fancyhead{}% Remove all header contents
    \fancyfoot[C]{{\footnotesize Page \thepage \hspace{1pt} of \pageref{LastPage}}} % except the center
    \renewcommand{\headrulewidth}{0pt}
    \renewcommand{\footrulewidth}{0pt}
}

\usepackage{lipsum}

\begin{document}
\lipsum
\thispagestyle{plain}
\newgeometry{left=1mm, lmargin=1mm,inner=1mm,right=1mm, rmargin=1mm,outer=1mm, top=1mm, tmargin=1mm,marginparwidth=1mm, marginpar=1mm}
\begin{enumerate}[noitemsep]
 \item This is a day of national consecration. And I am certain that on this day my fellow Americans expect that on my induction into the Presidency, I will address them with a candor and a decision which the present situation of our people impels.

\item This is preeminently the time to speak the truth, the whole truth, frankly and boldly. Nor need we shrink from honestly facing conditions in our country today. This great Nation will endure, as it has endured, will revive and will prosper.

\item So, first of all, let me assert my firm belief that the only thing we have to fear is fear itself -- nameless, unreasoning, unjustified terror which paralyzes needed efforts to convert retreat into advance. In every dark hour of our national life, a leadership of frankness and of vigor has met with that understanding and support of the people themselves which is essential to victory. And I am convinced that you will again give that support to leadership in these critical days.

\item In such a spirit on my part and on yours we face our common difficulties. They concern, thank God, only material things. Values have shrunk to fantastic levels; taxes have risen; our ability to pay has fallen; government of all kinds is faced by serious curtailment of income; the means of exchange are frozen in the currents of trade; the withered leaves of industrial enterprise lie on every side; farmers find no markets for their produce; and the savings of many years in thousands of families are gone. More important, a host of unemployed citizens face the grim problem of existence, and an equally great number toil with little return. Only a foolish optimist can deny the dark realities of the moment.

\item And yet our distress comes from no failure of substance. We are stricken by no plague of locusts. Compared with the perils which our forefathers conquered, because they believed and were not afraid, we have still much to be thankful for. Nature still offers her bounty and human efforts have multiplied it. Plenty is at our doorstep, but a generous use of it languishes in the very sight of the supply.

\item Primarily, this is because the rulers of the exchange of mankind's goods have failed, through their own stubbornness and their own incompetence, have admitted their failure, and have abdicated. Practices of the unscrupulous money changers stand indicted in the court of public opinion, rejected by the hearts and minds of men.

\item True, they have tried. But their efforts have been cast in the pattern of an outworn tradition. Faced by failure of credit, they have proposed only the lending of more money. Stripped of the lure of profit by which to induce our people to follow their false leadership, they have resorted to exhortations, pleading tearfully for restored confidence. They only know the rules of a generation of self-seekers. They have no vision, and when there is no vision the people perish.

\item Yes, the money changers have fled from their high seats in the temple of our civilization. We may now restore that temple to the ancient truths. The measure of that restoration lies in the extent to which we apply social values more noble than mere monetary profit.

\item Happiness lies not in the mere possession of money; it lies in the joy of achievement, in the thrill of creative effort. The joy, the moral stimulation of work no longer must be forgotten in the mad chase of evanescent profits. These dark days, my friends, will be worth all they cost us if they teach us that our true destiny is not to be ministered unto but to minister to ourselves, to our fellow men.

\item Recognition of that falsity of material wealth as the standard of success goes hand in hand with the abandonment of the false belief that public office and high political position are to be valued only by the standards of pride of place and personal profit; and there must be an end to a conduct in banking and in business which too often has given to a sacred trust the likeness of callous and selfish wrongdoing. Small wonder that confidence languishes, for it thrives only on honesty, on honor, on the sacredness of obligations, on faithful protection, and on unselfish performance; without them it cannot live.
\end{enumerate}
\restoregeometry
\lipsum
\end{document}

在此处输入图片描述

我没有注意 pade 设置尺寸。您必须对其进行微调,因为在此代码中,设置(尺寸)显然看起来是错误的(请参阅第三页中的标题)。

相关内容