[Python-checkins] peps: If form-feeds are not going to be used to indicate what can be marked as (original) (raw)
georg.brandl python-checkins at python.org
Wed Mar 23 21:23:29 CET 2011
- Previous message: [Python-checkins] peps: Do not start non-heading content on the first character of the line (after
- Next message: [Python-checkins] peps: Fixed reference [1] to point to the current documentation, not the
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
http://hg.python.org/peps/rev/71bdff24635e changeset: 50:71bdff24635e user: Fred Drake <fdrake at acm.org> date: Wed Jul 26 04:14:30 2000 +0000 summary: If form-feeds are not going to be used to indicate what can be marked as a header, use a non-white character in the first column. This looks a little cleaner.
files: pep2html.py | 29 ++++++++++++----------------- 1 files changed, 12 insertions(+), 17 deletions(-)
diff --git a/pep2html.py b/pep2html.py --- a/pep2html.py +++ b/pep2html.py @@ -59,40 +59,35 @@ if pep: title = "PEP " + pep + " -- " + title if title:
fo.write("<title>%s</title>\n" % cgi.escape(title))
fo.write("\n")fo.write(" <title>%s</title>\n" % cgi.escape(title))
body
- fo.write("\n")
- fo.write("[home]\n")
- fo.write('\n')
- fo.write('[home]\n') if os.path.basename(infile) != "pep-0000.txt":
fo.write("[<a href='.'>index</a>]\n")
- fo.write("
\n\n")
fo.write('[<a href=".">index</a>]\n')
- fo.write('
\n\n') for k, v in header: fo.write("
\n" % (cgi.escape(k), cgi.escape(v))) title = 0%s: %s
- fo.write("\n
")
- fo.write("\n
\n") while 1: line = fi.readline() if not line: break
if line[:1] == "\f":
fo.write("<hr />")
# fo.write("\n</pre><hr /><pre>\n")
title = 1
else:
line = fixpat.sub(lambda x, c=infile: fixanchor(c, x), line)
if title:
if line[0] != "\f":
if line[0].strip(): if line.strip() == "Local Variables:": break fo.write("</pre>\n<h3>%s</h3>\n<pre>" % line.strip())
# fo.write("</pre><h3><tt>%s</tt></h3><pre>\n" % line) title = 0 else:
line = fixpat.sub(lambda x, c=infile: fixanchor(c, x), line) fo.write(line)
- fo.write("\n")
- fo.write("\n")
- fo.write("\n")
- fo.write("\n"
"</body>\n"
fo.close() os.chmod(outfile, 0664)"</html>\n")
-- Repository URL: http://hg.python.org/peps
- Previous message: [Python-checkins] peps: Do not start non-heading content on the first character of the line (after
- Next message: [Python-checkins] peps: Fixed reference [1] to point to the current documentation, not the
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]