#17284: Fix command-line plotting keywords
----------------------------+------------------------
Reporter: jdemeyer | Owner:
Type: defect | Status: new
Priority: blocker | Milestone: sage-6.4
Component: graphics | Resolution:
Keywords: | Merged in:
Authors: | Reviewers:
Report Upstream: N/A | Work issues:
Branch: | Commit:
Dependencies: | Stopgaps:
----------------------------+------------------------
Description changed by jdemeyer:
Old description:
> This should open a Tachyon-rendered plot (and this worked until very
> recently):
> {{{
> sage: cube(viewer="tachyon")
> }}}
>
> The following still works:
> {{{
> sage: cube(viewer="tachyon").show()
> }}}
New description:
This should open a Tachyon-rendered plot (and this worked until very
recently):
{{{
sage: cube(viewer="tachyon")
}}}
The following patch fixes the problem (but probably not in the correct
way):
{{{
#!diff
diff --git a/src/sage/repl/display/formatter.py
b/src/sage/repl/display/formatter.py
index 670d208..a352a54 100644
--- a/src/sage/repl/display/formatter.py
+++ b/src/sage/repl/display/formatter.py
@@ -377,8 +377,6 @@ class
SageConsoleTextFormatter(SagePlainTextFormatter):
"""
from sage.structure.sage_object import SageObject
if isinstance(obj, SageObject) and hasattr(obj, '_graphics_'):
- gfx = obj._graphics_()
- if gfx:
- gfx.launch_viewer()
- return ''
+ obj.show()
+ return ''
return super(SageConsoleTextFormatter, self).__call__(obj)
}}}
--
--
Ticket URL: <http://trac.sagemath.org/ticket/17284#comment:1>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.