Apache OpenOffice (AOO) Bugzilla – Issue 24813
include tex-filter in OOo2.0
Last modified: 2013-08-07 14:42:31 UTC
Is it possible to include the LaTex export filter from Henrik Just in the next release of OO ? http://www.hj-gym.dk/~hj/writer2latex/ It is not a programming effort, just inclusion of some jar files. In Bug 3403 the Latex support is discussed: http://www.openoffice.org/issues/show_bug.cgi?id=3403 I know that further LaTex support needs more development, but at least for the export filter I don't see any problem to quickly include it. I suggest to check this possibility before releasing the next version. This would be a wonderful additional feature compared to Microsoft Word. Remember that also the PDF-export was often mentioned as an argument of OO's superiority over MS. Good publicity.
We can not include it right now. We close to the release and it is not possible to integrate new functionality without further testing. Retarget to 2.0.
Ok, if 1.1.1 is already close, I understand. So what about 1.1.2 ? The patch is working fine on my OO 1.1 (both Lin+Win). It's just adding files to an existing distribution, I didn't have to change any source code or recompile. Furthermore, this is just an export filter (a very important one) that does not collide with the other code of OO. Side-effects ? Guess not. When I see the ambitious goals for 2.0 it looks like it could take very long time to realize them all. Much longer than from 1.1.0 to 1.1.1. Why should the Latex export filter wait so long? It's working already. This filter is a critical factor for success in the scientific community. Many people there have to deliver Latex code for their publications. Whis this, you have a good argument to start your document in OpenOffice (instead of pure Latex plaintext or Winword/Mathtype). As many of them don't like to hack the Latex source code, OO has a good chance to be the 1st choice.
dublicate! *** This issue has been marked as a duplicate of 3404 ***
It's not a duplicate of Bug 3404 (flat XML) ! This is a Latex export filter (including XHMTL+MathML 2.0 support). Also different from a complete Latex support with an input filter (not integrated to OO yet). The big difference is complexity. This patch is ready and functional. The import filter on contrary not. If you're unhappy to release it now, Ok. Just I think that 2.0 is too late, because it's working already. The time between 1.1.1 and 1.1.2 should be enough for a test, or not? I can offer my support for testing (using it already on my productive system).
HI->AMA: Please take a look.
AMA->TL: Please, have a look.
Created attachment 13106 [details] Writer sample document for export
Created attachment 13108 [details] Resulting postscript file after export and conversion from dvi
I checked the LaTeX export from within the Writer by using the sample document provided as attachement. The result can be seen in the attached postscript file. Im quite impressed it looks great to me! ^__^ There are some minor issues like different fontsize, indention of the first line in a formula or text attributes like bold or italic being ignored. But overall it is a great thing and I would like to have it added to OOo. However there is one thing that needs to fixed: If you export a document to the file "abc.tex" for example there will be a temporary file (that is also not removed later) created with the name of "abc-config.xml". That must not be done. No file should ever be created in the office installation directory, usually the permissions for the user prohibit this, e.g. in a multi-user installation. Only the "user" sub-tree may be used for this, any other directory is likely to not work. But since it seems to be an intermediate file that no one needs after the successful export I think the regular temp directory of the system should be used for this. If that one gets fixed we can add the filter to the OOo suite. When it is done just pass this issue back to me and I will have a look at it again and after that I can pass it on to IS for integration. Nice work! ^^
Yes, it's very impressive to see the beautiful LaTeX formulas as an output of OpenOffice ! I'm also happy to see that I'm not the only one who likes this feature to be integrated. Thanks Henrik for this super-feature ! And don't forget that the same filter is also able to export XHTML+MathML, so that Mozilla can display a formula as a formula and not as an ugly GIF. About the "minor issues" : I can't reproduce that this temp-file is located in my installation/program directory with writer2latex 0.3.2beta & OO 1.1.0 on WinXP. This *config.xml is placed in the directory where I save my *.tex file. That's not necessarily bad as it contains some configuration info. Meta-Information could be important because TEX is not XML-based. But I can't judge about this. Layout bugs are not too important for me, because I'm usually changing the default *.sty style to the specific paper-style of the magazine where my publication should go. When editing the source, it's easy with regex "search&replace" to change those format instructions, too. The layout issues will probably never be solved, because LaTex is so much different from Word-Processor formats like MS-Word or OpenOffice. For many features I don't see an equivalent. Also, the rendering of Latex-texts depends on the Latex-distribution, the packages and styles you want to use. You will never get a 1:1 result, but this is also not the point. Mostly, the LaTex-output should be "beautified" and adapted to some specific publication styles. Like the IEEE-magazines that provide a predefined Latex-style. So, anyway, a typical Latex-user would have to edit something in the final text source code. I know, true LaTex-gurus will always write the source code directly. But I prefer an Office application like OO-Writer or MS-Word. Later I can always hack the source when necessary. The lack of equation numbering and bibtex-integration is still an issue, but the existing OO Latex-export is already a very good start.
Wow, I wasn't really expecting Writer2LaTeX to be included in OOo, but I would certainly appreciate if it happens. The issues with formatting of text in formulas should be easy to fix (ie. line starting with text should be left justified, current setting of bold, italic, font should be applied to text). Some details cannot be supported because they are not available in flat xml (which omits settings.xml for formulas). The problem with "abc-config.xml" is a known problem under unix. It's a configuration file (not temporary) and is supposed to end up in the same directory as the document. This works under mswindows, but under unix it depends on how you start OOo. I will fix that. As I see it, there are three other issues that has to be considered before Writer2LaTeX can be included in OOo: 1. The xmerge framework needs some changes and bugfixes. This affects the mobile device filters. I will create a patch and attach it to a separate issue. 2. LaTeX documents generated by Writer2LaTeX currently depends on a special style file "writer.sty". Either this has to be communicated to the user somehow, or Writer2LaTeX should be changed so that it's not needed (necessary definitions could be indluded in the preamble). 3. Writer2LaTeX allows a rather complex configuration, which doesn't have an ui yet. It has to be determined how to handle that. frank7, Writer2LaTeX does support BibTeX, but you will have to turn it on in the configuration: <option name="use_bibtex" value="true" /> <option name="bibtex_style" value="any BibTeX style" /> There is also a BibTeX import filter available (created by Daniel Carrera), see http://www.math.umd.edu/~dcarrera/openoffice/bibtex/filter.html This will import BibTeX data into OOo's bibliography database.
Is the target milstone 1.1.2 still realistic ? The latest version of the Latex export filter 0.3.3a is working fine on my Windows XP machine with OO 1.1.1. Our network administrators want to install MathType for MS Word. This is even more propriate, you can't edit the formulas with a normal Word-Version any more (without MathType installed). If the Sun company would invest some effort into a proper math support of OO, they would have the great oppertunity to sell it within StarOffice. LaTex always belongs to a good math support. When you look at MS-Word, there was never a significant progress for the formula editor in so many years. OO/StarOffice can make it better. You have the chance to win a large user-base in the academic community. Our institutions don't hesitate to pay for good software. At the moment, most of the people I know are not yet convinced because they don't see any advantage. (PDF is done with Adobe). The only strategic advantage I see at the moment is this LaTex support.
no, 1.1.2 does not sound realistic for me, I set target to 1.1.3. mh->tl: shouldn't we try to integrate in 680 first (and ASAP) so that we're in time for 1.1.3 release ? what is the current status and latest release ?
TL->MH: AFAIK the state is still the same as I mentioned above.
Maybe the most interesting question: are there any side effects with other parts of OpenOffice? In my test I didn't notice any. The patch looks uncritical: - adding writer2latex.jar to the classes directory - register the filter - replace xmerge.jar I made a diff between the xmerge.jar and xmergefix.jar archives: there are only functions (java/class) added, not modified So, when not executing the filter, there is no change in the behavior of OO (except in the list of filters). Correct? The status at the moment is already quite impressive. Why hesitate and not just include the current snapshot of writer2latex? A help file could explain the tricks with writer.sty, configuration and temporary files. The default configuration is already good to transfer text and formulas to Latex. Is the problem with the config file location in Unix solved? If not, can we leave it simply static? I had nice results (in Windoze) without touching it.
I have created issue 28561 with a few simple bugfixes for the xmerge framework that are needed for this. Also, I will have a version of Writer2LaTeX ready soon that does not require the additional style file (writer.sty) and does not create the *-config.xml file. This *could* be a possible solution for 1.1.3.
hj->tl Issue 28561 is not accepted yet, but could you anyway have a look at this again? There's a new version of Writer2LaTeX (0.3.3d) available at http://www.hj-gym.dk/~hj/writer2latex/index4.html. This version doesn't generate the *-config.xml file. Also it does not per default require writer.sty. Installation note: It is not *required* to put writer2latex.xml in the classes directory. * Would it be possible to include this in OOo 2.0? (or 1.1.x?) * If yes, how can it be included? Hosting at external.openoffice.org seems to be the simplest solution to me? * Is there any interest to include the XHTML + MathML export too? (cf. Issue 24256 "Exporting to HTML should turn Formulae into MathML not GIFs") Thanks Henrik
In our department, almost everybody is publishing journal and conference articles in LaTex. Last time I tried to create something in MS Office XP (comfortable!) with the intention to convert it to Latex later. That was an awful experience. I wasn't able to export the Powerpoint figures to EPS. The postscript printer drivers (generic + wmf2eps /eps-type) sometimes made just the upper half of the page. All EPS had a wrong bounding box. Sometimes the bbox wasn't even correctable by ghostscript (re-calculate bbox). Then I used OpenOffice to open the Powerpoint graphics, marked the figure and exported to EPS. Perfect! Correct bounding box! For the bibliography, MS Word had nothing to offer. OpenOffice can import BibTex-databases to its own BibDB (with the python program from Daniel Carrera) and export to BibTex (using writer2latex). That's fine. Just the bibliography style in OO looks awful, not acceptable for IEEE publications. But anyway the final paper should be LaTex. In my opinion, OpenOffice has a good potential as a LaTex front-end for people who don't like to write the LaTex-sourcecode directly. Especially the OO Draw tool is fine for creating LaTex EPS figures (if it's not a Matlab curve). Please think about it for the OO version 2.0. Some things could be better, like the bibliography style, formula editor and the Latex import. For the next 1.1.x-releases, the writer2latex-filter would be a good start, because it's already very useful in it's current state. XHTML+MathML export is a very useful feature for good-looking formulas. Pages with GIF-Math-formulas are really awful. Please don't do it like Microsoft, because it's our goal to create a better alternative to MS-Office. The MathML-support of writer2latex is already quite impressive. Of course only with Mozilla and not with MS-Internet-Explorer (best viewed with ... :-) You could make all the Latex- and MathML-support an optional field in the installation dialog, like the Palm filters. But better do it now. I see already a tendency for people to use Microsoft Word instead of Latex in publications. The development version 0.3.3d should be checked for bugs. I tried in different combinations of Java VM versions (1.4.2_02-1.5.0beta) and writer2latex (0.3.2-0.3.3d) versions, all with OO 1.1.2 on WinXP. Quite often I got Java exceptions, like this: There was an error in the conversion java.lang.NullPointerException at java.util.Hashtable.put(Unknown Source) at writer2latex.StyleMap.put(StyleMap.java:70) .... or exeptions in SAX. Now the sample documents work, but not my big 3 MB report (converted from MS-Word to SXW). I don't now what happened, maybe my Java is a bit messed up.
http://andreas.web-graphics.com/quickguide-sxw-xhtml/ another fan-page for the writer2latex XHTML export capabilities
TL->HJ: Sure I will take a look at it. But due to internal schedules it will probably not be within the next 4-6 weeks.
.
Henrik Just is listed at http://www.openoffice.org/copyright/copyrightapproved.html#j so no legal problems with inclusion.
I don't think that's possible to keep the target OOo1.1.3, I change this to OOo1.1.4.
Target set to OOo 2.0 as discussed with AMA, since the decision about integration is not yet made and thus it is too late for 1.1.4.
TL->SBA: LHO has asked for more extensive tests with our bug documents containing master / doctor theses or student work texts to check if the resulting LaTeX documents look as would be expected. Please take over. Thanks!
i'll take over for intensive testing reassigned to jw
not able to make further test because of an incompatibility of the current src680 build and the tool. this incompatibility occurs in any build later than scr680_m49. result -> loop while exporting if we found this error here i will go on with the tests
Currently (SRC680 m58 and higher) the filter is not working and needs to be fixed. A related issued might be #i33702#. TL->Henrik: Please take over. Thanks!
The filter now works again (tested with 680 m62), after applying the patch in issue 33702 to my version of xmerge.jar. For testing purposes, I will attach two files to this issue: New writer2latex.jar New xmergefix.jar (with patches from issues 28561 and 33702) (Both files+source will be available from http://www.hj-gym.dk/~hj/writer2latex next week).
Created attachment 20258 [details] New writer2latex.jar
Created attachment 20259 [details] Patched xmergefix.jar
Reassign to Thomas Lange
TL->JW: Please resume testing with the new version. Thanks!
hello thomas, i tested the tool today, now it works, wich just means it does not loop or crash. but formulars will not be exported in this version. i will attach an odt file wich i created as examle, wich contains a smal formular, a text and a table. the text and the table are in the result .tex file the formular is not. reassigned
Created attachment 20485 [details] example doc
TL->Henrik: Can you have a look please and then assign it back to JW? Thanks!
Created attachment 20530 [details] New writer2latex.jar which does not discard formulas
Oops, sorry about that. A newly introduced bug in Writer2LaTeX discarded all formulas in flat xml. This is fixed in the attached writer2latex.jar. Notes: In 680 m62 I get this error message when exporting a document with formulas: "Error saving the document <name>: Write Error. The file could not be written." Fortunately this is harmless, the file *does* get written The same problem occurs with export to pdf, and is described in issue 38881 - so it has nothing to do with xmerge or writer2latex. Also, because of a problem with the hack from issue 33702, the filter crashes on any document containing objects (except formulas, which are OK).
Reassigned to jw
approved for integration. this tool will be integrated in OOo2 and SO8. we first have to find a cws to add this tool to. i added ic for this issue because before integration we have to patch the xmerge.jar of SO/OOo so there will be a followup task for the integration set to fixed.
set to verified
reopend to include in Cws Latex
reassigned to the developer. added issue to cws integration task changed summery to: include tex-filter in OOo2.0 reassign to me if the cws is ready
Hi Henrik, hi Jack, it seems you are still in the christmas break :-) What is left to see the filter integrated? Thanks, Stefan
hello stefan, henrik just had no access to the cvs server and was not in any project yet, this has been fixed, we needed to know to wich projects he need access, this is known now, a project sw/writer2latex has been added and henrik got its access to our servers, so in think he will start to implement his tool soon
Are there any technical problems including the filter attached to this issue? Is all information for the QA process avaiable? Is it still possible to integrate it into 2.0.0 ?
retarget. We can't make it into 2.0.1. Too many lost time. Please take care about this for 2.0.1.
What's the problem ? In my OO 1.9.109 it's running fine, just the 2 writer2latex files + adding the export filter packages. xmerge.jar does not have to be exchanged any more. Latex-export and Bibtex-export works fine. Very useful for writing Phd and Master thesis. So, why hesitate? You're just losing a good argument what OO can do that MS-Word can't do.
AFAIK Henrik who is taking care of the integration currently has not time available. And since he is a real free-time-contributor and gets not üaid for it (unlike most other here who make their living by working on OOo/SO) it is the natural thing to put work and effort in such thing only when one has the spare time for it. I for my part am glad that he actually had agreed to work on this since otherwise probably no one else would have time for this. So please, unless you yourself are willing to do this on your own don't urge other people that only do these things in their spare time because of interest and hopefully some fun also.
I don't understand your problem. The patch is working fine. What else has to be done except copying the 4 files to the distribution? As I'm not authorized to modify files, I could at least offer testing it under Windows and Linux (which I partly did already).
I must admit I'm not completely sure also. But I think probably some changes in projects like instset_native or maybe even setup are required to do all the missing things that are described in the manual of the download version. As far as I understood currently basically the problem with the jar file was fixed.
I "patched" the recent OO 1.9.113. The thesis of my student looks much better in the Tex-ified version of the OO document, especially the formulas. In fact it's not even real patching, just copying the writer2latex.jar/writer2latex.xml to the programm/classes directory and adding the export filters in the package manager. Effort is < 10 minutes. For adding these 3 or 4 files to the 2.0 distribution package, the effort shouldn't be much higher. Of course we could discuss now until 2006 if and how we could add Tex to OO, but why not just doing it? I'm not authorized to change the files, but for the right person (who?) this should be an easy task. Yes, you're right. For the 0.4 final release of writer2latex the xmerge framework does not have to be upgraded any more. The builtin xmerge.jar does the job. Don't care too much about all the other options and configurations of writer2latex. The default is already a good start. Using the writer2latex.jar in command line mode, you need more setup things from the manual. But as an OO export filter no further configuration is necessary to get a nice Latex export (incl. Formulas and Tables!)
Hi Frank, if you know what is to do. Why you don't fill out the JCA form ( http://contributing.openoffice.org/programming.html ) to get the write access to this CWS(CVS) and submit the code by yourself? As you said, it's not much work to do there. Regards Jörg
What programming? I guess the code (ver 0.4 final) is ready. Henrik made a really fine addition to OO. I'm not experienced enough to play with the CWS/CVS OO packages. This would be too chaotic. It's more a management decision to include it or not. (marketing OO 2.0 not as a MS-Office clone but a suite with additional useful features, PDF is a good example, Latex another one)
I downloaded this export filter and installed it. During the testing process I did not find any problem. It would be nice to see in 2.0... I would like to do something for it. Can someone serve me an example, for examle same registered filter in ooo? What about to put this filter to mobile section of installer (because of dependency). Coping three file and register them not seems to big work and big change in installer. I would like to help to do that 10 minutes work... KAMI
As a non-expert user, may I add my support to Frank's plea for the urgency of adding an export filter? I am about to start writing a short philosophical monograph, and am wondering whether to use TeX to make it more publishable. But I'm not attracted to using a text-markup interface like Lyx, having got used to word processing. I want to revise using pages that are near-proofs, before shipping the MS to publishers in the form they can best use. So I agree with Frank that having a LaTeX export filter could be a strategic issue for the use of OO in the academic community. It's disappointing that although Henrik has apparently fixed the technical issues (thanks from all potential users), the inclusion of the filter in an update continues to slip, and is apparently not even planned for the 2.0 release. The export filter should be conceptually divorced from the idea of a TeX import filter, which looks to me like a mistake, and more generally of TeX emulation. TeX is by design a comprehensive typographical engine, intended to work with markup tags. Adapting a WYSIWYG word processor like OO Writer to do everything TeX can do is probably impossible and anyway pointless. Doing professional-level typography in a word processor should be avoided; it's like using the calculation function in tables within Word instead of a proper spreadsheet. A full TeX emulation would require something as elaborate and unhandy as Quark Express, which nobody (but nobody) uses for creating text. (There may of course be a case for restricted import, say of LaTeX equations.)
*** Issue 53920 has been marked as a duplicate of this issue. ***
as far as I understand most of the work already have been done in child workspace latex. what's the latest status on this ?
Should we do anything more? or just add as scp2 module?
Created attachment 31733 [details] Configuration: Types
Created attachment 31734 [details] Configuration: Filters
It's actually ready to be included, what's missing for integration is to: include it in the build system (the build file is sw/writer2latex/build.xml) include it in the installation. This simply means adding writer2latex.jar to program/classes and including the two attached configuration snippets. If anyone can do that, it will be finished.
In scp2 you only have to do two small changes: In source/ooo/file_ooo.scp you have to add the definition block for the new file. You can use a macro for this: STD_JAR_FILE( gid_File_Jar_Writer2latex, writer2latex) In source/ooo/module_hidden_ooo.scp you have to assign the file to a module. All jar files are included in gid_Module_Root_Files_3, so please include gid_File_Jar_Writer2latex into the corresponding file list. Where have the two configuration snippets to be included?
file_ooo.scp changes may be: STD_JAR_FILE( gid_File_Jar_Writer2latex, writer2latex) File gid_File_Registry_Spool_Oo_TypeDetection_Writer2Latex_Types_Xcu TXT_FILE_BODY; Styles = (PACKED, PATCH); Dir = gid_Dir_Share_Registry_Modules_Oo_TypeDetection_Types; Name = "/registry/spool/w2l_types.xcu"; End File gid_File_Registry_Spool_Oo_TypeDetection_Writer2Latex_Filters_Xcu TXT_FILE_BODY; Styles = (PACKED, PATCH); Dir = gid_Dir_Share_Registry_Modules_Oo_TypeDetection_Filter; Name = "/registry/spool/w2l_filters.xcu"; End File gid_File_Writer2Latex_Xml TXT_FILE_BODY; Name = "writer2latex.xml"; Dir = gid_Dir_Classes; Styles = (PACKED); End ----- Files that yo need to add to gid_Module_Root_Files_3 module in source/ooo/module_hidden_ooo.scp file... gid_File_Jar_Writer2latex, gid_File_Registry_Spool_Oo_TypeDetection_Writer2Latex_Types_Xcu, gid_File_Registry_Spool_Oo_TypeDetection_Writer2Latex_Filters_Xcu, gid_File_Writer2Latex_Xml I am not an scp master, but I think I might be good. is: what is your opinion?
I am not sure if STD_JAR_FILE( gid_File_Jar_Writer2latex, writer2latex) should be: UNO_JAR_FILE( gid_File_Jar_Writer2latex, writer2latex)
Looks good, but some small changes are needed: - The xcu files should not get the PATCH flag. - Only the jar file should be assigned to gid_Module_Root_Files_3, the other three files should be assigned to gid_Module_Root_Files_6 . You have to use UNO_JAR_FILE instead of STD_JAR_FILE, if the jar file contains services, that have to be registered in the serives.rdb.
It seems to me it does not install services. I saw all of java related File entry is between #ifdef SOLAR_JAVA [Filedef] #endif expression. What does SOLAR_JAVA means and should we put this four file in? -- The two file (w2l_filters.xcu and w2l_types).xcu went to \Application Data\OpenOffice.org2\user\uno_packages\cache\uno_packages\AD.tmp_\w2lfilters20.zip\writer2latex if I follow the installation: type unopkg gui 5. Select OpenOffice.org packages and select w2lfilters20.zip using the Add button: So that path might be wrong...
Yes, it is better to include all java related files into a #ifdef SOLAR_JAVA This variable is set in Java envrironments. If there is no Java in the environment, all jar files are not included into the installation set. If your jar files does not contain services, you have to use STD_JAR_FILE. Using UNO_JAR_FILE, the regcomp tool is used during packing process to register the services in the services.rdb file (which is located in the program directory). I do not know, where your files have to be found after calling unopkg. But after the installation they have to be located in the directory defined by gid_Dir_Share_Registry_Modules_Oo_TypeDetection_Filter . Could you find them there? For the path in user\uno_packages\cache after you called unopkg, Daniel can tell you probably more ( I cc'ed him).
Using unopkg [gui] is more the "extensions" way of installing your filter, e.g. you have a downloadable package the user can install into an existing OOo installation. I think this is not intended here, AFAIK you want OOo to come with your filter preinstalled (ready to go) without running any further extensions tool like unopkg... Please have a look at the filters coming with OOo how to do that. If you still want to stick with the unopkg way, then your observation is (partly) right. Your package data is located twice in the cache, one (merged) in the configuration backend folder, and one in the uno_package temp cache; which is ok.
I hope it will work! I put the files in module in the extra-javafilter... Here is the patch...
Created attachment 31854 [details] W2L integration info Javafilter installation file
Created attachment 31855 [details] W2L integration into Javafilter module
Created attachment 31856 [details] Writer2LaTeX version 0.4.1a - required files
writer2latex does not implement any uno services - so STD_JAR_FILE should be OK.
kami_ : If you add your files to a module, that can be selected during the installation, please do not commit the changes we discussed in file_ooo.scp and module_hidden_ooo.scp. Besides you have to define a module name and a module description in file module_javafilter.ulf
Created attachment 31895 [details] javafilter module ulf patch
All required info/files/patch has been added to this issue... henrikjust -> Is the latest files those you sent equal with version 0.4.1a?
The version in cvs (sw/writer2latex) is 0.4 - 0.4.1a is unstable and should not be used.
Created attachment 33283 [details] Latex filter basic integration - not tested...
Latex-basic-integration-2.zip is a patch to include it in the installer, and copy files from the source tree to output tree. Later someone might create a patch that also build Writer2Latex from its sources. Until that, it will be an easy and right solution.
What is the status of this issue? 2.0.2 is close and we have a feature freeze now... kami?
2.0.2 might be good: The latex filters are tested in integration - 2.0.1 HU contained this filter Only the build system integration not tested, someone might review this basic integration into build filter. For 2.0.3 we might target the full (buildtime compile) integration....
I have created the required SCP files. The installation works well, and everything is Ok with the LaTex export filter. Added the four files directly the solver: /solver/680/<targetsystem>/bin/writer2latex.jar /solver/680/<targetsystem>/bin/writer2latex.xml /solver/680/<targetsystem>/xml/registry/spool/w2l_filters.xcu /solver/680/<targetsystem>/xml/registry/spool/w2l_types.xcu That is what we have to resolve. I put the files to /xmerge/download and we have to copy the files into solver with the build system. Also there are a more professional version: The source is available, so we can build the files in OOo build time. ANT cpmpiler files are available, so we ned to adjus thata.
mhayes sus -> Can you help to integrate Writer2Latex filter into build system? We have a builds with W2L that works well (Hungarian, 2.0.1). henrikjust contributed the code of java filter, I contributed the code for scp installer. We need someone who finish the integration, add the W2L's source to xmerge and filter top level modules, to compile Writer2Latex (with ANT) filter during OOo's build. Can you help us? You should use this file: Mon Jan 16 12:57:00 -0800 2006: Latex-basic-integration-2.zip
The source of Writer2Latex 0.4 in zipped format is here: http://www.hj-gym.dk/%7Ehj/writer2latex/writer2latex04.zip
As I recently inherited this area, I will have to take a look into some sources first, but I scheduled some time for next week to evaluate this.
sos -> Last night I wrote a build thing for OOo, but It not worked well. The ant build runs under 0 sec and no latex filter created. Also the filter top level component is stopped with error, So I was not so successful :o( Of ycourse I can post the script, or send it to you for the base..
SUS->kami_ Best thing to attach the script to this issue. Thanks for note.
Created attachment 33417 [details] Latex buildsystem integration patch+source
->SUS I attached the files with patches and source. The problems: 1) Java source does not build, no error the message is talk about successful build. 2) Filter section won't build - I don't know what I missed 3) You should copy writer2latex.xml where is writer2latex.jar goes... Please correct the problems... Thanks, KAMI
It would be good to include some help for the users who don't know the configuration options of W2L. The most important thing is to distinguish between the two main applications of this export filter. First you might want a layout close to what you see in OO. I suppose that's the default configuration. However, if you want to publish a paper, you have to use the Latex-Style of the conference (IEEE style). For this, the W2L default (4.1a) was not good, because it had lots of additional Latex-Macros. With the optional "clean" writer2latex.xml configuration file it's much better for inclusion into existing Latex documents/styles. To faciliate the handling, two export filters "Latex (layout)" and "Latex (clean)" could differentiate those cases. Maybe for future development if this is too complex, or even a completely configurable "option field". At least, for short term, the users should know how to do this manually. In general, congratulations for creating the Latex support. Don't forget to handle this feature to the "marketing" group of OO. I hope this pushes OO in the academic area.
The QA reprentative returned this week, but told me, that only the TEX filters have been tested and not the XHTML, which seem to be part of this bundle. Any informations concerning this bundling? Currently adding xmerge to your 'Latex' CWS and checking the buildproblems you mentioned.
Fixed the ANT script so the build works and enhanced it so a javadoc-zip is delivered. Furthermore, it should work with or without office environment/stand-alone with ANT. Currently resynching the Childworkspace 'latex' to the latest build (m154), afterwards going to check in my changes, but.. To enhance project clarity from the beginning (and spare later CVS handling), I propose that you move all XML configuration files to the dependent Java packages and adapt the sources to access them via the Java Classloader: // starting '/' before the name does not add packagename to filename URL configURL = Object.class.getResource("/" + configFileName); Before I add the sources to the OpenOffice.org CVS. What you think?
Is 'ooomath.sty' used at all?
Yes, I get \usepackage{ooomath} in the Latex-export. So it's used, but not by the export filter, only later if you want to compile the Latex source. Then you have to include the style in the directory of your Latex distribution. I suggest to put those files together with the other XML configuration files in some "latex examples" directory. In the README or Online-Help this could be mentioned.
The problem with the 'ooomath.sty' is that we should ship it along with the rest. And for this we need a location to put it. You may probably need User-Experience to ask where it should go in the installation tree. The second problem with it is that it is NOT required by the Office but is to be used with the local LaTeX installation of the user. That is we need some means (if only documentation) to tell the user about that file in order for him to copy it in the respective directory of his LaTeX installation.
ooomath.sty should be copied to the same location the final exported file is saved, otherwise user can't distribute it, provide it to other people etc. Copying to the local TEXMF tree is possible, but think of distributing the resulting file elsewhere...
That sounds good because the user will be aware of the file this way. The new problem then is that the export dialog/filter needs to be modified to copy the styles file to the same location. I wonder if that is to be done in the filter or in the dialog as postprocess to the filter...
You want to save the style everytime in every directory you're saving TEX files to? You need this style only once, installed in the Latex distribution. I use lots of small OO subchapter files, because in OO it's more comfortable to write. But my final document is Latex (good formula numbering, good Bibtex support, ...). So I even don't need the ooomath style at all. Having tons of additional identical style files in the directories would disturb me. The first I would do is to remove this behaviour in the W2L sources. Anyway, the user should be aware of the different configuration files (clean Latex or layout-similar Latex) and you have to inform about those files somehow. I suppose most people want to edit the Latex source later and prefer the "clean Latex" configuration. What about a comment in the exported file, like "%% for the ooomath.sty and XML sample configuration files, check the ($Programdir)/samples/... directory"
Apropos Style: any idea about how people would use this filter? The typical Latex way of writing is to produce clean code of your Text. Then depending on the publication type you select dedicated styles, like the IEEE-conference style or some Phd book styles. I can't image that people would use the Latex export just like typical Word document sharing. For this, the OpenOffice-Format seems more suitable.
To clear up the ooomath.sty stuff: The package ooomath.sty is *not* used by default, so there should be no need to worry about this file. (To use ooomath.sty the user will have to manally configure Writer2LaTeX; a user who does this will probably know about the file already)
sus writes: "The QA reprentative returned this week, but told me, that only the TEX filters have been tested and not the XHTML, which seem to be part of this bundle. Any informations concerning this bundling?" This is true; export to XHTML 1.0 and XHTML 1.1+MathML is an integrated part of Writer2LaTeX. Since this export has not been approved for integration, the filter snippets w2l_types.xcu and w2l_filters.xcu does not install the XHTML export. If it is approved later, a simple extension of these is all that is needed.
frank888 writes: "Apropos Style: any idea about how people would use this filter? The typical Latex way of writing is to produce clean code of your Text. Then depending on the publication type you select dedicated styles, like the IEEE-conference style or some Phd book styles." The default configuration tries to catch this, by only preserving basic formatting (like bold, italics, centered text). The advanced user can fine-tune this.
removed dbo from CC.
Oh, don't hesitate with the XHTML+MathML support, since Mozilla Firefox 1.5 can display this. I tried with the W2L 0.4.1a and it looks impressive, not as beautiful as with the Latex-engine, but hey, it's true math, not only GIF-pictures. Soon, the computer algebra systems will read and process those formulas. MathML export is already possible in Waterloo Maple(TM) or Mathematica. If you enable this feature, you're the pioneer of Office math publishing, long before the MS-Word/Internet-Explorer tandem will be capable of MathML.
Take over issue to indicate, that I am working on it. So far, I created a uno package of the two Latex filter to install the filter via Office package manager (GUI or unopkg). The creation of a package ease the testing. I will have to debug xmerge as the filter receives an empty DOM tree (might be a misconfiguration of my test package). Is there still a need for the XMergeFix.jar? (after the integration of issues 28561 and 33702) and no issue listed as dependent here? If there are still problems, I would like to integrate the necessary changes into the module itself and make the xmergeFix.jar obsolete.
Started and remove blocking of 24256, as the XHTML filter won't be bundled with this issue. Nevertheless I took over 24256 as well (notes there). To make the filter JAR as lean as possible, only the files required for BibTeX and LaTeX 2e should be bundled. IMHO it is no good to bundle these and add later on only configuration as proposed earlier. By this an undesired dependency between filters would be created that might bring up problems later.
SUS: "Is there still a need for the XMergeFix.jar? (after the integration of issues 28561 and 33702) and no issue listed as dependent here?" AFAIK XMergeFix.jar is only need for OOo 1.1.x installation. I read it from the installation documentation. So In our case It does not need at all.------- "Started and remove blocking of 24256, as the XHTML filter won't be bundled with this issue. Nevertheless I took over 24256 as well (notes there)." So finally do you split up the filter to two parts? One for Latex another for XHTML+MathML? Two of the are very useful.
SUS -> KAMI_: Thanks for your information. I am about to integrate Hendrik's two TeX filter together with their Office configuration and a new ANT script, which creates a JAR with all mandatory parts (still to be selected). Optionally it creates a JavaDoc ZIP and a UNO package of the filter. BTW this ANT script will be able to be used in the Office build env and as well stand-alone. The evaluation of the XHTML export in conjunction with MathML is not dependent to the TeX filters and will therefore be be done in a different task.
Based on the writer2latex Version 0.4 (2005-07-01), I stripped the XHTML part from the filters and attached these sources as ZIP so you might check/enhance them. The ZIP represents the directory structure to be added beneath xmerge/source/. Furthermore, I created an uno package, which is yet unfinished, as it still searches the writer2latex.jar in the <SOFFICE_INSTALL>/program/classpath directory. In case you use it, by tools->package manager or by the unopkg commandline tool you still have to copy the included JAR manually to the class path.
Created attachment 34122 [details] Sources to be added to OpenOffice.org's XMerge module.
Created attachment 34123 [details] UNO package to test the LaTeX filters (incomplete, as the JAR have to be copied manually to program/classes)
sus->jw: Please test the functionality of the LaTeX / BibTeX export filters as provided in my attachments. Everybody else is appealed to test the filter as well. The JAR still have to be copied into the classes directory (as describe earlier) as XMerge is not capable to work with UNO packages. I plan to change this for SO9 (one of the XML based filter requirements I am currently writing on).
*** Issue 62280 has been marked as a duplicate of this issue. ***
Adding now by default the BibTeX and the LaTeX filter to the writer module. Moving the issue back to QA (jw), when the Office and patch build is done (and smoke tested).
Added the BibTeX and LaTeX export filter successfully to PP3 CWS latex
Please check filters in office patch of CWS latex re-open issue and reassign to jw@openoffice.org
reassign to jw@openoffice.org
reset resolution to FIXED
Thank you all for this feature, especially Henrik for the programming!
seen good in the cws latex set to verified. henrik are you still working on the filter? is it possible to send you some bugs and/ or a feature wishlist? some thinks are really unclear to me
FIXED, but I can't find the filter in the OO 2.0.3 release. What happened?
We might call it bad luck... To be able to add this feature, a feature mail and a test plan had to be written, but were missing. The reason it is usually written by implementor but this time by the QA. Unfortunately I was on vacation during the critical time, so I could not clear the situation. I am sorry for this final delay, the CWS will be intregrated in the upcoming patch.
FIXED because it was included in 2.0.4. The target with 2.0.3 was delayed. You can check the CWS status in EIS (http://eis.services.openoffice.org/EIS2/). http://eis.services.openoffice.org/EIS2/cws.ShowCWS?Id=2129&Path=SRC680%2Flatex
Created attachment 37658 [details] simple testcase
Will it integrated to 2.0.4? Thanks, KAMI
STATUS: The Childworkspace (CWS) has passed development and QualityAssurance. Only the gatekeeper stands between the integration into an upcoming build. The gatekeeper will be back on monday and the issues he earlier found in documentation (featuremail and feature test scenarios) are fixed. It looks very promising, that the LaTeX and BibTeX will make it into the 2.0.4. In any case I will keep an eye on this CWS.
Seen good in SRC680_m195 closing