簡體   English   中英

Tkinter 如何在 Microsoft Windows 上工作?

[英]How does Tkinter work on Microsoft Windows?

I was reading the up on Tkinter for certain operations that the windows manager handles and I got to wondering how exactly does Tkinter communicate with the OS's window manager? 根據文檔,它使用 Xlib 來繪制圖形,但這在 Microsoft Windows 上如何工作? Xlib 不是類似 Unix 的圖形庫,即 X11 嗎? Tkinter 究竟如何與 Windows 圖形通信? Python 的 Windows 版本是否可以訪問 WinAPI 並且不使用 Xlib?

Tk (the library upon which tkinter is base) uses the windows API on windows, and cocoa libraries on OSX. 這兩個平台不使用 xlib,但如果您願意,可以在這些平台上編譯基於 X11 的版本。

關於 tcl/tk 的 windows 端口的大量信息可在 Tcl wiki 上找到: https://wiki.tcl-lang.org/page/Microsoft+Windows+and+Tcl

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM