- Notifications
You must be signed in to change notification settings - Fork22
Simplify logic for adding a single axes#88
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Yep cool. It's now explicit that we're delegating responsibility for the axis to each widget (which wasn't super clear tome on first pass).
From a styling PoV, are you thinking we'll tweakapply_napari_colorscheme
to be overrideable (like from a user-supplied stylesheet)?
# changing color of axes background to transparent | ||
self.canvas.figure.patch.set_facecolor("none") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
The figure's facecolor doesn't need to be set?
No, it doesn't but I don't get why.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
It's already set inNapariMPLWidget.__init__()
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
🤦 yep. Ty.
I'm expecting it will eventually become mostly redundant and replaced by a style sheet. |
figure()
property toNapariMPLWidget
, to replace the documented.figure
attribute that actually never existed.add_single_axes()
helper method toNapariMPLWidget
, that automatically adds a single axes and styles it.NapariMPLWidget
is not responsible for adding Axes to the figure.