sympy/sympy — pull request #7401 by thisch (2014-04-13 14:48:20+00:00)
Title: fixes pyglet doctest problems

fixes TypeError and KeyError exceptions in the pygletplot package

```py
Traceback (most recent call last):
File "/usr/lib64/python2.7/doctest.py", line 1289, in __run
compileflags, 1) in test.globs
File "", line 1, in
p[2] = -x**2-y**2
File "sympy/plotting/pygletplot/plot.py", line 320, in __setitem__
f = PlotMode(*args, **kwargs)
File "sympy/plotting/pygletplot/plot_mode_base.py", line 164, in __init__
self.style = self.options.pop('style', '')
File "sympy/plotting/pygletplot/plot_mode_base.py", line 174, in w
r = f(self, *args, **kwargs)
File "sympy/plotting/pygletplot/plot_mode_base.py", line 327, in _set_style
v = ['both', 'solid'][step_max > 40]
TypeError: list indices must be integers, not BooleanFalse

Traceback (most recent call last):
File "/usr/lib64/python2.7/doctest.py", line 1289, in __run
compileflags, 1) in test.globs
File "", line 1, in
p[2].style = 'wireframe'
File "sympy/plotting/pygletplot/plot.py", line 301, in __getitem__
return self._functions[i]
KeyError: 2
```