Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Massive MEP move #4293

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 23 commits into from
Mar 30, 2015
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
DOC : fix markup in MEP26 and MEP27
  • Loading branch information
tacaswell committed Mar 30, 2015
commit dac829312a4dc94a1ac63a3773e6e5be7f647fd2
6 changes: 3 additions & 3 deletions 6 doc/devel/MEP/MEP26.rst
Original file line number Diff line number Diff line change
Expand Up @@ -116,14 +116,14 @@ syntax ::

selector {attribute: value;}

Each rule can have any number of `attribute`:`value` pairs, and a
Each rule can have any number of `attribute`: `value` pairs, and a
stylesheet can have any number of rules.

The initial syntax is designed only for `artist` primitives. It does
not address the question of how to set properties on `container` types
(whose properties may themselves be `artists` with settable
properties), however, a future solution to this could simply be nested
`RuleSet`s
`RuleSet` s

Selectors
~~~~~~~~~
Expand Down Expand Up @@ -221,7 +221,7 @@ Appendix
========

Matplotlib primitives
~~~~~~~~~~~~~~~~~~~~~
---------------------

This will form the initial selectors which stylesheets can use.

Expand Down
42 changes: 20 additions & 22 deletions 42 doc/devel/MEP/MEP27.rst
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ Two main places for generic code appear in the classes derived from
``FigureManagerBase`` and ``ShowBase``.

1. ``FigureManagerBase`` has **three** jobs at the moment:

1. The documentation describes it as a *``Helper class for pyplot
mode, wraps everything up into a neat bundle''*
2. But it doesn't just wrap the canvas and toolbar, it also does
Expand All @@ -63,6 +64,7 @@ Two main places for generic code appear in the classes derived from


2. ``ShowBase`` has two jobs:

1. It has the job of going through all figure managers registered
in ``_pylab_helpers.Gcf`` and telling them to show themselves.
2. And secondly it has the job of performing the backend specific
Expand All @@ -89,46 +91,42 @@ The description of this MEP gives us most of the solution:
3. Now that ``FigureManagerBase`` has no backend specifics in it, to
rename it to ``FigureManager``, and move to a new file
``backend_managers.py`` noting that:
1. This allows us to break up the conversion of backends into
separate PRs as we can keep the existing ``FigureManagerBase``
class and its dependencies intact.
2. and this also anticipates MEP22 where the new
``NavigationBase`` has morphed into a backend independent
``ToolManager``.

1. This allows us to break up the conversion of backends into
separate PRs as we can keep the existing ``FigureManagerBase``
class and its dependencies intact.
2. and this also anticipates MEP22 where the new
``NavigationBase`` has morphed into a backend independent
``ToolManager``.

+--------------------------------------+------------------------------+---------------------+--------------------------------+
|FigureManagerBase(canvas, num) |FigureManager(figure, num) |``WindowBase(title)``|Notes |
| | | | |
+======================================+==============================+=====================+================================+
|show |:arrow_right: |show | |
|show | |show | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|destroy |calls destroy on all |destroy | |
| |components | | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|full_screen_toggle |handles logic |set_fullscreen | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|resize |:arrow_right: |resize | |
|resize | |resize | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|key_press |key_press |:no_entry: | |
|key_press |key_press | | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|show_popup |show_poup |:no_entry: |Not used anywhere in mpl, and |
|show_popup |show_poup | |Not used anywhere in mpl, and |
| | | |does nothing. |
| | | | |
| | | | |
| | | | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|get_window_title |:arrow_right: |get_window_title | |
|get_window_title | |get_window_title | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|set_window_title |:arrow_right: |set_window_title | |
|set_window_title | |set_window_title | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|:no_entry: |_get_toolbar | |A common method to all |
| |_get_toolbar | |A common method to all |
| | | |subclasses of FigureManagerBase |
| | | | |
| | | | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|:no_entry: |:no_entry: |set_default_size | |
| | |set_default_size | |
+--------------------------------------+------------------------------+---------------------+--------------------------------+
|:no_entry: |:no_entry: |add_element_to_window| |
| | |add_element_to_window| |
+--------------------------------------+------------------------------+---------------------+--------------------------------+


Expand All @@ -137,14 +135,14 @@ The description of this MEP gives us most of the solution:
+==========+============+=============+
|mainloop |begin | |
+----------+------------+-------------+
|:no_entry:|end |Gets called |
| |end |Gets called |
| | |automagically|
| | |when no more |
| | |instances of |
| | |the subclass |
| | |exist |
+----------+------------+-------------+
|__call__ |:no_entry: |Method moved |
|__call__ | |Method moved |
| | |to |
| | |Gcf.show_all |
+----------+------------+-------------+
Expand Down
Morty Proxy This is a proxified and sanitized view of the page, visit original site.