summaryrefslogtreecommitdiffstats
path: root/Doc/lib/libnntplib.tex
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1997-07-17 16:34:52 (GMT)
committerGuido van Rossum <guido@python.org>1997-07-17 16:34:52 (GMT)
commite47da0ae04814fab2a0aa6e637de2e4269978017 (patch)
tree1360ad7010b92c02d287e79accc1415c77bedc3e /Doc/lib/libnntplib.tex
parent3c2a056fdd3af1f3b94f134b0cab2bd8050c9703 (diff)
downloadcpython-e47da0ae04814fab2a0aa6e637de2e4269978017.zip
cpython-e47da0ae04814fab2a0aa6e637de2e4269978017.tar.gz
cpython-e47da0ae04814fab2a0aa6e637de2e4269978017.tar.bz2
AMK's megapatch:
* \bcode, \ecode added everywhere * \label{module-foo} added everywhere * A few \seealso sections added. * Indentation fixed inside verbatim in lib*tex files
Diffstat (limited to 'Doc/lib/libnntplib.tex')
-rw-r--r--Doc/lib/libnntplib.tex11
1 files changed, 6 insertions, 5 deletions
diff --git a/Doc/lib/libnntplib.tex b/Doc/lib/libnntplib.tex
index 2641d82..41539b4 100644
--- a/Doc/lib/libnntplib.tex
+++ b/Doc/lib/libnntplib.tex
@@ -1,4 +1,5 @@
\section{Standard Module \sectcode{nntplib}}
+\label{module-nntplib}
\stmodindex{nntplib}
\renewcommand{\indexsubitem}{(in module nntplib)}
@@ -13,7 +14,7 @@ statistics about a newsgroup and print the subjects of the last 10
articles:
\small{
-\begin{verbatim}
+\bcode\begin{verbatim}
>>> s = NNTP('news.cwi.nl')
>>> resp, count, first, last, name = s.group('comp.lang.python')
>>> print 'Group', name, 'has', count, 'articles, range', first, 'to', last
@@ -34,13 +35,13 @@ Group comp.lang.python has 59 articles, range 3742 to 3803
>>> s.quit()
'205 news.cwi.nl closing connection. Goodbye.'
>>>
-\end{verbatim}
+\end{verbatim}\ecode
}
To post an article from a file (this assumes that the article has
valid headers):
-\begin{verbatim}
+\bcode\begin{verbatim}
>>> s = NNTP('news.cwi.nl')
>>> f = open('/tmp/article')
>>> s.post(f)
@@ -48,8 +49,8 @@ valid headers):
>>> s.quit()
'205 news.cwi.nl closing connection. Goodbye.'
>>>
-\end{verbatim}
-
+\end{verbatim}\ecode
+%
The module itself defines the following items:
\begin{funcdesc}{NNTP}{host\optional{\, port}}