Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
07bcd998
Kaydet (Commit)
07bcd998
authored
Nis 03, 1998
tarafından
Fred Drake
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Start at updating the template a little bit. There's a lot of stuff that's
just not here yet.
üst
47cfd03d
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
129 additions
and
90 deletions
+129
-90
libtemplate.tex
Doc/lib/libtemplate.tex
+43
-30
libtemplate.tex
Doc/libtemplate.tex
+43
-30
module.tex
Doc/templates/module.tex
+43
-30
No files found.
Doc/lib/libtemplate.tex
Dosyayı görüntüle @
07bcd998
...
@@ -4,18 +4,27 @@
...
@@ -4,18 +4,27 @@
% ==== 1. ====
% ==== 1. ====
% Choose one of the following section headers and index entries;
% Choose one of the following section headers and index entries;
% \section
{}
generates the section header,
% \section generates the section header,
% \bimodindex
{} or \stmodindex{}
generates an index entry for this
% \bimodindex
or \stmodindex
generates an index entry for this
% module. Note that these should only be used for the defining entry
% module. Note that these should only be used for the defining entry
% for the module. Other references to the module should use
% for the module. Other references to the module should use
% \refbimodindex{} or \refstmodindex{}.
% \refbimodindex, \refstmodindex, \refexmodindex or \refmodindex, as
% The \label{module-spam} line is for the \seealso{} command.
% appropriate. (Just prepend "ref" to the csname of the \*modindex
% macro used in the module definition.)
%
% The \label{module-spam} line is for the \seealso command.
\section
{
Built-in Module
\module
{
spam
}}
% If implemented in C, in
\bimodindex
{
spam
}
% standard library
\section
{
Standard Module
\module
{
spam
}}
% If implemented in Python, in
\stmodindex
{
spam
}
% standard library
\section
{
Built-in Module
\sectcode
{
spam
}}
% If implemented in C
\section
{
Extension Module
\module
{
spam
}}
% If implemented in C, but not
\
bimodindex
{
spam
}
\
exmodindex
{
spam
}
% in standard library
\section
{
Standard Module
\sectcode
{
spam
}}
% If implemented in Python
\section
{
Module
\module
{
spam
}}
% If implemented in Python, but not
\
stmodindex
{
spam
}
\
modindex
{
spam
}
% in standard library
\label
{
module-spam
}
\label
{
module-spam
}
...
@@ -42,12 +51,6 @@ is only available on genuine \UNIX{} systems.
...
@@ -42,12 +51,6 @@ is only available on genuine \UNIX{} systems.
The
\module
{
spam
}
module defines the following functions:
The
\module
{
spam
}
module defines the following functions:
% ---- 3.1. ----
% ---- 3.1. ----
% Redefine the ``indexsubitem'' macro to point to this module
% (alternatively, you can put this at the top of the file):
\setindexsubitem
{
(in module spam)
}
% ---- 3.2. ----
% For each function, use a ``funcdesc'' block. This has exactly two
% For each function, use a ``funcdesc'' block. This has exactly two
% parameters (each parameters is contained in a set of curly braces):
% parameters (each parameters is contained in a set of curly braces):
% the first parameter is the function name (this automatically
% the first parameter is the function name (this automatically
...
@@ -61,14 +64,14 @@ The \module{spam} module defines the following functions:
...
@@ -61,14 +64,14 @@ The \module{spam} module defines the following functions:
% least once in the description; each usage (even inside \code{...})
% least once in the description; each usage (even inside \code{...})
% should be enclosed in \var{...}.
% should be enclosed in \var{...}.
\begin{funcdesc}
{
open
}{
filename
\optional
{
, mode
, buffersize
}}
\begin{funcdesc}
{
open
}{
filename
\optional
{
, mode
\optional
{
, buffersize
}
}}
Open the file
\var
{
filename
}
as a can of Spam. The optional
Open the file
\var
{
filename
}
as a can of Spam. The optional
\var
{
mode
}
and
\var
{
buffersize
}
arguments specify the read-write mode
\var
{
mode
}
and
\var
{
buffersize
}
arguments specify the read-write mode
(
\code
{
'r'
}
(default) or
\code
{
'w'
}
) and the buffer size (default:
(
\code
{
'r'
}
(default) or
\code
{
'w'
}
) and the buffer size (default:
system dependent).
system dependent).
\end{funcdesc}
\end{funcdesc}
% ---- 3.
3
. ----
% ---- 3.
2
. ----
% Data items are described using a ``datadesc'' block. This has only
% Data items are described using a ``datadesc'' block. This has only
% one parameter: the item's name.
% one parameter: the item's name.
...
@@ -78,7 +81,7 @@ default varies per supermarket. This variable should not be changed
...
@@ -78,7 +81,7 @@ default varies per supermarket. This variable should not be changed
once the
\function
{
open()
}
function has been called.
once the
\function
{
open()
}
function has been called.
\end{datadesc}
\end{datadesc}
% --- 3.
4
. ---
% --- 3.
3
. ---
% Exceptions are described using a ``excdesc'' block. This has only
% Exceptions are described using a ``excdesc'' block. This has only
% one parameter: the exception name.
% one parameter: the exception name.
...
@@ -88,10 +91,19 @@ The exception argument is a string describing the reason of the
...
@@ -88,10 +91,19 @@ The exception argument is a string describing the reason of the
failure.
failure.
\end{excdesc}
\end{excdesc}
% ---- 3.5. ----
% ---- 3.4. ----
% There is no standard block type for classes. I generally use
% Other standard environments:
% ``funcdesc'' blocks, since class instantiation looks very much like
%
% a function call.
% classdesc - Python classes; same arguments are funcdesc
% methoddesc - methods, like funcdesc but has an optional parameter
% to give the type name: \begin{methoddesc}[mytype]{name}{args}
% By default, the type name will be the name of the
% last class defined using classdesc. The type name
% is required if the type is implemented in C (because
% there's no classdesc) or if the class isn't directly
% documented (if it's private).
% memberdesc - data members, like datadesc, but with an optional
% type name like methoddesc.
% ==== 4. ====
% ==== 4. ====
...
@@ -107,21 +119,22 @@ Example:
...
@@ -107,21 +119,22 @@ Example:
>>> can.empty()
>>> can.empty()
>>> can.close()
>>> can.close()
\end{verbatim}
\end{verbatim}
%
% Note that there is no trailing ">>> " prompt shown.
% ==== 5. ====
% ==== 5. ====
% If your module defines new object types (for a built-in module) or
% If your module defines new object types (for a built-in module) or
% classes (for a module written in Python), you should list the
% classes (for a module written in Python), you should list the
% methods and instance variables (if any) of each type or class in a
% methods and instance variables (if any) of each type or class in a
% separate subsection. It is important to redefine ``indexsubitem''
% separate subsection.
% for each subsection.
\subsection
{
Spam Objects
}
\subsection
{
Spam Objects
}
\label
{
spam-objects
}
% This label is generally useful for referencing this section, but is
% also used to give a filename when generating HTML.
Spam objects (returned by
\function
{
open()
}
above) have the following
Spam objects, as returned by
\function
{
open()
}
above, have the
methods.
following methods:
\setindexsubitem
{
(spam method)
}
\begin{
funcdesc}
{
empty
}{}
\begin{
methoddesc}
[spam]
{
empty
}{}
Empty the can into the trash.
Empty the can into the trash.
\end{
func
desc}
\end{
method
desc}
Doc/libtemplate.tex
Dosyayı görüntüle @
07bcd998
...
@@ -4,18 +4,27 @@
...
@@ -4,18 +4,27 @@
% ==== 1. ====
% ==== 1. ====
% Choose one of the following section headers and index entries;
% Choose one of the following section headers and index entries;
% \section
{}
generates the section header,
% \section generates the section header,
% \bimodindex
{} or \stmodindex{}
generates an index entry for this
% \bimodindex
or \stmodindex
generates an index entry for this
% module. Note that these should only be used for the defining entry
% module. Note that these should only be used for the defining entry
% for the module. Other references to the module should use
% for the module. Other references to the module should use
% \refbimodindex{} or \refstmodindex{}.
% \refbimodindex, \refstmodindex, \refexmodindex or \refmodindex, as
% The \label{module-spam} line is for the \seealso{} command.
% appropriate. (Just prepend "ref" to the csname of the \*modindex
% macro used in the module definition.)
%
% The \label{module-spam} line is for the \seealso command.
\section
{
Built-in Module
\module
{
spam
}}
% If implemented in C, in
\bimodindex
{
spam
}
% standard library
\section
{
Standard Module
\module
{
spam
}}
% If implemented in Python, in
\stmodindex
{
spam
}
% standard library
\section
{
Built-in Module
\sectcode
{
spam
}}
% If implemented in C
\section
{
Extension Module
\module
{
spam
}}
% If implemented in C, but not
\
bimodindex
{
spam
}
\
exmodindex
{
spam
}
% in standard library
\section
{
Standard Module
\sectcode
{
spam
}}
% If implemented in Python
\section
{
Module
\module
{
spam
}}
% If implemented in Python, but not
\
stmodindex
{
spam
}
\
modindex
{
spam
}
% in standard library
\label
{
module-spam
}
\label
{
module-spam
}
...
@@ -42,12 +51,6 @@ is only available on genuine \UNIX{} systems.
...
@@ -42,12 +51,6 @@ is only available on genuine \UNIX{} systems.
The
\module
{
spam
}
module defines the following functions:
The
\module
{
spam
}
module defines the following functions:
% ---- 3.1. ----
% ---- 3.1. ----
% Redefine the ``indexsubitem'' macro to point to this module
% (alternatively, you can put this at the top of the file):
\setindexsubitem
{
(in module spam)
}
% ---- 3.2. ----
% For each function, use a ``funcdesc'' block. This has exactly two
% For each function, use a ``funcdesc'' block. This has exactly two
% parameters (each parameters is contained in a set of curly braces):
% parameters (each parameters is contained in a set of curly braces):
% the first parameter is the function name (this automatically
% the first parameter is the function name (this automatically
...
@@ -61,14 +64,14 @@ The \module{spam} module defines the following functions:
...
@@ -61,14 +64,14 @@ The \module{spam} module defines the following functions:
% least once in the description; each usage (even inside \code{...})
% least once in the description; each usage (even inside \code{...})
% should be enclosed in \var{...}.
% should be enclosed in \var{...}.
\begin{funcdesc}
{
open
}{
filename
\optional
{
, mode
, buffersize
}}
\begin{funcdesc}
{
open
}{
filename
\optional
{
, mode
\optional
{
, buffersize
}
}}
Open the file
\var
{
filename
}
as a can of Spam. The optional
Open the file
\var
{
filename
}
as a can of Spam. The optional
\var
{
mode
}
and
\var
{
buffersize
}
arguments specify the read-write mode
\var
{
mode
}
and
\var
{
buffersize
}
arguments specify the read-write mode
(
\code
{
'r'
}
(default) or
\code
{
'w'
}
) and the buffer size (default:
(
\code
{
'r'
}
(default) or
\code
{
'w'
}
) and the buffer size (default:
system dependent).
system dependent).
\end{funcdesc}
\end{funcdesc}
% ---- 3.
3
. ----
% ---- 3.
2
. ----
% Data items are described using a ``datadesc'' block. This has only
% Data items are described using a ``datadesc'' block. This has only
% one parameter: the item's name.
% one parameter: the item's name.
...
@@ -78,7 +81,7 @@ default varies per supermarket. This variable should not be changed
...
@@ -78,7 +81,7 @@ default varies per supermarket. This variable should not be changed
once the
\function
{
open()
}
function has been called.
once the
\function
{
open()
}
function has been called.
\end{datadesc}
\end{datadesc}
% --- 3.
4
. ---
% --- 3.
3
. ---
% Exceptions are described using a ``excdesc'' block. This has only
% Exceptions are described using a ``excdesc'' block. This has only
% one parameter: the exception name.
% one parameter: the exception name.
...
@@ -88,10 +91,19 @@ The exception argument is a string describing the reason of the
...
@@ -88,10 +91,19 @@ The exception argument is a string describing the reason of the
failure.
failure.
\end{excdesc}
\end{excdesc}
% ---- 3.5. ----
% ---- 3.4. ----
% There is no standard block type for classes. I generally use
% Other standard environments:
% ``funcdesc'' blocks, since class instantiation looks very much like
%
% a function call.
% classdesc - Python classes; same arguments are funcdesc
% methoddesc - methods, like funcdesc but has an optional parameter
% to give the type name: \begin{methoddesc}[mytype]{name}{args}
% By default, the type name will be the name of the
% last class defined using classdesc. The type name
% is required if the type is implemented in C (because
% there's no classdesc) or if the class isn't directly
% documented (if it's private).
% memberdesc - data members, like datadesc, but with an optional
% type name like methoddesc.
% ==== 4. ====
% ==== 4. ====
...
@@ -107,21 +119,22 @@ Example:
...
@@ -107,21 +119,22 @@ Example:
>>> can.empty()
>>> can.empty()
>>> can.close()
>>> can.close()
\end{verbatim}
\end{verbatim}
%
% Note that there is no trailing ">>> " prompt shown.
% ==== 5. ====
% ==== 5. ====
% If your module defines new object types (for a built-in module) or
% If your module defines new object types (for a built-in module) or
% classes (for a module written in Python), you should list the
% classes (for a module written in Python), you should list the
% methods and instance variables (if any) of each type or class in a
% methods and instance variables (if any) of each type or class in a
% separate subsection. It is important to redefine ``indexsubitem''
% separate subsection.
% for each subsection.
\subsection
{
Spam Objects
}
\subsection
{
Spam Objects
}
\label
{
spam-objects
}
% This label is generally useful for referencing this section, but is
% also used to give a filename when generating HTML.
Spam objects (returned by
\function
{
open()
}
above) have the following
Spam objects, as returned by
\function
{
open()
}
above, have the
methods.
following methods:
\setindexsubitem
{
(spam method)
}
\begin{
funcdesc}
{
empty
}{}
\begin{
methoddesc}
[spam]
{
empty
}{}
Empty the can into the trash.
Empty the can into the trash.
\end{
func
desc}
\end{
method
desc}
Doc/templates/module.tex
Dosyayı görüntüle @
07bcd998
...
@@ -4,18 +4,27 @@
...
@@ -4,18 +4,27 @@
% ==== 1. ====
% ==== 1. ====
% Choose one of the following section headers and index entries;
% Choose one of the following section headers and index entries;
% \section
{}
generates the section header,
% \section generates the section header,
% \bimodindex
{} or \stmodindex{}
generates an index entry for this
% \bimodindex
or \stmodindex
generates an index entry for this
% module. Note that these should only be used for the defining entry
% module. Note that these should only be used for the defining entry
% for the module. Other references to the module should use
% for the module. Other references to the module should use
% \refbimodindex{} or \refstmodindex{}.
% \refbimodindex, \refstmodindex, \refexmodindex or \refmodindex, as
% The \label{module-spam} line is for the \seealso{} command.
% appropriate. (Just prepend "ref" to the csname of the \*modindex
% macro used in the module definition.)
%
% The \label{module-spam} line is for the \seealso command.
\section
{
Built-in Module
\module
{
spam
}}
% If implemented in C, in
\bimodindex
{
spam
}
% standard library
\section
{
Standard Module
\module
{
spam
}}
% If implemented in Python, in
\stmodindex
{
spam
}
% standard library
\section
{
Built-in Module
\sectcode
{
spam
}}
% If implemented in C
\section
{
Extension Module
\module
{
spam
}}
% If implemented in C, but not
\
bimodindex
{
spam
}
\
exmodindex
{
spam
}
% in standard library
\section
{
Standard Module
\sectcode
{
spam
}}
% If implemented in Python
\section
{
Module
\module
{
spam
}}
% If implemented in Python, but not
\
stmodindex
{
spam
}
\
modindex
{
spam
}
% in standard library
\label
{
module-spam
}
\label
{
module-spam
}
...
@@ -42,12 +51,6 @@ is only available on genuine \UNIX{} systems.
...
@@ -42,12 +51,6 @@ is only available on genuine \UNIX{} systems.
The
\module
{
spam
}
module defines the following functions:
The
\module
{
spam
}
module defines the following functions:
% ---- 3.1. ----
% ---- 3.1. ----
% Redefine the ``indexsubitem'' macro to point to this module
% (alternatively, you can put this at the top of the file):
\setindexsubitem
{
(in module spam)
}
% ---- 3.2. ----
% For each function, use a ``funcdesc'' block. This has exactly two
% For each function, use a ``funcdesc'' block. This has exactly two
% parameters (each parameters is contained in a set of curly braces):
% parameters (each parameters is contained in a set of curly braces):
% the first parameter is the function name (this automatically
% the first parameter is the function name (this automatically
...
@@ -61,14 +64,14 @@ The \module{spam} module defines the following functions:
...
@@ -61,14 +64,14 @@ The \module{spam} module defines the following functions:
% least once in the description; each usage (even inside \code{...})
% least once in the description; each usage (even inside \code{...})
% should be enclosed in \var{...}.
% should be enclosed in \var{...}.
\begin{funcdesc}
{
open
}{
filename
\optional
{
, mode
, buffersize
}}
\begin{funcdesc}
{
open
}{
filename
\optional
{
, mode
\optional
{
, buffersize
}
}}
Open the file
\var
{
filename
}
as a can of Spam. The optional
Open the file
\var
{
filename
}
as a can of Spam. The optional
\var
{
mode
}
and
\var
{
buffersize
}
arguments specify the read-write mode
\var
{
mode
}
and
\var
{
buffersize
}
arguments specify the read-write mode
(
\code
{
'r'
}
(default) or
\code
{
'w'
}
) and the buffer size (default:
(
\code
{
'r'
}
(default) or
\code
{
'w'
}
) and the buffer size (default:
system dependent).
system dependent).
\end{funcdesc}
\end{funcdesc}
% ---- 3.
3
. ----
% ---- 3.
2
. ----
% Data items are described using a ``datadesc'' block. This has only
% Data items are described using a ``datadesc'' block. This has only
% one parameter: the item's name.
% one parameter: the item's name.
...
@@ -78,7 +81,7 @@ default varies per supermarket. This variable should not be changed
...
@@ -78,7 +81,7 @@ default varies per supermarket. This variable should not be changed
once the
\function
{
open()
}
function has been called.
once the
\function
{
open()
}
function has been called.
\end{datadesc}
\end{datadesc}
% --- 3.
4
. ---
% --- 3.
3
. ---
% Exceptions are described using a ``excdesc'' block. This has only
% Exceptions are described using a ``excdesc'' block. This has only
% one parameter: the exception name.
% one parameter: the exception name.
...
@@ -88,10 +91,19 @@ The exception argument is a string describing the reason of the
...
@@ -88,10 +91,19 @@ The exception argument is a string describing the reason of the
failure.
failure.
\end{excdesc}
\end{excdesc}
% ---- 3.5. ----
% ---- 3.4. ----
% There is no standard block type for classes. I generally use
% Other standard environments:
% ``funcdesc'' blocks, since class instantiation looks very much like
%
% a function call.
% classdesc - Python classes; same arguments are funcdesc
% methoddesc - methods, like funcdesc but has an optional parameter
% to give the type name: \begin{methoddesc}[mytype]{name}{args}
% By default, the type name will be the name of the
% last class defined using classdesc. The type name
% is required if the type is implemented in C (because
% there's no classdesc) or if the class isn't directly
% documented (if it's private).
% memberdesc - data members, like datadesc, but with an optional
% type name like methoddesc.
% ==== 4. ====
% ==== 4. ====
...
@@ -107,21 +119,22 @@ Example:
...
@@ -107,21 +119,22 @@ Example:
>>> can.empty()
>>> can.empty()
>>> can.close()
>>> can.close()
\end{verbatim}
\end{verbatim}
%
% Note that there is no trailing ">>> " prompt shown.
% ==== 5. ====
% ==== 5. ====
% If your module defines new object types (for a built-in module) or
% If your module defines new object types (for a built-in module) or
% classes (for a module written in Python), you should list the
% classes (for a module written in Python), you should list the
% methods and instance variables (if any) of each type or class in a
% methods and instance variables (if any) of each type or class in a
% separate subsection. It is important to redefine ``indexsubitem''
% separate subsection.
% for each subsection.
\subsection
{
Spam Objects
}
\subsection
{
Spam Objects
}
\label
{
spam-objects
}
% This label is generally useful for referencing this section, but is
% also used to give a filename when generating HTML.
Spam objects (returned by
\function
{
open()
}
above) have the following
Spam objects, as returned by
\function
{
open()
}
above, have the
methods.
following methods:
\setindexsubitem
{
(spam method)
}
\begin{
funcdesc}
{
empty
}{}
\begin{
methoddesc}
[spam]
{
empty
}{}
Empty the can into the trash.
Empty the can into the trash.
\end{
func
desc}
\end{
method
desc}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment