diff Doc/texinputs/python.sty @ 21418:571d5b7b746c legacy-trunk

Add a new environment for whole-paragraph (or longer) notes & warnings.
author Fred Drake <fdrake@acm.org>
date Fri, 14 Dec 2001 22:50:06 +0000
parents f59c6b5dd122
children cc788b3b21b6
line wrap: on
line diff
--- a/Doc/texinputs/python.sty	Fri Dec 14 22:47:19 2001 +0000
+++ b/Doc/texinputs/python.sty	Fri Dec 14 22:50:06 2001 +0000
@@ -919,8 +919,13 @@
   \end{tabular}
 }
 
-\newcommand{\note}[1]{\strong{Note:} #1}
-\newcommand{\warning}[1]{\strong{Warning:} #1}
+\newcommand{\py@noticelabel@note}{Note:}
+\newcommand{\py@noticelabel@warning}{Warning:}
+\newenvironment{notice}[1][note]{
+  \par\strong{\csname py@noticelabel@#1\endcsname}
+}{}
+\newcommand{\note}[1]{\strong{\py@noticelabel@note} #1}
+\newcommand{\warning}[1]{\strong{\py@noticelabel@warning} #1}
 
 % Deprecation stuff.
 % Should be extended to allow an index / list of deprecated stuff.  But