Skip to content

Commit

Permalink
Merge pull request #5017 from OceanWolf/MEP22-warnings
Browse files Browse the repository at this point in the history
DOC: MEP22 warnings
  • Loading branch information
tacaswell committed Sep 3, 2015
2 parents b7ef642 + f5e43c1 commit 7c1993d
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 3 deletions.
4 changes: 3 additions & 1 deletion doc/users/whats_new/rcparams.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ default), ``'left'``, ``'right'``, ``'bottom'``, ``'top'`` and ``'none'``.
Added "toolmanager" to "toolbar" possible values
````````````````````````````````````````````````

The new value enables the use of ``ToolManager``
The new value enables the use of ``ToolManager``. Note at the moment we
release this for feedback and should get treated as experimental until further
notice.


Added ``axes.labelpad``
Expand Down
6 changes: 4 additions & 2 deletions doc/users/whats_new/toolmanager.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,10 @@ The `Toolbars` are replaced for `ToolContainers` that are just GUI interfaces to


.. note::
For the moment the `ToolManager` is working only with `GTK3` and `Tk` backends.
Make sure you are using one of those.
At the moment we release this primarily for feedback purposes and should
get treated as experimental until further notice as API changes will occur.
For the moment the `ToolManager` works only with the `GTK3` and `Tk` backends.
Make sure you use one of those.
Port for the rest of the backends is comming soon.

To activate the `ToolManager` include the following at the top of your file:
Expand Down
3 changes: 3 additions & 0 deletions lib/matplotlib/backend_managers.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,9 @@ class ToolManager(object):
"""

def __init__(self, canvas):
warnings.warn('Treat the new Tool classes introduced in v1.5 as ' +
'experimental for now, the API will likely change in ' +
'version 2.1 and perhaps the rcParam as well')
self.canvas = canvas

self._key_press_handler_id = self.canvas.mpl_connect(
Expand Down
3 changes: 3 additions & 0 deletions lib/matplotlib/backend_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,9 @@ class ToolBase(object):
"""

def __init__(self, toolmanager, name):
warnings.warn('Treat the new Tool classes introduced in v1.5 as ' +
'experimental for now, the API will likely change in ' +
'version 2.1, and some tools might change name')
self._name = name
self._figure = None
self.toolmanager = toolmanager
Expand Down

0 comments on commit 7c1993d

Please sign in to comment.