Search
Searching for multiple words only shows matches that contain all words.
Search Results
Search finished, found 55 pages matching the search query.
- bytearray.title (Python method, in Built-in Types)
- bytes.title (Python method, in Built-in Types)
- str.title (Python method, in Built-in Types)
- turtle.title (Python function, in
turtle
— Turtle graphics) - bytearray.istitle (Python method, in Built-in Types)
- bytes.istitle (Python method, in Built-in Types)
- Py_UNICODE_ISTITLE (C function, in Unicode Objects and Codecs)
- Py_UNICODE_TOTITLE (C function, in Unicode Objects and Codecs)
- str.istitle (Python method, in Built-in Types)
- xmlrpc.server.DocCGIXMLRPCRequestHandler.set_server_title (Python method, in
xmlrpc.server
— Basic XML-RPC servers) - xmlrpc.server.DocXMLRPCServer.set_server_title (Python method, in
xmlrpc.server
— Basic XML-RPC servers) argparse
— Parser for command-line options, arguments and subcommands...] for word in string.casefold().split()]) ... >>> parser = argparse.ArgumentParser() >>> _ = parser.add_argument('short_title', type=hyphenated) >>> parser.parse_args(['"The Tale of Two Cities"']) Namespace(short_title='"the-tale-of-two-cit...
collections
— Container datatypes...ames to result tuples returned by the csv or sqlite3 modules: EmployeeRecord = namedtuple('EmployeeRecord', 'name, age, title, department, paygrade') import csv for emp in map(EmployeeRecord._make, csv.reader(open("employees.csv", "rb"))):...
dbm
— Interfaces to Unix “databases”...tabase module specific exception instead of KeyError. The following example records some hostnames and a corresponding title, and then prints out the contents of the database: import dbm # Open database, creating it if necessary. with db...
html.parser
— Simple HTML and XHTML parser...le_data(self, data): print("Encountered some data :", data) parser = MyHTMLParser() parser.feed('<html><head><title>Test</title></head>' '<body><h1>Parse me!</h1></body></html>') The output will then be: Encountered...
json
— JSON encoder and decoder...options infile The JSON file to be validated or pretty-printed: $ python -m json.tool mp_films.json [ { "title": "And Now for Something Completely Different", "year": 1971 }, { "title": "Monty Python a...
logging
— Logging facility for Python...mpty string. You will need to override this method if you want specific behaviour, e.g. to show the count of records, a title or a separator line. formatFooter(records) Return a footer for a list of records. The base implementation just...
multiprocessing
— Process-based parallelism...e individual process IDs involved, here is an expanded example: from multiprocessing import Process import os def info(title): print(title) print('module name:', __name__) print('parent process:', os.getppid()) print('proce...
optparse
— Parser for command line options...contain several options. An option group is obtained using the class OptionGroup: class optparse.OptionGroup(parser, title, description=None) where parser is the OptionParser instance the group will be inserted in to title is the group...
smtplib
— SMTP protocol client...articular, the ‘To’ and ‘From’ addresses must be included in the message headers explicitly: import smtplib def prompt(title): return input(title).strip() from_addr = prompt("From: ") to_addrs = prompt("To: ").split() print("Enter me...
socket
— Low-level networking interface...for Windows, see the WinSock (or Winsock 2) specification. For IPv6-ready APIs, readers may want to refer to RFC 3493 titled Basic Socket Interface Extensions for IPv6.
sqlite3
— DB-API 2.0 interface for SQLite databases...cursor() Now that we’ve got a database connection and a cursor, we can create a database table movie with columns for title, release year, and review score. For simplicity, we can just use column names in the table declaration – thanks to...
string
— Common string operations...tuple (obj, used_key). The default version takes strings of the form defined in PEP 3101, such as “0[name]” or “label.title”. args and kwargs are as passed in to vformat(). The return value used_key has the same meaning as the key param...
tkinter.messagebox
— Tkinter message prompts...the specified window the logical parent of the message box. The message box is displayed on top of its parent window. titleSpecifies a string to display as the title of the message box. This option is ignored on macOS, where platform guid...
tkinter
— Python interface to Tcl/Tk...ility command, wm, for interacting with the window manager. Options to the wm command allow you to control things like titles, placement, icon bitmaps, and the like. In tkinter, these commands have been implemented as methods on the Wm cl...
turtle
— Turtle graphics...ists on; it’s created automatically along with the turtle. The turtle’s screen can be customised, for example: t.screen.title('Object-oriented turtle demo') t.screen.bgcolor("orange") Turtle graphics reference Note In the following do...
typing
— Support for type hints...eadOnly A special typing construct to mark an item of a TypedDict as read-only. For example: class Movie(TypedDict): title: ReadOnly[str] year: int def mutate_movie(m: Movie) -> None: m["year"] = 1999 # allowed m["title"] = "T...
urllib.request
— Extensible library for opening URLs...99/xhtml" xml:lang="en" lang="en">\n\n<head>\n <meta http-equiv="content-type" content="text/html; charset=utf-8" />\n <title>Python Programming ' Note that urlopen returns a bytes object. This is because there is no way for urlopen to a...
xml.dom.minidom
— Minimal DOM implementation...case, we do not take much advantage of the flexibility of the DOM. import xml.dom.minidom document = """\ <slideshow> <title>Demo slideshow</title> <slide><title>Slide title</title> <point>This is a demo</point> <point>Of a program for pro...
xml.dom.pulldom
— Support for building partial DOM trees...alled. expandNode(node) Expands all children of node into node. Example: from xml.dom import pulldom xml = '<html><title>Foo</title> <p>Some text <div>and more</div></p> </html>' doc = pulldom.parseString(xml) for event, node in doc:...
xml.etree.ElementTree
— The ElementTree XML API...indall(".//neighbor[2]") For XML with namespaces, use the usual qualified {namespace}tag notation: # All dublin-core "title" tags in the document root.findall(".//{http://purl.org/dc/elements/1.1/}title") Supported XPath syntax Synt...
xmlrpc.server
— Basic XML-RPC servers...style HTML documentation. This allows a server to provide its own web-based documentation. DocXMLRPCServer.set_server_title(server_title) Set the title used in the generated HTML documentation. This title will be used inside the HTML “tit...
- 13. What Now?
...n of code examples, larger modules, and useful scripts. Particularly notable contributions are collected in a book also titled Python Cookbook (O’Reilly & Associates, ISBN 0-596-00797-3.) https://pyvideo.org collects links to Python-related...
- Built-in Types
...h its first character capitalized and the rest lowercased. Changed in version 3.8: The first character is now put into titlecase rather than uppercase. This means that characters like digraphs will only have their first letter capitalized,...
- Changelog
...set. macOS gh-116145: Update macOS installer to Tcl/Tk 8.6.14. IDLE gh-88516: On macOS show a proxy icon in the title bar of editor windows to match platform behaviour. Tools/Demos gh-100176: Remove outdated Tools/{io,cc,string}...
- Dealing with Bugs
...it an issue. Click on the “New issue” button in the top bar to report a new issue. The submission form has two fields, “Title” and “Comment”. For the “Title” field, enter a very short description of the problem; fewer than ten words is good...
- Descriptor Guide
...e the schema for each table in a database: class Movie: table = 'Movies' # Table name key = 'title' # Primary key director = Field() year = Field() def __init__(self, key):...
- Functional Programming HOWTO
...er of David Mertz’s book Text Processing in Python discusses functional programming for text processing, in the section titled “Utilizing Higher-Order Functions in Text Processing”. Mertz also wrote a 3-part series of articles on functional...
- General Python FAQ
...ribing a suggested new feature for Python, providing a concise technical specification and a rationale. Look for a PEP titled “Python X.Y Release Schedule”, where X.Y is a version that hasn’t been publicly released yet. New development is...
- History and License
...CONDITIONS OF ANY KIND, either express or implied, including, without limitation, any warranties or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A PARTICULAR PURPOSE. You are solely responsible for determi...
- HOWTO Fetch Internet Resources Using The urllib Package
...//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">\n\n\n<html ... <title>Page Not Found</title>\n ... Wrapping it Up So if you want to be prepared for HTTPError or URLError there a...
- IDLE — Python editor and shell
...r Edit => Find in Files, are a subtype of editor window. They currently have the same top menu but a different default title and context menu. On macOS, there is one application menu. It dynamically changes according to the window current...
- Library and Extension FAQ
...stants 0, 1 and 2, respectively. Network/Internet Programming What WWW tools are there for Python? See the chapters titled Internet Protocols and Support and Internet Data Handling in the Library Reference Manual. Python has many modul...
- Py_UNICODE_ISTITLE.ch (C function parameter, in Unicode Objects and Codecs)
- Py_UNICODE_TOTITLE.ch (C function parameter, in Unicode Objects and Codecs)
- Regular Expression HOWTO
...he naive pattern for matching a single HTML tag doesn’t work because of the greedy nature of .*. >>> s = '<html><head><title>Title</title>' >>> len(s) 32 >>> print(re.match('<.*>', s).span()) (0, 32) >>> print(re.match('<.*>', s).group()) <...
- Tkinter Dialogs
...e classes and functions for creating simple modal dialogs to get a value from the user. tkinter.simpledialog.askfloat(title, prompt, **kw) tkinter.simpledialog.askinteger(title, prompt, **kw) tkinter.simpledialog.askstring(title, prompt...
- Unicode HOWTO
...cumentation for the unicodedata module. The documentation for the codecs module. Marc-André Lemburg gave a presentation titled “Python and Unicode” (PDF slides) at EuroPython 2002. The slides are an excellent overview of the design of Pyth...
- Unicode Objects and Codecs
...nt Py_UNICODE_ISUPPER(Py_UCS4 ch) Return 1 or 0 depending on whether ch is an uppercase character. int Py_UNICODE_ISTITLE(Py_UCS4 ch) Return 1 or 0 depending on whether ch is a titlecase character. int Py_UNICODE_ISLINEBREAK(Py_UCS4...
- What’s New in Python 2.0
...e March 2000 archives of the python-dev mailing list contain most of the relevant discussion, especially in the threads titled “Reference cycle collection for Python” and “Finalization again”. Other Core Changes Various minor changes have...
- What’s New in Python 2.2
...features while still remaining quite easy to read. Next, there are two relevant PEPs, PEP 252 and PEP 253. PEP 252 is titled “Making Types Look More Like Classes”, and covers the descriptor API. PEP 253 is titled “Subtyping Built-in Types...
- What’s New in Python 2.4
...ained users need to edit templates. The usual way of substituting variables by name is the % operator: >>> '%(page)i: %(title)s' % {'page':2, 'title': 'The Best of Times'} '2: The Best of Times' When writing the template string, it can be...
- What’s New In Python 3.11
...For example, the following specifies a TypedDict with one required and one not-required key: class Movie(TypedDict): title: str year: NotRequired[int] m1: Movie = {"title": "Black Panther", "year": 2018} # OK m2: Movie = {"title": "...
- What’s New In Python 3.2
...ing(""" ... [DEFAULT] ... location = upper left ... visible = yes ... editable = no ... color = blue ... ... [main] ... title = Main Menu ... color = green ... ... [options] ... title = Options ... """) >>> parser['main']['color'] 'green' >...
- What’s New In Python 3.8
...list comprehensions where a value computed in a filtering condition is also needed in the expression body: [clean_name.title() for name in names if (clean_name := normalize('NFC', name)) in allowed_names] Try to limit use of the walrus...