#35576 docbook-stylesheets: Rendering problem with program listings

#35576#5
Date:
1999-04-04 17:25:09 UTC
From:
To:
Consider the following file
-- bug.docbook --
<!doctype book PUBLIC "-//Davenport//DTD DocBook V3.0//EN" [
]>

<book>
  <title>
     Rendering bug?
  </>
  <chapter>
    <title>Observe</>
    <para>
      A file:
      <programlisting>
        <inlinegraphic format=linespecific fileref="example"></>
      </programlisting>
    </para>
  </chapter>
</book>
-- end bug.docbook --

#35576#10
Date:
1999-04-09 07:55:32 UTC
From:
To:
In your main file, you had:

    <para>
      A file:
      <programlisting>
        <inlinegraphic format=linespecific fileref="example"></>
      </programlisting>


For me, if you changed that <inlinegraphic> so it's flush left, the indentation of the first line is fixed.

No, you are correct.

See above.

I don't get this.  We'll need to try to track down what this is.  I'll
need your jadetex rev, and all your tetex revisions currently
installed, please.

Yes, see above.  All my backends (PDF, DVI, HTML) seem to be
consistent.

My TeX file shows:

{\def\Element%
{6}}level 0
        level 1
                level 2
        level 1
level 0\endNode{}

#35576#15
Date:
1999-04-10 09:19:27 UTC
From:
To:
You mean with inlinegraphic align=left? That doesn't work for me.

ii  jadetex         2.2-0.2        LaTeX macros for SGML to DVI/PS/PDF conversi
ii  tetex-base      0.9.990311-2   basic teTeX library files
ii  tetex-bin       0.9.990310-1   teTeX binary files
ii  tetex-dev       0.9.981113-2   kpathsea.a and include files for teTeX
ii  tetex-doc       0.9.990311-2   teTeX documentation
ii  tetex-extra     0.9.990311-2   extra teTeX library files
ii  tetex-lib       0.9.990310-1   shared libkpathsea for teTeX
ii  tetex-nonfree   0.9.990311-2   non-free teTeX library files

Oops. I was a bite careless in my wording of this. What I meant was: the tabs
are present as-is, not translated to some kind of TeX construct (simliar to
LaTeX's "tabbing" environment).

I'm not a plain TeX user. LaTeX ignores whitespace at the start of a line;
this may be generic TeX behaviour.

Ray

#35576#20
Date:
1999-04-10 15:07:17 UTC
From:
To:
JHM> On Fri, Apr 09, 1999 at 03:55:32 -0400, Adam Di Carlo wrote:

JHM> You mean with inlinegraphic align=left? That doesn't work for me.

No, I mean do:

     <para>
      A file:
     <programlisting>
<inlinegraphic format=linespecific fileref="example"></>
     </programlisting>

JHM> ii jadetex 2.2-0.2 LaTeX macros for SGML to DVI/PS/PDF conversi
JHM> ii tetex-base 0.9.990311-2 basic teTeX library files ii tetex-bin
JHM> 0.9.990310-1 teTeX binary files ii tetex-dev 0.9.981113-2
JHM> kpathsea.a and include files for teTeX ii tetex-doc 0.9.990311-2
JHM> teTeX documentation ii tetex-extra 0.9.990311-2 extra teTeX
JHM> library files ii tetex-lib 0.9.990310-1 shared libkpathsea for
JHM> teTeX ii tetex-nonfree 0.9.990311-2 non-free teTeX library files

Hmm... I've just started working with the new TeX stuff.  There's a
new upstream jadetex.
JHM> was: the tabs are present as-is, not translated to some kind of
JHM> TeX construct (simliar to LaTeX's "tabbing" environment).

JHM> I'm not a plain TeX user. LaTeX ignores whitespace at the start
JHM> of a line; this may be generic TeX behaviour.

Ok.... interesting.

Given that the spacing *is* correct in my output (basically, slink +
new docbook-stylesheets), whether or not tabs are represented as such
is irrelevant.  The issue is whether or not the TeX output is correct.

I'm installing the new TeX and new jadetex now.  I'll see if I can
reproduce your problem.  Try it with the SGML file changed as I
outlined above and see if you get better HTML, RTF, etc.

#35576#25
Date:
1999-04-11 20:37:24 UTC
From:
To:
I'm reading the TeXbook; the relevant part is on pp. 46 and 47.
The short story is that space is ignored at the start and at the of a
line and multiple spaces are collapsed into one (end of line character is
converted into a space).  What is space is determined by which characters
have catcode 10; this setting can be changed by the format file and by
any input file.  In Plain TeX, its SPACE and HTAB.

I hope this helps :-)

#35576#30
Date:
1999-06-30 18:34:48 UTC
From:
To:
I've taken a look at the Makefile rendering bug again (tabs being ignored).

As I understand things
- My document uses '<inlinegraphic format=linespecific fileref="example"></>'
  to include the example.
- /usr/lib/sgml/stylesheet/dsssl/docbook/nwalsh/print/dbgraph.dsl causes
  jade to include the file "literally" in it's token stream.
- Jade's TeX backend (in TeXFOTBuilder.cxx's TeXFOTBuilder::characters)
  escapes characters that have special meanings to TeX (but not tabs).
