ÓãCÂÛ̳

 ÕÒ»ØÃÜÂë
 Á¢¼´×¢²á
²é¿´: 12404|»Ø¸´: 10

[Tkinter] Tkinter ´°¿Ú×é¼þ£ºToplevel

[¸´ÖÆÁ´½Ó]
·¢±íÓÚ 2015-5-17 12:35:39 | ÏÔʾȫ²¿Â¥²ã |ÔĶÁģʽ
¹ºÂòÖ÷Ìâ ÒÑÓÐ 12 È˹ºÂò  ±¾Ö÷ÌâÐèÏò×÷ÕßÖ§¸¶ 10 Óã±Ò ²ÅÄÜä¯ÀÀ
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2016-11-24 09:02:16 | ÏÔʾȫ²¿Â¥²ã
лл¥ÔÚ·ÖÏí
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2017-2-11 23:00:56 | ÏÔʾȫ²¿Â¥²ã
лл£¬ÎÒ¸Õ¸Õ¿ªÊ¼Ñ§Ï°
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2017-8-8 14:35:23 | ÏÔʾȫ²¿Â¥²ã
ºóÃæµÄÔõô¶¼Ã»ÈËÆÀÂÛÁË,¿ÉÄܺܶàÈËû¼á³ÖÏÂÀ´°É
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
Í·Ïñ±»ÆÁ±Î
·¢±íÓÚ 2018-10-19 16:38:06 | ÏÔʾȫ²¿Â¥²ã
Ìáʾ: ×÷Õß±»½ûÖ¹»òɾ³ý ÄÚÈÝ×Ô¶¯ÆÁ±Î
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2018-12-26 16:54:55 | ÏÔʾȫ²¿Â¥²ã
·½·¨

deiconify()
Displays the window, after using either the iconify or the withdraw methods.
ÔÚʹÓÃiconify»òÕßwithdraw·½·¨ºó£¬ÏÔʾ´°¿Ú¡£

frame()
Returns a system-specific window identifier.
·µ»ØÒ»¸öÏµÍ³ÌØ¶¨µÄ´°¿Ú±êʶ·û

group(window)
Adds the window to the window group administered by the given window.
¸øÌض¨µÄ´°¿Ú·Ö×é

iconify()
Turns the window into an icon, without destroying it.
°Ñ´°¿Ú±ä³ÉÁËÒ»¸öͼ±ê£¬ÇÒ²»ÆÆ»µËü

protocol(name, function)
Registers a function as a callback which will be called for the given protocol.
¸øÌض¨µÄЭÒéÌí¼ÓÒ»¸ö»Øµ÷º¯Êý

state()
Returns the current state of the window. Possible values are normal, iconic, withdrawn, and icon.
·µ»Ø´°¿ÚµÄµ±Ç°×´Ì¬¡£¿ÉÄܵÄÖµÊÇÕý³£µÄ,±êÖ¾ÐÔ¡¢³·ÏúºÍͼ±ê¡£

transient([master])
Turns the window into a temporary(transient) window for the given master, or to the window's parent, when no argument is given.
°Ñ´°¿Ú×÷ΪÁÙʱ´°¿Ú¸ømaster£¬Èç¹ûûÓиø²ÎÊý£¬¾Í¸ø¸¸´°¿Ú

withdraw()
Removes the window from the screen, without destroying it.
´ÓÆÁÄ»ÉÏɾ³ý´°¿Ú£¬ÇÒ²»ÆÆ»µËü¡£

maxsize(width, height)
Defines the maximum size for this window.
¶¨ÒåÕâ¸ö´°¿ÚµÄ×î´ó³ß´ç¡£

minsize(width, height)
Defines the minimum size for this window.
¶¨ÒåÕâ¸ö´°¿ÚµÄ×îС³ß´ç¡£

positionfrom(who)
Defines the position controller.
¶¨ÒåλÖÿØÖÆÆ÷¡£

resizable(width, height)
Defines the resize flags, which control whether the window can be resized.
¶¨Òå´óС±êÖ¾£¬Ëü¿ØÖÆÊÇ·ñ¿ÉÒÔµ÷Õû´óСµÄ´°¿Ú¡£

sizefrom(who)
Defines the size controller.
¶¨Òå³ß´çµÄ¿ØÖÆÆ÷¡£

title(string)
Defines the window title.
¶¨Òå´°¿ÚÃû×Ö¡£

ÆÀ·Ö

²ÎÓëÈËÊý 1ÈÙÓþ +5 Óã±Ò +4 ¹±Ï× +3 ÊÕÆð ÀíÓÉ
Ì«Ñô·ç±© + 5 + 4 + 3

²é¿´È«²¿ÆÀ·Ö

С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2019-8-14 22:22:23 | ÏÔʾȫ²¿Â¥²ã

лл¥ÔÚ·ÖÏí
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2019-10-15 16:43:11 | ÏÔʾȫ²¿Â¥²ã
ȷʵÊǺö«Î÷°¡
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2020-4-24 15:04:22 | ÏÔʾȫ²¿Â¥²ã
Â¥Ö÷ÄãºÃ£¬ ¿É·ñÄÜÔÚToplevelÕâ¸ö´°¿ÚÖУ¬ Ìí¼ÓÎı¾¿ò£¬ ´Ó¶øÊäÈë²¢»ñÈ¡ÄØ£¬ Õâ¿éÓеã·Ñ½â
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2021-1-15 10:44:13 | ÏÔʾȫ²¿Â¥²ã
ÈçºÎÖ»ÄÜ´´½¨Ò»¸ö toplevel ´°¿Ú£¿
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
·¢±íÓÚ 2021-1-15 12:47:18 | ÏÔʾȫ²¿Â¥²ã
ÎÒÊÇÌÒ´¨ÈË ·¢±íÓÚ 2021-1-15 10:44
ÈçºÎÖ»ÄÜ´´½¨Ò»¸ö toplevel ´°¿Ú£¿

root = Tk()
top = Toplevel(master=root)
top.grab_set()  # master=root ºó¼ÓÉÏÕâ¸ö·½·¨Èøù½çÃæÎÞ·¨½øÐвÙ×÷
С¼×Óã×îÐÂ¿Î³Ì -> https://ilovefishc.com
ÄúÐèÒªµÇ¼ºó²Å¿ÉÒÔ»ØÌû µÇ¼ | Á¢¼´×¢²á

±¾°æ»ý·Ö¹æÔò

СºÚÎÝ|ÊÖ»ú°æ|Archiver|ÓãC¹¤×÷ÊÒ ( ÔÁICP±¸18085999ºÅ-1 | ÔÁ¹«Íø°²±¸ 44051102000585ºÅ)

GMT+8, 2025-12-21 12:53

Powered by Discuz! X3.4

© 2001-2023 Discuz! Team.

¿ìËٻظ´ ·µ»Ø¶¥²¿ ·µ»ØÁбí