--- latex_renderer/lib/latex_renderer_macro.rb 2006-11-06 05:41:02.536259814 +0100
+++ latex_renderer/lib/latex_renderer_macro.rb 2006-11-21 02:36:33.729396231 +0100
@@ -11,7 +11,7 @@
filename = latex.process
md5 = latex.md5hash
# if the processing was successful we just display the rendered image
- sprintf('
', #
',
+ sprintf('',
filename.gsub(/.*?\/images/, '/images'), formula, formula)
rescue => e
# if it failed for some reason, we'll display the original content
--- latex_renderer/lib/latex_renderer.rb 2006-11-07 01:29:59.982875022 +0100
+++ latex_renderer/lib/latex_renderer.rb 2006-11-20 22:27:45.975021427 +0100
@@ -157,8 +157,10 @@
file.write wrapped_formula
end
+ # Change directory to work around the missing --output-directory problem in earlier TeTeX versions
+ FileUtils.cd("#{@temp_dir}")
# temp dvi file
- from_latex_to_dpi = run_command("#{@@requisites[:latex]} --output-directory=#{@temp_dir} --interaction=nonstopmode #{@temp[:latex]}", "Conversion from Latex to DPI")
+ from_latex_to_dpi = run_command("#{@@requisites[:latex]} --interaction=nonstopmode #{@temp[:latex]}", "Conversion from Latex to DPI")
#convert dvi to ps using dvips
from_dpi_to_ps = run_command("#{@@requisites[:dvips]} -E #{@temp[:dvi]} -o #{@temp[:ps]}", "Conversion from DPI to PS")