[Po4a-commits] po4a/lib/Locale/Po4a Po.pm,1.38,1.39
Nicolas FRAN??OIS
po4a-devel@lists.alioth.debian.org
Sat, 02 Apr 2005 22:19:31 +0000
Update of /cvsroot/po4a/po4a/lib/Locale/Po4a
In directory haydn:/tmp/cvs-serv30243/lib/Locale/Po4a
Modified Files:
Po.pm
Log Message:
Do not convert a tab to spaces when the tab is not at the beginning of a
line.
Index: Po.pm
===================================================================
RCS file: /cvsroot/po4a/po4a/lib/Locale/Po4a/Po.pm,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -d -r1.38 -r1.39
--- Po.pm 22 Mar 2005 12:37:40 -0000 1.38
+++ Po.pm 2 Apr 2005 22:19:29 -0000 1.39
@@ -254,8 +254,8 @@
$output .= format_comment($self->{po}{$msgid}{'comment'},"")
if $self->{po}{$msgid}{'comment'};
- $output .= format_comment($self->{po}{$msgid}{'automatic'},". ")
- if $self->{po}{$msgid}{'automatic'};
+ $output .= format_comment($self->{po}{$msgid}{'automatic'},". ")
+ if $self->{po}{$msgid}{'automatic'};
$output .= format_comment($self->{po}{$msgid}{'type'}," type: ")
if $self->{po}{$msgid}{'type'};
$output .= format_comment($self->{po}{$msgid}{'reference'},": ")
@@ -1063,9 +1063,9 @@
my $text=shift;
print STDERR "\ncanonize [$text]====" if $debug{'canonize'};
$text =~ s/^ *//s;
+ $text =~ s/^[ \t]+/ /gm;
# if ($text eq "\n"), it messed up the first string (header)
$text =~ s/\n/ /gm if ($text ne "\n");
- $text =~ s/\t/ /gm;
$text =~ s/([.)]) +/$1 /gm;
$text =~ s/([^.)]) */$1 /gm;
$text =~ s/ *$//s;