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

Commit

Permalink
fixing a few imports
Browse files Browse the repository at this point in the history
  • Loading branch information
Frédéric Chapoton committed Jun 7, 2018
1 parent 6aad51b commit a0be77f
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 5 deletions.
4 changes: 3 additions & 1 deletion src/sage/combinat/words/finite_word.py
Expand Up @@ -6899,7 +6899,9 @@ def colored_vector(self, x=0, y=0, width='default', height=1, cmap='hsv', thickn
raise RuntimeError("Color map %s not known"%cmap)

#Drawing the colored vector...
from sage.plot.plot import polygon,line,text
from sage.plot.line import line
from sage.plot.polygon import polygon
from sage.plot.text import text

#The default width of the vector
if width == 'default':
Expand Down
2 changes: 1 addition & 1 deletion src/sage/matrix/matrix2.pyx
Expand Up @@ -13221,7 +13221,7 @@ cdef class Matrix(Matrix1):
sage: A.plot(cmap='Oranges')
Graphics object consisting of 1 graphics primitive
"""
from sage.plot.plot import matrix_plot
from sage.plot.matrix_plot import matrix_plot
return matrix_plot(self, *args, **kwds)

def derivative(self, *args):
Expand Down
7 changes: 6 additions & 1 deletion src/sage/plot/plot.py
Expand Up @@ -579,6 +579,12 @@ def f(x): return (x-3)*(x-5)*(x-7)+40
from sage.misc.decorators import options

from .graphics import Graphics, GraphicsArray
from sage.plot.polygon import polygon

# line below is only for redirection of imports
from sage.plot.line import line, line2d



#Currently not used - see comment immediately above about
#figure.canvas.mpl_connect('draw_event', pad_for_tick_labels)
Expand Down Expand Up @@ -2064,7 +2070,6 @@ def _plot(funcs, xrange, parametric=False,
"""
from sage.plot.colors import Color
from sage.plot.polygon import polygon
from sage.plot.misc import setup_for_eval_on_grid
if funcs == []:
return Graphics()
Expand Down
5 changes: 3 additions & 2 deletions src/sage/plot/step.py
Expand Up @@ -17,6 +17,8 @@
#
# http://www.gnu.org/licenses/
#*****************************************************************************
from sage.plot.line import line


def plot_step_function(v, vertical_lines=True, **kwds):
r"""
Expand Down Expand Up @@ -51,9 +53,8 @@ def plot_step_function(v, vertical_lines=True, **kwds):
sage: plot_step_function(v, vertical_lines=False, thickness=30, rgbcolor='purple', axes=False)
Graphics object consisting of 14 graphics primitives
"""
from .plot import line
# make sorted copy of v (don't change in place, since that would be rude).
v = list(sorted(v))
v = sorted(v)
if len(v) <= 1:
return line([]) # empty line
if vertical_lines:
Expand Down

0 comments on commit a0be77f

Please sign in to comment.