diff options
author | Karl Berry <karl@freefriends.org> | 2006-01-11 23:55:29 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2006-01-11 23:55:29 +0000 |
commit | 48243fdbbe15cb58c4136497707e37637e7d4100 (patch) | |
tree | 9de6f823e6a2520490bab3ea3f0828852d1a8db3 /Master/texmf-dist/source/latex/ncctools/nccparskip.dtx | |
parent | f7ffde8f769cd6f1d473ae231d219b99b3fa5263 (diff) |
trunk/Master/texmf-dist/source/latex/ncctools
git-svn-id: svn://tug.org/texlive/trunk@408 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/ncctools/nccparskip.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/ncctools/nccparskip.dtx | 84 |
1 files changed, 84 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/latex/ncctools/nccparskip.dtx b/Master/texmf-dist/source/latex/ncctools/nccparskip.dtx new file mode 100644 index 00000000000..24ac87568d3 --- /dev/null +++ b/Master/texmf-dist/source/latex/ncctools/nccparskip.dtx @@ -0,0 +1,84 @@ +% \iffalse +%% +%% File: nccparskip.dtx Copyright (C) 2002--2004 by Alexander I. Rozhenko +%% +%<package>\NeedsTeXFormat{LaTeX2e} +%<package>\ProvidesPackage{nccparskip} +%<package> [2004/12/08 v1.1 Parskip Control Package (NCC)] +% +% \changes{v1.01}{2002/01/09}{This version is uploaded to CTAN} +% \changes{v1.02}{2002/02/07}{The package is renamed to nccparskip} +% \changes{v1.1}{2004/12/08}{Documentation was prepared} +% +%<*driver> +\documentclass{ltxdoc} +\usepackage{nccparskip} +\SetParskip{6pt plus 1pt minus .4pt} +\GetFileInfo{nccparskip.sty} +\begin{document} +\title{The \textsf{nccparskip} package\thanks{This file + has version number \fileversion, last + revised \filedate.}} +\author{Alexander I. Rozhenko\\rozhenko@oapmg.sscc.ru} +\date{\filedate} +\maketitle +\DocInput{nccparskip.dtx} +\end{document} +%</driver> +% \fi +% +% \DescribeMacro{\SetParskip} +% The package provides identical distance between all paragraphs except +% section markups. It redefines control list commands and suppress +% |\topskip|, |\partopskip|, and |\itemsep| in lists. As a result, the distance +% between ordinary paragraphs and paragraphs prepared by lists is the same. +% The command |\SetParskip|\marg{distance} controls this distance. +% The default distance is +% \begin{quote} +% |\SetParskip{4pt plus 1pt minus .2pt}| +% \end{quote} +% In this document, we use |\SetParskip{6pt plus 1pt minus .4pt}|. +% \StopEventually{} +% +% \section{The Implementation} +% +% \begin{macro}{\SetParskip} +% Define the command and set list skips to zero length. +% \begin{macrocode} +%<*package> +\newcommand*{\SetParskip}[1]{\setlength{\parskip}{#1}\parsep\parskip} +\partopsep\z@ +\topsep\z@ +\itemsep\z@ +% \end{macrocode} +% \end{macro} +% +% We suppose that list definitions were done in the similar way as +% in standard \LaTeX\ classes. Redefine list control commands: +% \begin{macrocode} +\def\@listi{\leftmargin\leftmargini} +\let\@listI\@listi +\def\@listii{\leftmargin\leftmarginii + \labelwidth\leftmarginii \advance\labelwidth-\labelsep} +\def\@listiii{\leftmargin\leftmarginiii + \labelwidth\leftmarginiii \advance\labelwidth-\labelsep} +% \end{macrocode} +% +% Redefine the |\normalsize|, |\small|, and |\footnotesize| +% commands to avoid the |\@listi| redefinition in them. +% \begin{macrocode} +\let\NCC@normalsize\normalsize +\def\normalsize{\let\NCC@temp\@listi\NCC@normalsize\let\@listi\NCC@temp} +\let\NCC@small\small +\def\small{\let\NCC@temp\@listi\NCC@small\let\@listi\NCC@temp} +\let\NCC@footnotesize\footnotesize +\def\footnotesize{\let\NCC@temp\@listi\NCC@footnotesize\let\@listi\NCC@temp} +% \end{macrocode} +% +% Finally we set defaults: +% \begin{macrocode} +\normalsize +\SetParskip{4pt plus 1pt minus .2pt} +%</package> +% \end{macrocode} +\endinput |