Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

ÓÃpython½øÐÐGUI¿ª·¢µÄÑ¡Ôñ

Python×î´óµÄÌصã¾ÍÔÚÓÚËýµÄ¿ìËÙ¿ª·¢¹¦ÄÜ¡£×÷ΪһÖÖ½ºË®ÐÍÓïÑÔ£¬python¼¸ºõ¿ÉÒÔÉø͸ÔÚÎÒÃDZà³Ì¹ý³ÌÖеĸ÷¸öÁìÓò¡£ÕâÀïÎÒ¼òµ¥½éÉÜÒ»ÏÂÓÃpython½øÐÐgui¿ª·¢µÄһЩѡÔñ¡£
 1.Tkinter
 TkinterËƺõÊÇÓëtclÓïÑÔͬʱ·¢Õ¹ÆðÀ´µÄÒ»ÖÖ½çÃæ¿â¡£tkinterÊÇpythonµÄÅ䱸µÄ±ê×¼gui¿â£¬Ò²ÊÇopensourceµÄ²úÎï¡£Tkinter¿ÉÓÃÓÚwindows/linux/unix/macintosh²Ù×÷ϵͳ£¬¶øÇÒÏÔʾ·ç¸ñÊDZ¾µØ»¯µÄ¡£TkinterÓÃÆðÀ´·Ç³£¼òµ¥£¬python×Ô´øµÄIDLE¾ÍÊDzÉÓÃËüдµÄ¡£³ý´ËÍ⣬tkinterµÄÀ©Õ¹¼¯pmwºÍTix¹¦ÄÜÉ϶¼ÒªÏà¶ÔËüÇ¿´ó£¬µ«tkinterÈ´ÊÇ×î»ù±¾µÄ¡£ÎÒÈÏΪ£¬ÔÚÓÃpython×ögui¿ª·¢£¬tkinterÊÇ×î»ù±¾µÄ֪ʶ£¬ËùÒÔÕâ¸ö»·½ÚÊDZØÐëҪѧϰµÄ¡£Äã»òÐíÔÚÒÔºóµÄ¿ª·¢Öв¢²»³£ÓÃtkinter£¬µ«ÊÇһЩСÐ͵ÄÓ¦ÓÃÉÏÃ棬Ëû»¹ÊǺÜÓÐÓõģ¬¶øÇÒ¿ª·¢ËÙ¶ÈÒ²ºÜ¿ì¡£
 2.WxPython
 WxWidgetsÓ¦¸ÃËãÊǽü¼¸ÄêÁ˱ȽÏÁ÷ÐеÄGUI¿çƽ̨¿ª·¢¼¼ÊõÁË¡£wxWidgetsÓв»Í¬µÄ°æ±¾Ó¦Óã¬ÓÐc++µÄ£¬Ò²ÓÐbasicµÄ£¬ÏÖÔÚÔÚpythonÉÏÃæÒ²ÓнϺõÄÒÆÖ²¡£wxpythonµÄ¹¦ÄÜÉÏÃæҪǿÓÚtkinter,ËýÌṩÁ˳¬¹ý200¸öÀ࣬ÃæÏò¶ÔÏóµÄ±à³Ì·ç¸ñ£¬Éè¼ÆµÄ¿ò¼ÜÀàËÆÓÚMFC¡£¶ÔÓÚ´óÐÍGUIÓ¦ÓÃÉÏÃ棬wxPython»¹ÊǾßÓкÜÇ¿µÄÓÅÊƵġ£boa constructor¿ÉÒÔ°ïÖúÎÒÃÇ¿ìËÙ¿ÉÊӵع¹½¨wxwidgets½çÃæ¡£
 3.PyQT
 QtͬÑùÊÇÒ»ÖÖ¿ªÔ´µÄGUI¿â£¬QtµÄÀà¿â´óÔ¼ÔÚ300¶à¸ö£¬º¯Êý´óÔ¼ÔÚ5700¶à¸ö¡£QtͬÑùÊʺÏÓÚ´óÐÍÓ¦Óã¬ÓÉËü×Ô´øµÄqt designer¿ÉÒÔÈÃÎÒÃÇÇáËÉÀ´¹¹½¨½çÃæÔªËØ¡£
 4.pyGtk
 GtkÊÇlinuxÏÂGnomeµÄºËÐÄ¿ª·¢¿âÁË¡£¹¦ÄÜÉÏÃæ·Ç³£ÆëÈ«¡£ÖµµÃ˵Ã÷µÄÊÇ£¬ÔÚwindowsƽ̨ÏÂgtkµÄÏÔʾ·ç¸ñ²¢²»ÊÇÌر𱾵ػ¯¡£²»¹ýËû´øµÄgladeµÄ½çÃæÉè¼ÆÆ÷»¹ÊÇ¿ÉÒÔ°ïÄãÊ¡²»ÉÙʵġ£
 5.Jython
 ³¢ÊÔ¹ýÓÃpython·ÃÎÊjavaÀà¿âÂð£¬ÄÇô¾ÍÓÃjython°É¡£jythonÆäʵ¿ÉÒÔÈÏΪÊÇÁíÍâÒ»¸öpython¿ª·¢»·¾³£¬»ùÓÚjavaµÄ£¬µ«ÊÇ´ó¶àÊýµÄCPythonµ÷ÓÃjythonÏ»¹ÊÇ¿ÉÒԵġ£Äã¿ÉÒÔÔÚjython»·¾³ÏÂÏñʹÓÃjavaÒ»ÑùÀ´Í¨¹ýpythonµÄÓï·¨À´µ÷ÓÃjavaÓïÑÔ£¬ÕæµÄºÜ¿á¡£
 6.MFC
 Windows Pywin32ÔÊÐíÄãÏñVCÒ»ÑùµÄÐÎʽÀ´Ê¹ÓÃPYTHON¿ª·¢win32Ó¦ÓᣴúÂë·ç¸ñ¿ÉÒÔÀàËÆwin32 sdk£¬Ò²¿ÉÒÔÀàËÆMFC£¬ÓÉÄãÑ¡Ôñ¡£Èç¹ûÄãÈÔ²»·ÅÆúvcÒ»ÑùµÄ´úÂë¹ý³ÌÔÚpythonÏ£¬ÄÇôÕâ¾ÍÊÇÒ»¸ö²»´íµÄÑ¡Ôñ¡£
 7.PythonCard
 PythonCardÆäʵÊǶÔwxPythonµÄÔÙ·â×°¡£²»¹ý·â×°µÄ¸ü¼Ó¼òµ¥£¬Ê¹ÓÃÆðÀ´¾õµÃ±ÈwxPython¸üÖ±¹Û£¬Ò²¸ü¼òµ¥»¯ÁË¡£
 8.Dabo
 ÈÔÊÇÒ»¸ö»ùÓÚwxpytho


