Ben and Eric,
Thanks so much for your help!
I'm trying to turn change some of the rcParams in my script... Here is a test of what happens:
import matplotlib
matplotlib.rcParams['keymap.fullscreen']=''
Traceback (most recent call last):
File "<input>", line 1, in <module>
File "/usr/lib/pymodules/python2.6/matplotlib/__init__.py", line 623, in __setitem__
See rcParams.keys() for a list of valid parameters.'%key)
KeyError: 'keymap.fullscreen is not a valid rc parameter.See rcParams.keys() for a list of valid parameters.'
It seems that none of the keymap parameters are defined in my rcParams dictionary...
I also tried adding some of the "keymap" lines out of the online rc file:
http://matplotlib.sf.net/_static/matplotlibrc
to my rc file and it told me: Bad key "keymap.pan"
I've got version 0.99.0 on ubuntu.
Is this a new feature? Do you know what I can try instead??
Thanks!
-David
Hello!
My name is David Mashburn, and I have been a very happy user of
matplotlib for almost 5 years now, so let me start by saying thank you
for this wonderful piece of software! I has been a blessing to me!
I am creating a program that performs actions based on key commands in
matplotlib, and I keep bumping into conflicts with the interactive
keyboard navigation system. Is there any way to bypass or disable some
or all of the keybindings hooked to interactive navigation?
By the way, I'm using the WxAgg backend if that matters.
Thanks!
-David
David,
I have not tested this myself, but I believe that if you set
"navigate=False" as a keyword argument for making your axes, this will
stop the callbacks from being registered.
That completely disables the toolbar, which is likely not what the OP wants.
There are a bunch of rcParams, listed at the bottom of matplotlibrc_template (and of the default matplotlibrc file that is installed) that can be used to turn off the key bindings without disabling the toolbar.
Personally, I think that putting in all those key bindings by default was a major mistake, one that should be reversed ASAP. Having the plot jump to fullscreen when one bumps "f" is rude. The first time it happened I had no idea what was going on or how to recover from it--I thought maybe my X-server had gone bonkers. And does one actually save a displayed figure so often that it is useful to have the "s" shortcut to save one from having to click the toolbar button? I could go on with this complaint...
Eric
···
On 07/26/2010 10:18 AM, Benjamin Root wrote:
On Mon, Jul 26, 2010 at 3:09 PM, David Mashburn > <david.n.mashburn@...287... <mailto:david.n.mashburn@…287…> <mailto:david.n.mashburn@…287…>> wrote:
Thanks for using matplotlib!
Ben Root