On Sat, Sep 23, 2006 at 08:24:21PM +0200, Andreas Karlsson wrote: > I miss the possibility to export LyX documents to RTF directly from inside > LyX. > > Wouldn't it be possible to construct such an export function with the help > of the open source LaTeX2RTF software (http://latex2rtf.sourceforge.net/) by > somehow including it in LyX or modifying it?
Yes, it is possible. After installing latex2rtf, simply put the following two lines in "$HOME/.lyx/preferences" if you use a Linux like OS, or in "%USERPROFILE%/Application Data/LyX1.4.x/preferences" if you are on Windows (I am not sure where the preferences file is on the Mac): \format "rtf" "rtf" "RTF" "" "your_viewer" "" \converter "latex" "rtf" "latex2rtf -p -S $$i" "needaux" substituting "your_viewer" with a program able to show you an RTF file. If you are on Windows or Mac, simply use "auto" as "your_viewer". After starting LyX you should have a View->RTF menu entry. If you omit your_viewer such that you have two lines like these: \format "rtf" "rtf" "RTF" "" "" "" \converter "latex" "rtf" "latex2rtf -p -S $$i" "needaux" then you won't have a View->RTF menu entry but you will nevertheless be able to export to RTF through File->Export->RTF. Be warned that the Windows port of latex2rtf should be invoked as latex2rt (i.e., without the final 'f') and you should probably specify the full path to latex2rt.exe. If later on you want modify something, I suggest that you use the LyX GUI through "Tools->Preferences->File formats" for changing the RTF viewer, and "Tools->Preferences->Converters" for changing the command invoking latex2rtf. -- Enrico