Skip to content

Commit

Permalink
Improved paragraph handling
Browse files Browse the repository at this point in the history
  • Loading branch information
nigelhorne committed Jun 14, 2024
1 parent a1dce5d commit 1f0b04d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions gedcom
Original file line number Diff line number Diff line change
Expand Up @@ -9682,8 +9682,9 @@ sub getaddress {
return $rc;
}

# paragraph => 1: ignore spacing and put it all into one paragraph
sub notes {
# paragraph => 0: ignore spacing and put it all into one paragraph
sub notes
{
my %params = (ref($_[0]) eq 'HASH') ? %{$_[0]} : @_;

my $record = $params{'record'};
Expand Down Expand Up @@ -9719,12 +9720,13 @@ sub notes {
}
$note =~ s/\r//g;
next if($note =~ /^\s*$/);
$note =~ s/\s\s+/ /g;
$note =~ s/ \n/\n/g;
if($paragraph) {
$note =~ s/\n+/\n\t/g;
} else {
$note =~ s/\n+/; /g;
}
$note =~ s/\s\s+/ /g;
$note =~ s/\s+$//g;
$note =~ s/\. /. /g;
$note =~ s/Dr\.\s\s/Dr. /g;
Expand Down

0 comments on commit 1f0b04d

Please sign in to comment.