Skip to content

added axes::cla #29

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
Feb 28, 2023
Merged
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
13 changes: 13 additions & 0 deletions include/matplotlibcpp17/axes.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,10 @@ struct DECL_STRUCT_ATTR Axes : public BaseWrapper {
container::BarContainer barh(const pybind11::tuple &args = pybind11::tuple(),
const pybind11::dict &kwargs = pybind11::dict());

// cla
ObjectWrapper cla(const pybind11::tuple &args = pybind11::tuple(),
const pybind11::dict &kwargs = pybind11::dict());

// contour
ObjectWrapper contour(const pybind11::tuple &args = pybind11::tuple(),
const pybind11::dict &kwargs = pybind11::dict());
Expand Down Expand Up @@ -259,6 +263,7 @@ struct DECL_STRUCT_ATTR Axes : public BaseWrapper {
WARN_MSG("Not loading bar_label because matplotlib version is < 3.4.0");
#endif
LOAD_FUNC_ATTR(barh, self);
LOAD_FUNC_ATTR(cla, self);
LOAD_FUNC_ATTR(contour, self);
LOAD_FUNC_ATTR(contourf, self);
LOAD_FUNC_ATTR(errorbar, self);
Expand Down Expand Up @@ -304,6 +309,7 @@ struct DECL_STRUCT_ATTR Axes : public BaseWrapper {
pybind11::object bar_attr;
pybind11::object bar_label_attr;
pybind11::object barh_attr;
pybind11::object cla_attr;
pybind11::object contour_attr;
pybind11::object contourf_attr;
pybind11::object errorbar_attr;
Expand Down Expand Up @@ -404,6 +410,13 @@ container::BarContainer Axes::barh(const pybind11::tuple &args,
return container::BarContainer(obj);
}

// cla
ObjectWrapper Axes::cla(const pybind11::tuple &args,
const pybind11::dict &kwargs) {
pybind11::object ret = cla_attr(*args, **kwargs);
return ObjectWrapper(std::move(ret));
}

// contour
ObjectWrapper Axes::contour(const pybind11::tuple &args,
const pybind11::dict &kwargs) {
Expand Down