Package: txt2tags
Version: 2.3-1
Severity: normal
Tags: patch

Hi,

txt2tags fails to produce valid xhtml output in blockquote mode:

$ txt2tags -t xhtml -H -i - -o -
<RET>
<TAB>invalid quotation
<CTRL-D>
        <blockquote>
        invalid quotation
        </blockquote>

should be: 
        <blockquote><p>
        quotation
        </p></blockquote>

Please note that this is *unrelated* with the known problem described at the 
begining 
of /usr/bin/txt2tags:
#XXX Paragraph separation not valid inside Quote
# Quote will not have <p></p> inside, instead will close and open
# again the <blockquote>. This really sux in CSS, when defining a
# diferent background color. Still don't know how to fix it.

Here is a fix for the problem I'm describing (NOT fixing the paragraph 
separation bug):

/usr/bin/txt2tags, line 634 (and following) becomes:
           'img'                 : '<img~A~ src="\a" border="0" alt=""/>',
           'blockQuoteOpen'      : '<blockquote><p>'   ,
           'blockQuoteClose'     : '</p></blockquote>'

        },

Once this patch has been applied:
$ txt2tags -t xhtml -H -i - -o -
<RET>
<TAB>valid quotation
<CTRL-D>
        <blockquote><p>
        valid quotation
        </p></blockquote>

One could fix it a few lines above instead, in the html part (I don't know if 
<BLOCKQUOTE> without <P> is valid html). It's a very annoying bug (although 
quite easy 
to fix) because txt2tags produces otherwise nice valid xhtml (AFAICT).

Regards,
Gabriel Kerneis

-- System Information:
Debian Release: 4.0
  APT prefers stable
  APT policy: (990, 'stable'), (500, 'unstable')
Architecture: i386 (i686)
Shell:  /bin/sh linked to /bin/bash
Kernel: Linux 2.6.21-2-686
Locale: LANG=fr_FR, LC_CTYPE=fr_FR (charmap=ISO-8859-1)

Versions of packages txt2tags depends on:
ii  python                        2.4.4-2    An interactive high-level object-o

txt2tags recommends no packages.

-- no debconf information



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to