- jadetex formats the TeX file produced by jade's TeX backend.

I've found that the "moreverb" package (part of tetex-extra) contains macros
to handle lines containing tabs.

I'm not familiar enough with jade to be sure, but I suspect that it has a
notion of line-based processing; that could be used, together with the
relevant macros from "moreverb" included in the jadetex format, to handle
tabs correctly.

#35576#35
Date:
1999-08-13 00:38:49 UTC
From:
To:
[Please retain the CC to 35576-forwarded@bugs.debian.org for Debian
 bug tracking log purposes.]

Norm, the included patch add a test case to docboook-stylesheets 1.43
such that more testing on done with '<inlinegraphic
format="linespecific"...>'.

A user has reported that the indentation resulting from this test
(both new cases) are not properly preserved in TeX output.  As such,
it seems to be a bug in either JadeTeX or the TeX backend to Jade.

This is tested with jadetex 2.6.

Sebastian, any thoughts on this?

#35576#40
Date:
1999-08-13 00:43:00 UTC
From:
To:
/ Adam Di Carlo <adam@onshore.com> was heard to say:
| [Please retain the CC to 35576-forwarded@bugs.debian.org for Debian
|  bug tracking log purposes.]
...
| Sebastian, any thoughts on this?

Don't use tabs.
                                        Cheers,
                                          norm

#35576#45
Date:
1999-08-13 01:15:12 UTC
From:
To:
Uh.... what if I wanted to include a Makefile in my documentation,
which traditionally does use tabs?

The RTF renders ok.  Does that mean this is a TeX backend problem?

#35576#50
Date:
1999-08-13 02:21:47 UTC
From:
To:
Sebastian, this is regarding a bug that Ray Dassen has located in
jadetex (I think!).  I send a test case before that demonstrates it,
but further grubbing through my mail file revealed this message.

Please retain the CC for our logs.

"J.H.M. Dassen (Ray)" <jdassen@wi.leidenuniv.nl> writes:

This seems quite correct to me.  It would seem that the inability to
properly condition the input in jadetex is either a bug in jade or
jadetex.  After all, the RTF output comes out ok.

As such I am forwarding this to Sebastian and marking it as forwarded,
and considering it a jadetex rather than a docbook-stylesheets bug.

#35576#55
Date:
1999-08-13 12:16:04 UTC
From:
To:
/ Adam Di Carlo <adam@onshore.com> was heard to say:
| >Don't use tabs.
|
| Uh.... what if I wanted to include a Makefile in my documentation,
| which traditionally does use tabs?

Ugh.

| The RTF renders ok.  Does that mean this is a TeX backend problem?

How does the HTML come out? I'm sure it's a problem in the TeX backend,
where TeX treates tabs as spaces explicitly, but so does HTML, I think.

This could be fixed in the stylesheets, I suppose...

                                        Cheers,
                                          norm

#35576#60
Date:
1999-08-13 13:32:59 UTC
From:
To:
It comes out fine; see
http://www.wi.leidenuniv.nl/~jdassen/onderwijs/stuva/debug/ and
appendix.html in there.

Yes; see my earlier remarks regarding this bug
(http://www.debian.org/Bugs/db/35/35576.html).

I can't say for sure whether it's a jade TeX backend or jadetex problem
though.

HTML (or at least the Netscape I'm using here to render it) treats tabs as
tabs.

Ray

#35576#65
Date:
1999-08-13 15:11:33 UTC
From:
To:
/ "J.H.M. Dassen (Ray)" <jdassen@wi.LeidenUniv.nl> was heard to say:
| HTML (or at least the Netscape I'm using here to render it) treats tabs as
| tabs.

Wow. Ok. Uh, Sebastian, I'm going to leave this one with you :-)

                                        Cheers,
                                          norm

#35576#76
Date:
2016-03-30 16:12:05 UTC
From:
To:
reassign 35576 texlive-htmlxml
notforwarded 35576
stop
BTS cleanup:

- bug still present
- jadetex is a transitional package -> reassigning
- Sebastian Rahtz is dead -> notforwarded

Hilmar