mirror of
https://github.com/python/cpython.git
synced 2025-08-03 08:34:29 +00:00
Modified for installer and new names of various applets. Also cleaned
up anything else I saw.
This commit is contained in:
parent
9ffa432972
commit
3412c5d0fb
7 changed files with 113 additions and 137 deletions
|
@ -1,9 +1,9 @@
|
|||
<HTML>
|
||||
<HEAD>
|
||||
<TITLE>Using Python 1.4 on the Macintosh</TITLE>
|
||||
<TITLE>Using Python 1.5 on the Macintosh</TITLE>
|
||||
</HEAD>
|
||||
<BODY>
|
||||
<H1>Using Python 1.4 on the Macintosh</H1>
|
||||
<H1>Using Python 1.5 on the Macintosh</H1>
|
||||
<HR>
|
||||
|
||||
This document is an introduction to using Python on the Apple
|
||||
|
@ -42,8 +42,8 @@ interpreter in interactive mode by double-clicking its icon: <p>
|
|||
This should give you a text window with an informative version string
|
||||
and a prompt, something like the following:
|
||||
<PRE>
|
||||
Python 1.4 (Oct 27 1996) [CW PPC w/GUSI]
|
||||
Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam
|
||||
Python 1.5 (#0 Aug 27, 1997) [CW PPC w/GUSI MSL]
|
||||
Copyright 1991-1997 Stichting Mathematisch Centrum, Amsterdam
|
||||
>>>
|
||||
</PRE>
|
||||
The version string tells you the version of Python, whether it was
|
||||
|
@ -189,6 +189,8 @@ The options modify the interpreters behaviour in the following way:
|
|||
exiting) after a script has terminated normally,
|
||||
<li> for every module imported a line is printed telling you where the
|
||||
module was loaded from,
|
||||
<li> do not print the values of expressions executed as statements in
|
||||
an interactive python (obsolete),
|
||||
<li> do not buffer stdout and stderr,
|
||||
<li> print some debugging output during the parsing phase,
|
||||
<li> keep the output window open when a script terminates.
|
||||
|
@ -279,9 +281,9 @@ The python interpreter keeps a preferences file in the standard
|
|||
location in the system folder. In this preferences file it remembers
|
||||
the default module search path and the default settings for the
|
||||
runtime options. The preferences are settable via
|
||||
<CODE>EditPythonPrefs</CODE>. For PPC python this is a standalone
|
||||
<CODE>EditPythonPrefs</CODE>. For PPC/cfm68k python this is a standalone
|
||||
program living in the main Python folder, for 68K python it is a
|
||||
script in the <CODE>Scripts</CODE> folder. <p>
|
||||
script in the <CODE>Mac:Scripts</CODE> folder. <p>
|
||||
|
||||
The interface to edit the preferences is rather clunky for the current
|
||||
release. <p>
|
||||
|
@ -310,8 +312,8 @@ An applet is a fullblown application written in Python, similar to an
|
|||
AppleScript applet (and completely different from a Java
|
||||
applet). Applets are currently supported on PowerPC macintoshes and on
|
||||
68K macintoshes if you use the CFM68K version of the interpreter,
|
||||
and are created using the <CODE>mkapplet</CODE> program. You create an
|
||||
applet by dropping the python source script onto mkapplet.
|
||||
and are created using the <CODE>BuildApplet</CODE> program. You create an
|
||||
applet by dropping the python source script onto BuildApplet.
|
||||
<a href="example2.html">Example 2</a> is a more involved applet
|
||||
with its own resource file, etc. <p>
|
||||
|
||||
|
@ -320,7 +322,7 @@ it is not self-sufficient, so distributing it to a machine without an
|
|||
installed Python interpreter will not work: it needs the shared python
|
||||
execution engine <CODE>PythonCore</CODE>, and probably various modules
|
||||
from the Lib and PlugIns folders. Distributing it to a machine that does
|
||||
have a Python system (of the same release and architecture) will work. <p>
|
||||
have a Python system will work. <p>
|
||||
|
||||
<h2>Customizing applets</h2>
|
||||
|
||||
|
@ -394,10 +396,11 @@ set) the end-of-line convention used in a file. <p>
|
|||
Python attempts to keep its preferences file up-to-date even when you
|
||||
move the Python folder around, etc. If this fails the effect will be
|
||||
that Python cannot start or, worse, that it does work but it cannot find
|
||||
any standard modules. In this case, start Python examine <code>sys.path</code>.
|
||||
any standard modules. In this case, start Python and examine <code>sys.path</code>.
|
||||
If it is incorrect remove any Python preferences file from the system
|
||||
folder and start the interpreter <em>while the interpreter sits in the main
|
||||
Python folder</em>. This will regenerate the preferences file. <p>
|
||||
Python folder</em>. This will regenerate the preferences file. You may also
|
||||
have to run the ConfigurePython applet again. <p>
|
||||
|
||||
<h2>Where to go from here</h2>
|
||||
|
||||
|
@ -405,7 +408,7 @@ The next section to check out is the <a href="index.html">annotated sample progr
|
|||
|
||||
<HR>
|
||||
<A HREF="http://www.cwi.nl/~jack">Jack Jansen</A>,
|
||||
<A HREF="mailto:jack@cwi.nl">jack@cwi.nl</A>, 20-Nov-1996.
|
||||
<A HREF="mailto:jack@cwi.nl">jack@cwi.nl</A>, 27-Aug-1997.
|
||||
|
||||
</BODY>
|
||||
</HTML>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue