Skip to content

[ENH] Interactive Zoom Rectangle Color Review for MACOSX backend #23777

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

Closed
manu-b-s opened this issue Aug 30, 2022 · 5 comments · Fixed by #24367
Closed

[ENH] Interactive Zoom Rectangle Color Review for MACOSX backend #23777

manu-b-s opened this issue Aug 30, 2022 · 5 comments · Fixed by #24367
Labels
Difficulty: Medium https://matplotlib.org/devdocs/devel/contribute.html#good-first-issues Good first issue Open a pull request against these issues if there are no active ones! GUI: MacOSX
Milestone

Comments

@manu-b-s
Copy link

Interactive zoom rectangle is not visible on dark backgrounds for MACOSX backend.

Seems like this has been fixed when using QT backend (issue #16798), but can't find any solution / workaround for MACOSX backend.

Light Background

Dark Background

@manu-b-s manu-b-s changed the title Interactive Zoom Rectangle Color Review for MACOSX backend [ENH] Interactive Zoom Rectangle Color Review for MACOSX backend Aug 30, 2022
@tacaswell tacaswell added this to the v3.7.0 milestone Aug 30, 2022
@tacaswell tacaswell added GUI: MacOSX Good first issue Open a pull request against these issues if there are no active ones! Difficulty: Medium https://matplotlib.org/devdocs/devel/contribute.html#good-first-issues labels Aug 30, 2022
@tacaswell
Copy link
Member

This is a good first issue because there is no API design and does not require any understanding of Matplotlib internals.

Labeling this as medium difficulty because the implementation is likely to touch the objective C code and may require familiarity with both Python and objective C. This may require research into the underlying toolkit's API.

@QuLogic
Copy link
Member

QuLogic commented Aug 30, 2022

In the Qt backend, we draw the rectangle twice, once in black, once in white with an offset. The same can be done in the macos backend.

@oscargus
Copy link
Member

Just to clarify, that offset is in the "dash-space"? (I first read it as x and y offset.) I guess one can possibly even use the new striped line functionality for this?

@anntzer
Copy link
Contributor

anntzer commented Aug 31, 2022

In all likelihood it will be much faster to do this with calls to native (dashed) path-drawing functions.

@QuLogic
Copy link
Member

QuLogic commented Aug 31, 2022

Yes, in dash space. Both Qt and GTK draw them with native calls.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Difficulty: Medium https://matplotlib.org/devdocs/devel/contribute.html#good-first-issues Good first issue Open a pull request against these issues if there are no active ones! GUI: MacOSX
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants