Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Make variables private in Tk-backend#26741

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

Draft
oscargus wants to merge1 commit intomatplotlib:main
base:main
Choose a base branch
Loading
fromoscargus:tkrename
Draft
Changes fromall 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
12 changes: 6 additions & 6 deletionslib/matplotlib/backends/_backend_tk.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -26,7 +26,7 @@


_log = logging.getLogger(__name__)
cursord = {
_CURSOR_DICT = {
cursors.MOVE: "fleur",
cursors.HAND: "hand2",
cursors.POINTER: "arrow",
Expand All@@ -51,8 +51,8 @@ def _restore_foreground_window_at_end():
# Initialize to a non-empty string that is not a Tcl command
_blit_tcl_name = "mpl_blit_" + uuid.uuid4().hex

TK_PHOTO_COMPOSITE_OVERLAY = 0 # apply transparency rules pixel-wise
TK_PHOTO_COMPOSITE_SET = 1 # set image buffer directly
_TK_PHOTO_COMPOSITE_OVERLAY = 0 # apply transparency rules pixel-wise
_TK_PHOTO_COMPOSITE_SET = 1 # set image buffer directly


def _blit(argsid):
Expand DownExpand Up@@ -97,10 +97,10 @@ def blit(photoimage, aggimage, offsets, bbox=None):
if (x1 > x2) or (y1 > y2):
return
bboxptr = (x1, x2, y1, y2)
comp_rule =TK_PHOTO_COMPOSITE_OVERLAY
comp_rule =_TK_PHOTO_COMPOSITE_OVERLAY
else:
bboxptr = (0, width, 0, height)
comp_rule =TK_PHOTO_COMPOSITE_SET
comp_rule =_TK_PHOTO_COMPOSITE_SET

# NOTE: _tkagg.blit is thread unsafe and will crash the process if called
# from a thread (GH#13293). Instead of blanking and blitting here,
Expand DownExpand Up@@ -434,7 +434,7 @@ def stop_event_loop(self):

def set_cursor(self, cursor):
try:
self._tkcanvas.configure(cursor=cursord[cursor])
self._tkcanvas.configure(cursor=_CURSOR_DICT[cursor])
except tkinter.TclError:
pass

Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp