diff --git a/pyproject.toml b/pyproject.toml index f1ee514f..6b2d6181 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -29,7 +29,7 @@ keywords = ["latex", "tikz", "matplotlib", "graphics"] dynamic = ["version"] requires-python = ">=3.7" dependencies = [ - "matplotlib >= 1.4.0", + "matplotlib >= 3.6.0", "numpy", "Pillow", "webcolors", diff --git a/src/tikzplotlib/_legend.py b/src/tikzplotlib/_legend.py index 29d8e635..bfe8683a 100644 --- a/src/tikzplotlib/_legend.py +++ b/src/tikzplotlib/_legend.py @@ -78,8 +78,8 @@ def draw_legend(data, obj): if alignment: data["current axes"].axis_options.append(f"legend cell align={{{alignment}}}") - if obj._ncol != 1: - data["current axes"].axis_options.append(f"legend columns={obj._ncol}") + if obj._ncols != 1: + data["current axes"].axis_options.append(f"legend columns={obj._ncols}") # Write styles to data if legend_style: