Hi,

This is also addressed to [email protected] in order to request posting this tidbit onto a password-protected Wiki page. I suggest:
 <http://wiki.lyx.org/Windows/Windows>
since Scientific Word/Workplace users are Windows-only.

Thanks!

---------

Importing Scientific Word/Scientific Workplace (hereinafter SWP) .tex files into LyX is relatively straightforward. The particular procedure that works as of 10 December 2007 is provided below.

Before proceeding, one should consider the issue of included graphics files. One of the allures of SWP, working under MS Windows, has been the ready cutting-pasting of Windows metafiles (.wmf, .emf) via the clipboard, out from some application, as figures into one's document. This, plus punching out the final PDF, could be done without the aggravation of first putting figures into EPS (encapsulated postscript) format, as is the standard handling practice for most other LaTeX setups. With the advent of LyX 1.5 and the contributed metafile2eps utility, one can continue this lazy practice, as the combo will auto-render .wmf that are included in the document, and auto-convert to EPS when time for PDF output.

However, metafile2eps is also great as a standalone utility for converting .wmf into EPS. If one collaborates with others possessing vanilla LaTeX setups and/or on linux, one will need to exchange figures in EPS format. So undertaking such conversions up-front is likely advisable.


STEPS to Convert SW/SWP .tex to LyX .lyx
========================================

If not done already, install the *free* MetafileToEPSConverter, per:
   <http://wiki.lyx.org/Windows/MetafileToEPSConverter>


I.  In SWP, File>SaveAs Portable LaTeX.
This will employ, for instance, the LaTeX-standard \includegraphics directive, and comment-out SWP-specific macros and pragmas. These comment-outs will later show up as harmless ERT (evil red text - embedded TeX commands, but here, merely % comments) in the LyX document. Those can be left alone (harmless), or deleted as desired.


II. Metafile-to-EPS conversion (optional, but recommended)
Convert any figures that are windows metafiles (.wmf, .emf) to .eps:
  A. go to c:\Program Files\LyX15\bin,
      -- right-click metafile2eps.exe, and PinToStartMenu
      -- this makes it easy to invoke the program from the Start Menu
  B.
  - Open Powerpoint and metafile2eps windows
  - drag .wmf file icon into Powerpoint -- should auto-open the graphic
  -- in powerpoint: select-All, Copy
- in metafile2eps window: Edit>paste, then File>ExportEPS (can use button icons) Note that when pasting, the image actually shown in the metafile2eps GUI window may not be the complete figure you were expecting, but don't be alarmed - the complete figure is put to the EPS file intact.

C. In .tex file, using a text editor (e.g., WinVi32, WordPad etc) search/replace ".wmf" to ".eps", etc.


III. The following is a current bug in the behind-scenes tex2lyx converter program; it will someday get fixed (bug 4418). Meanwhile, here's the workaround: In the .tex file, using a text editor (e.g., WinVi32, WordPad etc) search/replace:
  natheight with %natheight
  natwidth with %natwidth


IV. LyX:Document>Settings>LaTeX Preamble:
You may need to change the \usepackage directives to match MikTeX (or whatever LaTeX installation you're employing). For example, there is no such package (at least in MikTeX):
 \usepackage{fancyheadings}
In this case, it's easy to delete this entry in the preamble and find built-in provisions for this functionality under Document>Settings>Page Layout to get what you want.


V. BibTeX Bibliography:
For converted .tex files that included a BibTeX bibliography at the end, at the tail of the resulting LyX document, there will be a grey tag labeled "BibTeX Generated Bibliography" - clicking it pops a menu showing the .bib database files and a selectable bib style.








Frank J. Iannarilli   [EMAIL PROTECTED]
Aerodyne Research, Inc., 45 Manning Road, Billerica, MA 01821 USA
www.aerodyne.com/cosr/cosr.html

Reply via email to