SWP 6.0.14 Importing TeX bugs

jm's picture

Thank you for fixing in 6.0.14 the problem in 6.0.13 that importing TeX with equation references added a space before the reference so that, for example, (2) was imported as ( 2).

However, none of the other problems with importing TeX reported in topic SWP 6.0.13 Importing TeX (reproduced below) has been fixed. **Please** fix these for the next release - they are a major impediment to my using SWP 6 for serious work.

Moreover, unfortunately, 6.0.14 has introduced a new bug in importing TeX that was not present in 6.0.13. Specifically, some math that was imported in a TeX field TEX:\genfrac that generated correct PDF output when imported into 6.0.13 generates gobbledygook PDF output when imported into 6.0.14. I attach 2 PDF files that illustrate this. ImportTeX13.pdf was imported using 6.0.13, ImportTeX14.pdf with 6.0.14. Compare the last displayed equation in these two files.

I am finding it exceedingly frustrating that every time you correct a bug in importing TeX that I illustrated in a file in one version of SWP 6 you create a new bug in the next version even with that same file. Could you amend your test procedures to include exporting and then importing the attached file ExportTeX0.sci to make sure that the imported one really is identical to the exported one?

Previous posting

SWP 6.0.13 Importing TeX

I attach 3 files that illustrate serious bugs with importing TeX files into SWP 6.

ExportTeX0.sci is an original file from SWP 6.0.13.
ExportTeX1.tex is the TeX file generated from ExportTeX0.sci by using the Export TeX facility in SWP 6.0.13.
ImportTeX1.sci is the sci file generated from ExportTeX1.tex by using the Import TeX facility in SWP 6.0.13.

If the export and import facilities worked correctly, ImportTeX1.sci would be identical to ExportTeX0.sci. (I did not edit the TeX file directly, so there is nothing there that was not exported by SWP.) It isn't identical in the following respects:

1. Addition of required and non-breaking spaces. Lots of required and non-breaking spaces have been added to ImportTeX1.sci which screw up the formatting. One example is that the equation references have a space added so that they now appear as, for example, ( 2) instead of (2). Another is that, if I edit ImportTeX1.sci and it happens that an added non-breaking space is at the end of a line, the line breaks come in inappropriate places. There seems to be no reason for adding all these required and non-breaking spaces and having them added is extremely inconvenient.

2. Proposition environment. The Proposition environment is not recognised correctly in ImportTeX1.sci - it is just recognised as an "environment", not as a "Proposition" and no numbering appears on-screen. Moreover, Preview PDF has a problem - see #3.

3. Paragraph indent after proposition. In ImportTeX1.sci and the PDF generated from it, there is no paragraph indent following the proposition, even though there is in the PDFs generated directly from ExportTeX0.sci and ExportTeX1.tex.

4. Math not interpreted. In the final displayed equation, the fraction is displayed as the TeX field "TEX: \genfrac" in ImportTeX1.sci, not graphically as it is in ExportTeX0.sci.

5. BIBTEX command not interpreted correctly. The name of the BibTeX style file (in this case agsm) is moved outside the command and the database files are not highlighted under Properties.

Having these bugs in SWP 6 sorted out is a very high priority for me. They are a major impediment to using SWP 6 for serious work. None of my co-authors has yet been prepared to move from SWP 5.5 to SWP 6 - the many bugs in SWP 6 make it slow and frustrating to use and the new features are not sufficient to compensate. So every iteration between co-authors and me requires me to do a lot of manual editing of errors introduced by Import TeX. This is deeply frustrating.

Can you please sort out these bugs for the next release of SWP 6?

AttachmentSize
ImportTeX13.pdf236.18 KB
ImportTeX14.pdf270.93 KB
ExportTeX0.sci583.36 KB
John MacKendrick's picture

Thank you for this and other

Thank you for this and other reports. It looks like you inadvertently attached .pdf files to this message rather than .tex files. Do you think you could re-attach them?

jm's picture

I attached the .pdf files

I attached the .pdf files because I wanted to illustrate the difference in the final displayed equation of the PDF output between importing the same .tex file with 6.0.13 (ImportTeX13.pdf, which shows what the equation is supposed to look like) and 6.0.14 (ImportTeX14.pdf, which shows an incorrect version).

The .tex file I imported was just the .tex file generated by using Export TeX in SWP 6 on the .sci file I attached (ExportTeX0.sci). I don't think it makes any difference to the .tex file whether the export is done using 6.0.13 or 6.0.14. I attach the .tex file exported from 6.0.13 in case it is helpful.

It would be really great if your testing procedure were to ensure that exporting the file ExportTeX0.sci to a .tex file and then reimporting the resulting .tex file into a .sci file generated a .sci file identical to the original. The differences I have identified are the following:

1. Addition of required and non-breaking spaces. Lots of required and non-breaking spaces are added in the imported file that screw up the formatting when the file is edited further. There seems to be no reason to add all these required and non-breaking spaces and having them added is extremely inconvenient.

2. Proposition environment. The Proposition environment is not recognised correctly - it is just recognised as an "environment", not as a "Proposition" and no numbering appears on-screen. Moreover, Preview PDF has a problem - see #3.

3. Paragraph indent after proposition. In the PDF generated from the imported file, there is no paragraph indent following the proposition, even though there is in the PDFs generated directly from ExportTeX0.sci and ExportTeX13.tex.

4. Math not interpreted. In the final displayed equation, the fraction is displayed as the TeX field "TEX: \genfrac", not graphically as it is in ExportTeX0.sci.

5. BIBTEX command not interpreted correctly. The name of the BibTeX style file (in this case agsm) is moved outside the command and the database files are not highlighted under Properties.

If there is anything else I can do to help you track down these problems, please let me know.