Ïà¹ØÎĵµ£º

pythonѧϰ±Ê¼Ç£¨Ò»£©

Ê×ÏÈתÔØÒ»¶Î¹ØÓÚÍƼöµÄѧϰpythonµÄÊé¼®£¨Ô­ÎÄÁ´½Ó£©£º
1.ѧϰ¡¶A Byte of Python¡·£¬ÖÐÎÄÒëÃûΪ¡¶Python¼òÃ÷½Ì³Ì£¨pdfÏÂÔصØÖ·£©¡·£¬È«ÊéÏÂÀ´Ö»ÓÐ100¶àÒ³£¬¼òµ¥¸ÉÁ·£¬Í¨Ë×Ò׶®£¬Êǹ«ÈϵÄPythonÈëÃŽ̡̳£ÎÒËäȻϵ½ÁË¡¶Python¼òÃ÷½Ì³Ì¡·pdf°æ£¬µ«ÊǾõµÃÆäÖеĴúÂë¿ÉÄÜÊÇÒòΪÒëÕßת»»ÎĵµÀàÐ͵ÄÔ­Òò£¬¸ñʽ±äµÃºÜÂÒ£¬ËùÒÔ× ......

pythonÀàÐÍת»»¡¢ÊýÖµ²Ù×÷


2008-12-21
pythonÀàÐÍת»»¡¢ÊýÖµ²Ù×÷
¹Ø¼ü×Ö: pythonÀàÐÍת»»¡¢ÊýÖµ²Ù×÷
pythonÀàÐÍת»»
Java´úÂë
º¯Êý                      ÃèÊö   
int(x [,base ])    ......

pythonË㷨ʵ¼ù3 ðÅÝÅÅÐò

#ðÅÝÅÅÐò
def BubbleSort(mylist):
n = len(mylist)
i = 0
j = 0
bExchange = False
for i in range(1, n):
bExchange = False
j = n - 1
while j >= i:
if mylist[j] < mylist[j - 1]:
tmp = mylist[j]
myli ......

pythonË㷨ʵ¼ù4 ¿ìËÙÅÅÐò

#¿ìËÙÅÅÐò
def Partition(mylist, low, high):
tmp = mylist[low]
while low < high:
while low < high and mylist[high] >= tmp:
high = high - 1
if low < high:
mylist[low] = mylist[high]
low = low + 1
while low < hi ......

pythonË㷨ʵ¼ù5 Ö±½ÓÑ¡ÔñÅÅÐò

#Ö±½ÓÑ¡ÔñÅÅÐò
def SelectSort(mylist):
size = len(mylist)
i = 0
for i in range(0, size):
k = i
for j in range(i + 1, size):
if mylist[j] < mylist[k]:
k = j

if k != i:
tmp = mylist[i]
......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