MS Word converter -> HTML (MS Word) converter

Patch from Alex Fernandez.


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@37321 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Pavel Sanda 2011-01-25 10:26:29 +00:00
parent e0dfcdbdda
commit 297a74b7ad

View File

@ -642,19 +642,14 @@ def checkConverterEntries():
path, elyxer = checkProg('a LyX -> HTML converter', path, elyxer = checkProg('a LyX -> HTML converter',
['elyxer.py --directory $$r $$i $$o', 'elyxer --directory $$r $$i $$o'], ['elyxer.py --directory $$r $$i $$o', 'elyxer --directory $$r $$i $$o'],
rc_entry = [ r'\converter lyx html "%%" ""' ]) rc_entry = [ r'\converter lyx html "%%" ""' ])
path, elyxer = checkProg('a LyX -> MS Word converter', path, elyxer = checkProg('a LyX -> HTML (MS Word) converter',
['elyxer.py --directory $$r $$i $$o', 'elyxer --html --directory $$r $$i $$o'], ['elyxer.py --html --directory $$r $$i $$o', 'elyxer --html --directory $$r $$i $$o'],
rc_entry = [ r'\converter lyx wordhtml "%%" ""' ]) rc_entry = [ r'\converter lyx wordhtml "%%" ""' ])
if elyxer.find('elyxer') >= 0: if elyxer.find('elyxer') >= 0:
elyxerfound = True
else:
elyxerfound = False
if elyxerfound:
addToRC(r'''\copier html "python -tt $$s/scripts/ext_copy.py -e html,png,jpg,jpeg,css $$i $$o"''') addToRC(r'''\copier html "python -tt $$s/scripts/ext_copy.py -e html,png,jpg,jpeg,css $$i $$o"''')
addToRC(r'''\copier wordhtml "python -tt $$s/scripts/ext_copy.py -e html,png,jpg,jpeg,css $$i $$o"''') addToRC(r'''\copier wordhtml "python -tt $$s/scripts/ext_copy.py -e html,png,jpg,jpeg,css $$i $$o"''')
else: else:
# search for other converters than eLyXer # search for HTML converters other than eLyXer
# On SuSE the scripts have a .sh suffix, and on debian they are in /usr/share/tex4ht/ # On SuSE the scripts have a .sh suffix, and on debian they are in /usr/share/tex4ht/
path, htmlconv = checkProg('a LaTeX -> HTML converter', ['htlatex $$i', 'htlatex.sh $$i', \ path, htmlconv = checkProg('a LaTeX -> HTML converter', ['htlatex $$i', 'htlatex.sh $$i', \
'/usr/share/tex4ht/htlatex $$i', 'tth -t -e2 -L$$b < $$i > $$o', \ '/usr/share/tex4ht/htlatex $$i', 'tth -t -e2 -L$$b < $$i > $$o', \
@ -664,7 +659,7 @@ def checkConverterEntries():
addToRC(r'''\copier html "python -tt $$s/scripts/ext_copy.py -e html,png,css $$i $$o"''') addToRC(r'''\copier html "python -tt $$s/scripts/ext_copy.py -e html,png,css $$i $$o"''')
else: else:
addToRC(r'''\copier html "python -tt $$s/scripts/ext_copy.py $$i $$o"''') addToRC(r'''\copier html "python -tt $$s/scripts/ext_copy.py $$i $$o"''')
path, htmlconv = checkProg('a LaTeX -> MS Word converter', ["htlatex $$i 'html,word' 'symbol/!' '-cvalidate'", \ path, htmlconv = checkProg('a LaTeX -> HTML (MS Word) converter', ["htlatex $$i 'html,word' 'symbol/!' '-cvalidate'", \
"htlatex.sh $$i 'html,word' 'symbol/!' '-cvalidate'", \ "htlatex.sh $$i 'html,word' 'symbol/!' '-cvalidate'", \
"/usr/share/tex4ht/htlatex $$i 'html,word' 'symbol/!' '-cvalidate'"], "/usr/share/tex4ht/htlatex $$i 'html,word' 'symbol/!' '-cvalidate'"],
rc_entry = [ r'\converter latex wordhtml "%%" "needaux"' ]) rc_entry = [ r'\converter latex wordhtml "%%" "needaux"' ])
@ -680,7 +675,7 @@ def checkConverterEntries():
addToRC(r'\Format blog blog "LyXBlogger" "" "" "" "document"') addToRC(r'\Format blog blog "LyXBlogger" "" "" "" "document"')
addToRC(r'\converter xhtml blog "python -m lyxblogger $$i" ""') addToRC(r'\converter xhtml blog "python -m lyxblogger $$i" ""')
# #
checkProg('an OpenOffice.org -> LaTeX converter', ['w2l -clean $$i'], checkProg('an OpenOffice.org -> LaTeX converter', ['w2l -clean $$i'],
rc_entry = [ r'\converter sxw latex "%%" ""' ]) rc_entry = [ r'\converter sxw latex "%%" ""' ])
# #