8000 Make plt.style.use accept path-like objects in addition to string · Issue #15138 · matplotlib/matplotlib · GitHub
[go: up one dir, main page]

Skip to content
Make plt.style.use accept path-like objects in addition to string #15138
Closed
@ivarstange

Description

@ivarstange

plt.style.use(style) accepts a str, dict, or list. The str can be either the name of a style or a path/URL to a style file. I propose that this also accept a pathlike object (pathlib.Path) so that it is unneccesary to cast it like plt.style.use(str(my_path)), but accept it like this plt.style.use(my_path).

There may be other places in the code that accepts file paths as strings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    API: consistencyDifficulty: Easyhttps://matplotlib.org/devdocs/devel/contribute.html#good-first-issuesGood first issueOpen a pull request against these issues if there are no active ones!

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0