Title: python.sty correction - verbatim environment
Type: Stage:
Components: Documentation Versions:
Status: closed Resolution: out of date
Dependencies: Superseder:
Assigned To: fdrake Nosy List: fdrake, georg.brandl, smigaj
Priority: normal Keywords: patch

Created on 2005-09-17 12:50 by smigaj, last changed 2007-08-23 20:36 by georg.brandl. This issue is now closed.

File name Uploaded Description Edit
python.sty.verbatim.diff smigaj, 2005-09-17 12:50 python.sty patch
Messages (2)
msg48739 - (view) Author: Wojciech Smigaj (smigaj) Date: 2005-09-17 12:50
This patch alters the way the verbatim environment is
customized in the python.sty package. The old way --
essentially redefining the environment -- made the
verbatim text be surrounded by an excessive, and
somewhat irregular, amount of space. To get rid of it I
propose to use the dedicated \every@verbatim hook and
\verbatim@font commands.

As a result we get code:
- typeset in \small typeface, 
- separated from the preceding and following text by
exactly \parskip (the amount of space separating normal
- indented by \leftmargini -- the indent consistent
with that used e.g. in descriptions.

The code isn't enclosed in a minipage any more, as I
can't see any reason for it now. Consequently, page
breaking inside verbatim text is now permitted (which I
consider a good thing, since listings may be lengthy).

As a minor trouble, the alltt package defining the
environment of the same name does not use the
\every@verbatim hook. However, since the code is rather
short, I propose to include the modified definition in
the python.sty package itself.

A test case: compare how the code included into
"Documenting Python" (doc.tex) looks when latexed with
the original and modified versions of python.sty.
msg55206 - (view) Author: Georg Brandl (georg.brandl) * (Python committer) Date: 2007-08-23 20:36
Obsolete now that we're using reST sources.
Date User Action Args
2007-08-23 20:36:03georg.brandlsetstatus: open -> closed
resolution: out of date
messages: + msg55206
nosy: + georg.brandl
2005-09-17 12:50:52smigajcreate