HTML --> MIF J'ai installe deux traducteurs pour récuper des fichiers HTML en MIF (Framemaker). Pour ceux qui regrettent avoir utiliser du raw html :) Les deux marchent plus ou moins.... sgml_test: ********** A utiliser comme dans l'exemple suivant: sgml_test HTML MIF < exercice.html > exercice.mif ou encore: htmltomif exercice (sans extension *.html!) html2mif ******** ne traduit pas les chars francais A utiliser comme: html2mif exercice (sans extension *.html!) Fichier README pour sgml_test: ---------------------------------------------------------------------- This is sort of proof-of-concept code for converting HTML to MIF (and some other things). To run it, try: make testm Oh... you might have to go in libwww and do 'make' first. This isn't how I would write the code today, but it works to a certain extent. Enjoy Dan Connolly 7 July 1995 old readme follows... README for HTML design code/ideas as of Feb 1993. This is just a collection of stuff I used to develop the HTML spec. Included are translators: from to plaintext html html mif plaintext mif and perhaps some others. I was working on an extesible, object-oriented architecture for dealing with SGML documents and MIME bodies. Parts of this have been prepared for distribution, but the large majority has not. ---------------------------------------------------------------------- Fichier README pour html2mif: ---------------------------------------------------------------------- HTML to MIF converter Wayne Christopher wayne@icemcfd.com Nov 29, 1994 I've put together a simple HTML to MIF translator for formatting on-line help into a printed copy. There are two basic parts: 1. html2mif, a tcl program (unfortunately it's rather slow but that doesn't matter so much for this application) that takes an html file and produces a mif file. 2. html_template, a set of FrameMaker formats for the tags generated by html2mif. This is a bit rough, so if you have any questions please let me know. It shouldn't be hard to hack it up to accept more HTML constructs if you know HTML, MIF, and Tcl reasonably well. I have used a subset of HTML for easy conversion to FrameMaker, namely the following tags: title h1 h2 h3 h4 h5 p li br pre em strong b i u tt a body head html hr img Also I have defined a new tag, , that encloses text that should not be shown in the on-line version. Mosaic doesn't do the right thing with this exactly if there are newlines, but I'm working on a Tcl/Tk based www viewer that will do what I want here. Take a look at any of the sample.html for an example of what the format looks like. The figures can be done in two ways: RGB format using SGI snapshot, and EPS format from SGI showcase (or other locations also). For the EPS files one should also made screendumps for viewing inside of Mosaic. Mosaic requires images in gif format. To convert the rgb files to gif I used the SGI "togif" program. To convert the html files to Framemaker, I wrote a rather slow tcl program called html2mif. To run it, do (e.g) "html2mif sample". This converts the html file to a mif file that can be imported into framemaker, and also converts rgb files to xwd files using the SGI "toppm" program and then "pnmtoxwd", from the PBMplus package (let me know if you need this). html2mif tries to scale the figures appropriately, and uses the "alt" keyword in the img html tag, if present, to define a scaling factor in DPI (75 is no scaling). This is not what the alt keyword is supposed to be used for but what the heck. Let me know if you find this program useful or have any suggestions. ----------------------------------------------------------------------