From: Fred Drake Date: Sat, 3 May 2003 02:07:22 +0000 (+0000) Subject: - add title attributes to the navigation icons on the navigation bars; X-Git-Tag: v2.3c1~883 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=8b34e7cc402d1db5694525bd04d9c4b2a8b8b90f;p=python - add title attributes to the navigation icons on the navigation bars; this causes some browsers to offer descriptive tooltips when the mouse hovers over the linked icon - clean up the code in this area --- diff --git a/Doc/perl/l2hinit.perl b/Doc/perl/l2hinit.perl index 6e4b0cbead..0ecb693d80 100644 --- a/Doc/perl/l2hinit.perl +++ b/Doc/perl/l2hinit.perl @@ -141,27 +141,39 @@ sub get_my_icon($) { . " height='32' alt='$text' width='32'>"; } -sub use_my_icon($$) { - my($s,$rel) = @_; - if ($s =~ /\/) { - my $r = get_my_icon($1); - $s =~ s/\/$r/; +sub unlinkify($) { + my $text = "$_[0]"; + $text =~ s|||; + $text =~ s|]*>||i; + return $text; +} + +sub use_icon($$$) { + my($rel,$str,$title) = @_; + if ($title) { + my $s = "$str"; + if ($s =~ /\/) { + my $r = get_my_icon($1); + $s =~ s/\/$r/; + } + $s =~ s/<[aA] /' . "\n"