summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorFred Drake <fdrake@acm.org>2001-10-26 03:09:27 (GMT)
committerFred Drake <fdrake@acm.org>2001-10-26 03:09:27 (GMT)
commitaf07b2c34fe4166fdb13b9b08e53148034c1318f (patch)
tree0d16959c11f9c4679faf074d5ce295ad679cd9c2 /Doc
parent7f10cce4c144fe47575eda395b6e4691ba0cfa21 (diff)
downloadcpython-af07b2c34fe4166fdb13b9b08e53148034c1318f.zip
cpython-af07b2c34fe4166fdb13b9b08e53148034c1318f.tar.gz
cpython-af07b2c34fe4166fdb13b9b08e53148034c1318f.tar.bz2
Add yet more markup that let's a stylesheet pick out a small bit of the
presentation. This is acceptable since it only occurs in the formatted output and does not affect the document markup.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/perl/python.perl14
1 files changed, 11 insertions, 3 deletions
diff --git a/Doc/perl/python.perl b/Doc/perl/python.perl
index 10dcdd0..54a92c5 100644
--- a/Doc/perl/python.perl
+++ b/Doc/perl/python.perl
@@ -868,6 +868,10 @@ sub get_refcount{
return $REFCOUNTS{"$func:$param"};
}
+
+$TLSTART = '<span class="typelabel">';
+$TLEND = '</span>';
+
sub do_env_cfuncdesc{
local($_) = @_;
my $return_type = next_argument();
@@ -1047,7 +1051,10 @@ sub do_env_excdesc{
local($_) = @_;
my $excname = next_argument();
my $idx = make_str_index_entry("<tt class=\"exception\">$excname</tt>");
- return "<dl><dt><b>exception $idx</b>\n<dd>" . $_ . '</dl>'
+ return ("<dl><dt><b>${TLSTART}exception$TLEND $idx</b>"
+ . "\n<dd>"
+ . $_
+ . '</dl>');
}
sub do_env_fulllineitems{ return do_env_itemize(@_); }
@@ -1060,7 +1067,8 @@ sub handle_classlike_descriptor{
$idx = make_str_index_entry(
"<tt class=\"$what\">$THIS_CLASS</tt> ($what in $THIS_MODULE)" );
$idx =~ s/ \(.*\)//;
- return ("<dl><dt><b>$what $idx</b>(<var>$arg_list</var>)\n<dd>"
+ return ("<dl><dt><b>$TLSTART$what$TLEND $idx</b>"
+ . "(<var>$arg_list</var>)\n<dd>"
. $_
. '</dl>');
}
@@ -1075,7 +1083,7 @@ sub do_env_classdescstar{
$idx = make_str_index_entry(
"<tt class=\"class\">$THIS_CLASS</tt> (class in $THIS_MODULE)");
$idx =~ s/ \(.*\)//;
- return ("<dl><dt><b>class $idx</b>\n<dd>"
+ return ("<dl><dt><b>${TLSTART}class$TLEND $idx</b>\n<dd>"
. $_
. '</dl>');
}