Skip to content

Remove deprecated rcParams entries and functions. #8721

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 1 commit into from
Jun 6, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
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
7 changes: 7 additions & 0 deletions doc/api/api_changes/code_removal.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,15 @@ favor of the synonym ``"auto"``.
The ``shading`` kwarg to ``pcolor`` has been removed. Set ``edgecolors``
appropriately instead.


Removed internal functions
--------------------------

The ``matplotlib.backends.backend_ps.seq_allequal`` function has been removed.
Use ``np.array_equal`` instead.

The deprecated ``matplotlib.rcsetup.validate_maskedarray``,
``matplotlib.rcsetup.deprecate_savefig_extension`` and
``matplotlib.rcsetup.validate_tkpythoninspect`` functions, and associated
``savefig.extension`` and ``tk.pythoninspect`` rcparams entries have been
removed.
6 changes: 2 additions & 4 deletions lib/matplotlib/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -823,16 +823,14 @@ def gen_candidates():
'tick.size': ('tick.major.size', lambda x: x, None),
'svg.embed_char_paths': ('svg.fonttype',
lambda x: "path" if x else "none", None),
'savefig.extension': ('savefig.format', lambda x: x, None),
'axes.color_cycle': ('axes.prop_cycle', lambda x: cycler('color', x),
lambda x: [c.get('color', None) for c in x]),
'svg.image_noscale': ('image.interpolation', None, None),
}

_deprecated_ignore_map = {
}
_deprecated_ignore_map = {}

_obsolete_set = {'tk.pythoninspect', 'legend.isaxes'}
_obsolete_set = {'legend.isaxes'}

# The following may use a value of None to suppress the warning.
_deprecated_set = {'axes.hold'} # do NOT include in _all_deprecated
Expand Down
28 changes: 0 additions & 28 deletions lib/matplotlib/rcsetup.py
Original file line number Diff line number Diff line change
Expand Up @@ -279,18 +279,6 @@ def validate_toolbar(s):
return validator(s)


def validate_maskedarray(v):
# 2008/12/12: start warning; later, remove all traces of maskedarray
try:
if v == 'obsolete':
return v
except ValueError:
pass
warnings.warn('rcParams key "maskedarray" is obsolete and has no effect;\n'
' please delete it from your matplotlibrc file',
mplDeprecation)


_seq_err_msg = ('You must supply exactly {n} values, you provided {num} '
'values: {s}')

Expand Down Expand Up @@ -492,13 +480,6 @@ def validate_whiskers(s):
"(float, float)]")


def deprecate_savefig_extension(value):
warnings.warn("savefig.extension is deprecated. Use savefig.format "
"instead. Will be removed in 1.4.x",
mplDeprecation)
return value


def update_savefig_format(value):
# The old savefig.extension could also have a value of "auto", but
# the new savefig.format does not. We need to fix this here.
Expand Down Expand Up @@ -576,12 +557,6 @@ def validate_corner_mask(s):
return validate_bool(s)


def validate_tkpythoninspect(s):
# Introduced 2010/07/05
warnings.warn("tk.pythoninspect is obsolete, and has no effect",
mplDeprecation)
return validate_bool(s)

validate_legend_loc = ValidateInStrings(
'legend_loc',
['best',
Expand Down Expand Up @@ -1330,8 +1305,6 @@ def _validate_linestyle(ls):
'savefig.orientation': ['portrait', validate_orientation], # edgecolor;
#white
'savefig.jpeg_quality': [95, validate_int],
# what to add to extensionless filenames
'savefig.extension': ['png', deprecate_savefig_extension],
# value checked by backend at runtime
'savefig.format': ['png', update_savefig_format],
# options are 'tight', or 'standard'. 'standard' validates to None.
Expand All @@ -1343,7 +1316,6 @@ def _validate_linestyle(ls):

# Maintain shell focus for TkAgg
'tk.window_focus': [False, validate_bool],
'tk.pythoninspect': [False, validate_tkpythoninspect], # obsolete

# Set the papersize/type
'ps.papersize': ['letter', validate_ps_papersize],
Expand Down