#16570: Animate example looks broken
-------------------------------------+-------------------------------------
       Reporter:  gagern             |        Owner:
           Type:  defect             |       Status:  needs_info
       Priority:  minor              |    Milestone:  sage-6.4
      Component:  graphics           |   Resolution:
       Keywords:                     |    Merged in:
        Authors:  Martin von Gagern  |    Reviewers:  Jakob Kroeker
Report Upstream:  N/A                |  Work issues:
         Branch:                     |       Commit:
  u/gagern/ticket/16570              |  9d9e590f5ef642a06f45056ac282fe696131c435
   Dependencies:                     |     Stopgaps:
-------------------------------------+-------------------------------------

Comment (by gagern):

 Replying to [comment:32 jakobkroeker]:
 > but I guess, in `make_image()` `**kwds` should also be passed to
 `save_image()`?

 
[http://git.sagemath.org/sage.git/tree/src/sage/plot/graphics.py?id=d1eeb8f187ec15f7c032a35e3dc19654482da26d#n2946
 graphics.save] (which is what `save_image` delegates to) will combine
 arguments from three sources: `self.SHOW_OPTIONS` which contains default
 values, `self._extra_kwds` which obtains keywords from the `plot`
 function, and the `kwds` passed to `save` itself. Looking at
 
[http://git.sagemath.org/sage.git/tree/src/sage/plot/plot.py?id=d1eeb8f187ec15f7c032a35e3dc19654482da26d#n1236
 plot] we see that all show-relevant keywords (as determined by
 `Graphics._extract_kwds_for_show`) will get passed to `_set_extra_kwds`
 ''except'' `xmin` and `xmax` which are explicitely ignored.

 So what's the conclusion here? As long as a keyword argument is deemed
 suitable for `show`, i.e. matches a key in `Graphics.SHOW_OPTIONS`, then
 passing it as an agument to `plot` is enough, and we gain nothing by
 repeating those arguments for `save`. Are there any arguments which make
 sense for `save` but do not fall in that category? Since
 
[http://git.sagemath.org/sage.git/tree/src/sage/plot/graphics.py?id=d1eeb8f187ec15f7c032a35e3dc19654482da26d#n3387
 show] is little more than a call to `save` followed by launching the
 viewer, this should in my opinion not be the case. I'd say there is no
 need to repeat the arguments, and if any arguments would be needed for
 `show`, then that would be a bug in its own right.

--
Ticket URL: <http://trac.sagemath.org/ticket/16570#comment:33>
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.

Reply via email to