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

Python & XML


Chapter 1
Python and XML
Python and XML are two very different animals, each with a rich
history. Python is a full-scale programming language that has grown
from scripting world roots in a very organic way, through the vision
and guidance of Python's inventor, Guido van Rossum. Guido continues to
take into account the needs of Python developers as Python matures.
XML, on the other hand, though strongly impacted by the ideas of a
small cadre of visionaries, has grown from standards-committee roots.
It has seen both quiet adoption and wrenching battles over its future.
Why bother putting the two technologies together?
Before the Python/XML combination, there seemed no easy or effective
way to work with XML in a distributed environment. Developers were
forced to rely on a variety of tools used in awkward combination with
one other. We used shell scripting and Perl to process text and
interact with the operating system, and then used Java XML API's for
processing XML and network programming. The shell provided an excellent
means of file manipulation and interaction with the Unix system, and
Perl was a good choice for simple text manipulation, providing access
to the Unix APIs. Unfortunately, neither sported a sophisticated object
model. Java, on the other hand, featured an object-oriented
environment, a robust platform API for network programming, threads,
and graphical user interface (GUI) application development. But with
Java, we found an immediate lack of text manipulation power; scripting
languages typically provided strong text processing. Python presented a
perfect solution, as it combines the strengths of all of these various
options.
Like most scripting languages, Python features excellent text and
file manipulation capabilities. Yet, unlike most scripting languages,
Python sports a powerful object-oriented environment with a robust
platform API for network programming, threads, and graphical user
interface development. It can b


Ïà¹ØÎĵµ£º

Python Ï̲߳Ù×÷

ÔÚpythonÖÐÈçºÎ´´½¨Ò»¸öÏ̶߳ÔÏó
Èç¹ûÄãÒª´´½¨Ò»¸öÏ̶߳ÔÏ󣬺ܼòµ¥£¬Ö»ÒªÄãµÄÀà¼Ì³Ðthreading.Thread£¬È»ºóÔÚ__init__ÀïÊ×Ïȵ÷ÓÃthreading.ThreadµÄ__init__·½·¨¼´¿É
import threading
class mythread(threading.Thread):
    def __init__(self, threadname):
      & ......

µÚÒ»´ÎдÍêÕûµÄPython GUI³ÌÐò

 Ò¹ÀïÓÃÍâ¹ÒÈÝÒ×±»²é£¬Òò´ËÏëÈòËÊìµÄʱ¼ä¼¯Öе½°×Ì죬ÿ´Î¶¼Òª¿ÚË㣬Âé·³£¬ÕýºÃ¸Õ¸ÕѧÁËwxPython£¬Ò»Ê±ÊÖÑ÷£¬À´×Ô¼ºÐ´¸ö°É¡£Ëä˵´¿Êô×ÔÓé×ÔÀÖ£¬µ«Ò²Ñ§µ½²»ÉÙ¶«Î÷¡£ÏÖ¼ÇÓÚÏ¡£
1. ¹ØÓÚPythonµÄGUIÉè¼Æ
Ò»Ö±ÒÔÀ´¶¼Ã»ÓÐÒ»¸ö×ã¹»ºÃµÄKiller IDE£¬ÕâÒ²¹Ö²»µÃ£¬Ã»ÓÐÒ»¸ö×㹻ǿ´óµÄºǫ́£¬ÒªÏë×ö³ÉÖØÁ¿¼¶µÄIDE̸ºÎÈÝÒ×£¨ÒªÊ ......

opencv python cool

µ±Äê×ö±ÏÒµÂÛÎĵÄʱºòopenCV¾ÍÏñÊÇÎÒµÄÈðÊ¿¾üµ¶£¬Ì«ÓиÐÇéÁË¡£Èç½ñÓÃÁËÒ»Äê¶àµÄpython£¬·¢ÏÖopenCVÒ²ÓÐpython°æ±¾ÁË£¬ÕæÊÇÌ«¿áÁË£¡µ±È»pythonÔÚ´¦ÀíͼÏñʱ»¹¿ÉÒÔÓÃÆäËü¿âÀýÈçPIL(Python Imaging Library )£¬Ò»ÖÖÇáÁ¿¼¶µÄͼÏñ¿â¡£Ä¿Ç°openCV1.0°æ±¾¶ÔÓ¦µÄpython°æ±¾Îª2.5£¬openCV2.0¶ÔÓ¦python 2.6¡£
¸½Â¼£º
1. һƪ½éÉÜͼ ......

Eclipse+PyDev = Python±à¼­Æ÷£¬

http://www.ibm.com/developerworks/cn/opensource/os-cn-ecl-pydev/Á¬½ÓÕâ¸öÍøÖ·£¬²»»áÈÃÄãʧÍûµÄ¡£
PyDev ¼ò½é
2003Äê7ÔÂ16ÈÕ£¬ÒÔ Fabio Zadrozny ΪÊ×µÄÈýÈË¿ª·¢Ð¡×éÔÚÈ«Çò×î´óµÄ¿ª·ÅÔ´´úÂëÈí¼þ¿ª·¢Æ½Ì¨ºÍ²Ö¿â SourceForge ÉÏ×¢²áÁËÒ»¿îеÄÏîÄ¿£¬¸ÃÏîĿʵÏÖÁËÒ»¸ö¹¦ÄÜÇ¿´óµÄ Eclipse²å¼þ£¬Óû§¿ÉÒÔÍêÈ«ÀûÓà Eclipse À ......

python ¶íÂÞ˹·½¿é

Õâ¸öËãÊÇC++ǶÈëpython°É£¬ÀûÓÃpythonʵÏÖÏÔʾºÍʼþ´¦Àí£¬C++ʵÏÖÂß¼­
ÒÔºóÓÐʱ¼äÒ²»á·´¹ýÀ´ÊÔÊÔ£º£© 
import pygame
import sys
import os
import ctypes
def cur_file_dir():
#»ñÈ¡½Å±¾Â·¾¶
path = sys.path[0]
#ÅжÏΪ½Å±¾Îļþ»¹ÊÇpy2exe±àÒëºóµÄÎļþ£¬Èç¹ûÊǽű¾Îļþ£¬Ôò·µ»ØµÄÊǽű¾µÄÄ¿Â ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