I've just looked at fancyhdr's doc: I think there's a solution to your pb in §14 Special page layout for float pages.
B.A.
Document Classes ⇒ Indenting subsections using the article.cls
Re: Indenting subsections using the article.cls
Sorry: my last answer incorporated an answer to another question, at the end.
Regards,
B.A.
Regards,
B.A.
Re: Indenting subsections using the article.cls
B.A.
I have found this example, but it does not work. (it's close, but wrong)
I'm beginning to think this is just impossible.
It would help me if you could explain the syntax in the following line (from the example)
\def\section#1{\leftskip=\saveskip\oldsection{#1}\leftskip=\sectskip}
THanks,
Paul
Indentation of Chapter/Sections
To get something like this:
Section
...........................
Subsection
.......................................
.....................
Subsubsection
.............................
............................
Subsection
........................
.............
Section
..................................
..................
insert in Layout->Preamble
\newdimen\sectskip
\newdimen\subsectskip
\newdimen\saveskip
\saveskip=\leftskip
\sectskip=1cm
\subsectskip=2cm
%% etc.
\let\oldsection\section
\let\oldsubsection\subsection
%% etc.
\def\section#1{\leftskip=\saveskip\oldsection{#1}\leftskip=\sectskip}
\def\subsection#1{\leftskip=\sectskip\oldsubsection{#1}\leftskip=\subsectskip}
%% etc.
%%
I have found this example, but it does not work. (it's close, but wrong)
I'm beginning to think this is just impossible.
It would help me if you could explain the syntax in the following line (from the example)
\def\section#1{\leftskip=\saveskip\oldsection{#1}\leftskip=\sectskip}
THanks,
Paul
Indentation of Chapter/Sections
To get something like this:
Section
...........................
Subsection
.......................................
.....................
Subsubsection
.............................
............................
Subsection
........................
.............
Section
..................................
..................
insert in Layout->Preamble
\newdimen\sectskip
\newdimen\subsectskip
\newdimen\saveskip
\saveskip=\leftskip
\sectskip=1cm
\subsectskip=2cm
%% etc.
\let\oldsection\section
\let\oldsubsection\subsection
%% etc.
\def\section#1{\leftskip=\saveskip\oldsection{#1}\leftskip=\sectskip}
\def\subsection#1{\leftskip=\sectskip\oldsubsection{#1}\leftskip=\subsectskip}
%% etc.
%%
Re: Indenting subsections using the article.cls
Your example works (if I've well understood what you want to obtain) if it is slightly modified: try this preamble:
\newdimen\saveskip
\newdimen\sectskip
\newdimen\subsectskip
\newdimen\subsubsectskip
\saveskip=\leftskip
\sectskip=1cm
\subsectskip=2cm
\subsubsectskip=3cm
\let\oldsection\section
\let\oldsubsection\subsection
\let\oldsubsubsection\subsubsection
\def\section#1{\leftskip=\sectskip\oldsection{#1}}%
\def\subsection#1{\leftskip=\subsectskip\oldsubsection{#1}}%
\def\subsubsection#1{\leftskip=\subsubsectskip\oldsubsubsection{#1}}
But what I suggested in a previous message does the same -- as I see it, the only difference is that it introduces new lengths (\sectskip,\subsectskip and so on) to realize the indentions, which might make it easier to have variants of your layout according to the document, for instance. You must know that \leftskip is the name, in Plain TeX, of the 'glue' (= length) added at the beginning of each line of a paragraph. The default is 0pt, which means that the lines begin at the left margin. The previous code begins by saving the original value of leftskip under the name of \saveskip, then modifies the actual value by setting it to what want for the indention of sections (\leftskip=\sectskip), etc.
So I would suggest the simpler code for the preamble (maybe you would like to save the original value of \leftskip -- I haven't done it):
\let\oldsection\section
\renewcommand{\section}{\leftskip=1cm \oldsection}
\let\oldsubsection\subsection
\renewcommand{\subsection}{\leftskip=2cm \oldsubsection}
\let\oldsubsubsection\subsubsection
\renewcommand{\subsubsection}{\leftskip=3cm \oldsubsubsection}
I've tested both ways: they apparently give the same result.
I hope I've been clear. Also, let me know if it does what you want.
Regards,
B.A.
\newdimen\saveskip
\newdimen\sectskip
\newdimen\subsectskip
\newdimen\subsubsectskip
\saveskip=\leftskip
\sectskip=1cm
\subsectskip=2cm
\subsubsectskip=3cm
\let\oldsection\section
\let\oldsubsection\subsection
\let\oldsubsubsection\subsubsection
\def\section#1{\leftskip=\sectskip\oldsection{#1}}%
\def\subsection#1{\leftskip=\subsectskip\oldsubsection{#1}}%
\def\subsubsection#1{\leftskip=\subsubsectskip\oldsubsubsection{#1}}
But what I suggested in a previous message does the same -- as I see it, the only difference is that it introduces new lengths (\sectskip,\subsectskip and so on) to realize the indentions, which might make it easier to have variants of your layout according to the document, for instance. You must know that \leftskip is the name, in Plain TeX, of the 'glue' (= length) added at the beginning of each line of a paragraph. The default is 0pt, which means that the lines begin at the left margin. The previous code begins by saving the original value of leftskip under the name of \saveskip, then modifies the actual value by setting it to what want for the indention of sections (\leftskip=\sectskip), etc.
So I would suggest the simpler code for the preamble (maybe you would like to save the original value of \leftskip -- I haven't done it):
\let\oldsection\section
\renewcommand{\section}{\leftskip=1cm \oldsection}
\let\oldsubsection\subsection
\renewcommand{\subsection}{\leftskip=2cm \oldsubsection}
\let\oldsubsubsection\subsubsection
\renewcommand{\subsubsection}{\leftskip=3cm \oldsubsubsection}
I've tested both ways: they apparently give the same result.
I hope I've been clear. Also, let me know if it does what you want.
Regards,
B.A.
Re: Indenting subsections using the article.cls
B.A.
Thanks for your patient help.
I have finally made it work. Perhaps all your suggestions have been right all along.
The final difference is this:
If I place a blank line (double carraige return) in-between sections, all is well.
Without the blank line ahead of (and after) a new section or subsection, it produces wierd results.
Please try this and see if you agree.
Thanks Very Much, Once Again.
Problem Solved!
Paul
Thanks for your patient help.
I have finally made it work. Perhaps all your suggestions have been right all along.
The final difference is this:
If I place a blank line (double carraige return) in-between sections, all is well.
Without the blank line ahead of (and after) a new section or subsection, it produces wierd results.
Please try this and see if you agree.
Thanks Very Much, Once Again.
Problem Solved!
Paul
Re: Indenting subsections using the article.cls
You're right: I have the same problem without a blank line. Actually,it seems that tex considers,in that case, the text before the section as being in the same paragraph (the basic tex unit) as the section title itself. Here is a solution: add a \par command just before the \leftskip=..., to force a new paragraph, eg, in the 'short' version:
\renewcommand{\subsection]{\par\leftskip=2cm\oldsubsection}
I tested it (not extensively) and it does the trick, without adding vertical space in case of a blank line.
Regards,
B.A.
\renewcommand{\subsection]{\par\leftskip=2cm\oldsubsection}
I tested it (not extensively) and it does the trick, without adding vertical space in case of a blank line.
Regards,
B.A.