[Date Index][Thread Index]
[Date Prev][Date Next][Thread Prev][Thread Next]
Re: Bug report
- From: Denis Barbier <nospam@thanx>
- Date: Fri, 21 Dec 2001 16:42:51 +0100
On Thu, Dec 20, 2001 at 07:11:29PM +0100, Alvise Belotti wrote:
[...]
> It's me or
> <spaced>, when used in conjunction with <href>,
> lead to a surprising result?
[...]
Hi Alvise,
there is indeed a problem, a patch is attached. You may apply it
against typography.src or your installed typography.wml.
Thanks for your report.
--
Denis Barbier
WML Maintainer
Index: typography.src
===================================================================
RCS file: /home/barbier/cvsdepot/wml/wml_include/des/typography.src,v
retrieving revision 1.31
diff -u -u -r1.31 typography.src
--- typography.src 2001/10/28 21:24:26 1.31
+++ typography.src 2001/12/21 15:35:48
@@ -75,12 +75,10 @@
my $every = int(5 / ($n_char+1));
$every = 1 if ($every < 1);
while ($body) {
- if ($body =~ m|^(</?[a-zA-Z]+[^>]+>)(.*)|s) {
- $body = $2;
+ if ($body =~ s|^(</?[a-zA-Z]+[^>]*>)||s) {
<perl:print: $1 />
}
- elsif ($body =~ m|^(\S+)(.*)|s) {
- $body = $2;
+ elsif ($body =~ s|^([^<\s]+)||s) {
$word = $1;
$word =~ s|\G(.)|$1$pad_char|sg;
<perl:print: $word />
@@ -88,8 +86,15 @@
<perl:print: $pad_line />
}
}
- elsif ($body =~ m|^(\s+)(.*)|s) {
- $body = $2;
+ elsif ($body =~ s|^(\S+)||s) {
+ $word = $1;
+ $word =~ s|\G(.)|$1$pad_char|sg;
+ <perl:print: $word />
+ if (($cnt++ % $every) == 0) {
+ <perl:print: $pad_line />
+ }
+ }
+ elsif ($body =~ s|^(\s+)||s) {
$space = $1;
$space =~ s|\G([^\n])|$pad_char$1|sg;
<perl:print: $space />