#20343: Adding sage/misc/tikz_picture.py
-----------------------------------+------------------------
       Reporter:  slabbe           |        Owner:
           Type:  enhancement      |       Status:  new
       Priority:  major            |    Milestone:  sage-7.2
      Component:  misc             |   Resolution:
       Keywords:                   |    Merged in:
        Authors:  Sébastien Labbé  |    Reviewers:
Report Upstream:  N/A              |  Work issues:
         Branch:                   |       Commit:
   Dependencies:                   |     Stopgaps:
-----------------------------------+------------------------
Description changed by slabbe:

Old description:

> From my optional Sage package [1] slabbe-0.2.spkg.
>
> [1] https://github.com/seblabbe/slabbe

New description:

 Importing a file from my optional Sage package
 [https://github.com/seblabbe/slabbe slabbe-0.2.spkg] into Sage.

 {{{
 sage: from sage.misc.tikz_picture import TikzPicture
 sage: V =
 [[1,0,1],[1,0,0],[1,1,0],[0,0,-1],[0,1,0],[-1,0,0],[0,1,1],[0,0,1],[0,-1,0]]
 sage: P = Polyhedron(vertices=V).polar()
 sage: s = P.projection().tikz([674,108,-731],112)
 sage: t = TikzPicture(s)
 sage: t.pdf()
 }}}

 {{{
 sage: g = graphs.PetersenGraph()
 sage: s = latex(g)
 sage: t = TikzPicture(s, standalone_configs=["border=4mm"], packages
 =['tkz-graph'])
 sage: _ = t.pdf()
 }}}

 If dot2tex and graphviz available:

 {{{
 sage: t = TikzPicture.from_graph(g)  # optional: dot2tex
 }}}

--

--
Ticket URL: <http://trac.sagemath.org/ticket/20343#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 https://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to