Ensure that a "backend" entry exists. Normally, the default matplotlibrc file contains *no* entry for "backend" (the corresponding line starts with ##, not #; we fill in _auto_backend_sentinel in that case. However, packagers can set a different default backend
(self)
| 756 | dict.update(self, other_params) |
| 757 | |
| 758 | def _ensure_has_backend(self): |
| 759 | """ |
| 760 | Ensure that a "backend" entry exists. |
| 761 | |
| 762 | Normally, the default matplotlibrc file contains *no* entry for "backend" (the |
| 763 | corresponding line starts with ##, not #; we fill in _auto_backend_sentinel |
| 764 | in that case. However, packagers can set a different default backend |
| 765 | (resulting in a normal `#backend: foo` line) in which case we should *not* |
| 766 | fill in _auto_backend_sentinel. |
| 767 | """ |
| 768 | dict.setdefault(self, "backend", rcsetup._auto_backend_sentinel) |
| 769 | |
| 770 | def __setitem__(self, key, val): |
| 771 | if (key == "backend" |