use API documentation style for the descriptions of the additional

functions made available in the post-installation script run by the
Windows installer
This commit is contained in:
Fred Drake 2004-02-19 22:28:15 +00:00
parent c54d9256fb
commit a9ee0da8f3

43
Doc/dist/dist.tex vendored
View file

@ -1462,27 +1462,23 @@ The installation script runs embedded in the windows installer, every
output (\code{sys.stdout}, \code{sys.stderr}) is redirected into a output (\code{sys.stdout}, \code{sys.stderr}) is redirected into a
buffer and will be displayed in the GUI after the script has finished. buffer and will be displayed in the GUI after the script has finished.
Some functions especially useful in this context are available in the Some functions especially useful in this context are available as
installation script. additional built-in functions in the installation script.
\begin{verbatim}
directory_created(pathname)
file_created(pathname)
\end{verbatim}
\begin{funcdesc}{directory_created}{path}
\funcline{file_created}{path}
These functions should be called when a directory or file is created These functions should be called when a directory or file is created
by the postinstall script at installation time. It will register the by the postinstall script at installation time. It will register
pathname with the uninstaller, so that it will be removed when the \var{path} with the uninstaller, so that it will be removed when the
distribution is uninstalled. To be safe, directories are only removed distribution is uninstalled. To be safe, directories are only removed
if they are empty. if they are empty.
\end{funcdesc}
\begin{verbatim} \begin{funcdesc}{get_special_folder_path}{csidl_string}
get_special_folder_path(csidl_string)
\end{verbatim}
This function can be used to retrieve special folder locations on This function can be used to retrieve special folder locations on
Windows like the Start Menu or the Desktop. It returns the full path Windows like the Start Menu or the Desktop. It returns the full
to the folder. 'csidl_string' must be one of the following strings: path to the folder. \var{csidl_string} must be one of the following
strings:
\begin{verbatim} \begin{verbatim}
"CSIDL_APPDATA" "CSIDL_APPDATA"
@ -1504,15 +1500,17 @@ to the folder. 'csidl_string' must be one of the following strings:
If the folder cannot be retrieved, \exception{OSError} is raised. If the folder cannot be retrieved, \exception{OSError} is raised.
Which folders are available depends on the exact Windows version, and probably Which folders are available depends on the exact Windows version,
also the configuration. For details refer to Microsoft's documentation of the and probably also the configuration. For details refer to
Microsoft's documentation of the
\cfunction{SHGetSpecialFolderPath()} function. \cfunction{SHGetSpecialFolderPath()} function.
\end{funcdesc}
\begin{verbatim} \begin{funcdesc}{create_shortcut}{target, description,
create_shortcut(target, description, filename[, arguments[, filename\optional{,
workdir[, iconpath[, iconindex]]]]) arguments\optional{,
\end{verbatim} workdir\optional{,
iconpath\optional{, iconindex}}}}}
This function creates a shortcut. This function creates a shortcut.
\var{target} is the path to the program to be started by the shortcut. \var{target} is the path to the program to be started by the shortcut.
\var{description} is the description of the sortcut. \var{description} is the description of the sortcut.
@ -1523,6 +1521,7 @@ This function creates a shortcut.
and \var{iconindex} is the index of the icon in the file and \var{iconindex} is the index of the icon in the file
\var{iconpath}. Again, for details consult the Microsoft \var{iconpath}. Again, for details consult the Microsoft
documentation for the \class{IShellLink} interface. documentation for the \class{IShellLink} interface.
\end{funcdesc}
\section{Registering with the Package Index} \section{Registering with the Package Index}
\label{package-index} \label{package-index}