summaryrefslogtreecommitdiff
path: root/lib/Pod
diff options
context:
space:
mode:
authorRoderick Schertler <roderick@gate.net>1997-02-22 13:03:08 -0500
committerChip Salzenberg <chip@atlantic.net>1997-02-22 02:41:53 +1200
commit78ff9ed7ca04a40a5e1e46df66c3ac95d7315e7d (patch)
tree5a482bde218174a0271d308f22e75c0a4dbb6561 /lib/Pod
parent17f91513ac552043d03e11367fc515f8fe1d0145 (diff)
downloadperl-78ff9ed7ca04a40a5e1e46df66c3ac95d7315e7d.tar.gz
Pod::Text fixes
Here are some bug fixes for Pod::Text. Is it a bug that text given to =for and =begin doesn't get indented? It seems like a bug to me, but I imagine one could argue the other way so I wanted to test opinion before fixing it. p5p-msgid: <350.856634588@eeyore.ibcinc.com>
Diffstat (limited to 'lib/Pod')
-rw-r--r--lib/Pod/Text.pm11
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/Pod/Text.pm b/lib/Pod/Text.pm
index 2ecaebe609..d40abbca94 100644
--- a/lib/Pod/Text.pm
+++ b/lib/Pod/Text.pm
@@ -48,7 +48,7 @@ require Exporter;
@EXPORT = qw(pod2text);
use vars qw($VERSION);
-$VERSION = "1.0201";
+$VERSION = "1.0202";
$termcap=0;
@@ -101,7 +101,7 @@ POD_DIRECTIVE: while (<IN>) {
$begun = "";
}
elsif ($begun eq "text") {
- print STDOUT $_;
+ print OUTPUT $_;
}
next;
}
@@ -119,7 +119,7 @@ POD_DIRECTIVE: while (<IN>) {
if (/^=for\s+(\S+)\s*(.*)/s) {
if ($1 eq "text") {
- print STDOUT $2,"";
+ print OUTPUT $2,"";
} else {
# ignore unknown for
}
@@ -128,7 +128,7 @@ POD_DIRECTIVE: while (<IN>) {
elsif (/^=begin\s+(\S+)\s*(.*)/s) {
$begun = $1;
if ($1 eq "text") {
- print STDOUT $2."";
+ print OUTPUT $2."";
}
next;
}
@@ -211,6 +211,9 @@ sub prepare_for_output {
if ($Cmd eq 'cut') {
$cutting = 1;
}
+ elsif ($Cmd eq 'pod') {
+ $cutting = 0;
+ }
elsif ($Cmd eq 'head1') {
makespace();
print OUTPUT;