Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
jupyter vs tikz picture
Browse files Browse the repository at this point in the history
  • Loading branch information
elixyre committed Nov 3, 2015
1 parent 2cc7f6c commit c51513c
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/sage/misc/latex.py
Original file line number Diff line number Diff line change
Expand Up @@ -2174,12 +2174,12 @@ def view(objects, title='Sage', debug=False, sep='', tiny=False,
print(MathJax().eval(objects, mode=mode, combine_all=combine_all))
else:
base_dir = os.path.abspath("")
from sage.misc.temporary_file import graphics_filename
png_file = graphics_filename()
png_link = "cell://" + png_file
from sage.misc.temporary_file import tmp_filename
png_file = tmp_filename(ext=".png")
png(objects, os.path.join(base_dir, png_file),
debug=debug, engine=engine)
print('<html><img src="{}"></html>'.format(png_link)) # put comma at end of line?
from IPython.core.display import Image
return Image(filename=png_file)
return
# command line or notebook with viewer
tmp = tmp_dir('sage_viewer')
Expand Down

0 comments on commit c51513c

Please sign in to comment.