Thanks to visit codestin.com
Credit goes to github.com

Skip to content

gtk: Fix draw on unmapped windows. #17981

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
Jul 22, 2020

Conversation

QuLogic
Copy link
Member

@QuLogic QuLogic commented Jul 20, 2020

PR Summary

Most other backends do not skip drawing on unmapped windows; this skip causes explicit draws to do nothing and breaks things that expect it to work.

For example, the TextBox example broke since the widget was changed to set text before showing the window (#17117). This required drawing to work in order to measure text size and place the caret.

PR Checklist

  • Has Pytest style unit tests
  • Code is Flake 8 compliant
  • [N/A] New features are documented, with examples if plot related
  • [N/A] Documentation is sphinx and numpydoc compliant
  • [N/A] Added an entry to doc/users/next_whats_new/ if major new feature (follow instructions in README.rst there)
  • Documented in doc/api/next_api_changes/* if API changed in a backward-incompatible way
    Maybe?

Most other backends do not skip drawing on unmapped windows; this skip
causes explicit draws to do nothing and breaks things that expect it to
work.

For example, the `TextBox` example broke since the widget was changed to
set text before showing the window. This required drawing to work in
order to measure text size and place the caret.
@QuLogic QuLogic added this to the v3.3.1 milestone Jul 20, 2020
@tacaswell tacaswell merged commit 03aebfb into matplotlib:master Jul 22, 2020
meeseeksmachine pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Jul 22, 2020
@tacaswell
Copy link
Member

Merged on a single review and trusting that @QuLogic tested this locally.

@QuLogic QuLogic deleted the gtk3-unmapped-draw branch July 22, 2020 21:19
timhoffm added a commit that referenced this pull request Jul 22, 2020
…981-on-v3.3.x

Backport PR #17981 on branch v3.3.x (gtk: Fix `draw` on unmapped windows.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants