summaryrefslogtreecommitdiffstats
path: root/Doc/libfm.tex
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1994-01-02 01:22:07 (GMT)
committerGuido van Rossum <guido@python.org>1994-01-02 01:22:07 (GMT)
commit5fdeeeae2a12b9956cc84d62eae82f72cabc8664 (patch)
treeac0053479e10099850c8e0d06e31cb3afbf632bb /Doc/libfm.tex
parent0b0719866e8a32d0a787e73bca9e79df1d1a74f8 (diff)
downloadcpython-5fdeeeae2a12b9956cc84d62eae82f72cabc8664.zip
cpython-5fdeeeae2a12b9956cc84d62eae82f72cabc8664.tar.gz
cpython-5fdeeeae2a12b9956cc84d62eae82f72cabc8664.tar.bz2
Restructured library documentation
Diffstat (limited to 'Doc/libfm.tex')
-rw-r--r--Doc/libfm.tex86
1 files changed, 86 insertions, 0 deletions
diff --git a/Doc/libfm.tex b/Doc/libfm.tex
new file mode 100644
index 0000000..acbc05d
--- /dev/null
+++ b/Doc/libfm.tex
@@ -0,0 +1,86 @@
+\section{Built-in Module \sectcode{fm}}
+\bimodindex{fm}
+
+This module provides access to the IRIS {\em Font Manager} library.
+It is available only on Silicon Graphics machines.
+See also: 4Sight User's Guide, Section 1, Chapter 5: Using the IRIS
+Font Manager.
+
+This is not yet a full interface to the IRIS Font Manager.
+Among the unsupported features are: matrix operations; cache
+operations; character operations (use string operations instead); some
+details of font info; individual glyph metrics; and printer matching.
+
+It supports the following operations:
+
+\renewcommand{\indexsubitem}{(in module fm)}
+\begin{funcdesc}{init}{}
+Initialization function.
+Calls \code{fminit()}.
+It is normally not necessary to call this function, since it is called
+automatically the first time the \code{fm} module is imported.
+\end{funcdesc}
+
+\begin{funcdesc}{findfont}{fontname}
+Return a font handle object.
+Calls \code{fmfindfont(\var{fontname})}.
+\end{funcdesc}
+
+\begin{funcdesc}{enumerate}{}
+Returns a list of available font names.
+This is an interface to \code{fmenumerate()}.
+\end{funcdesc}
+
+\begin{funcdesc}{prstr}{string}
+Render a string using the current font (see the \code{setfont()} font
+handle method below).
+Calls \code{fmprstr(\var{string})}.
+\end{funcdesc}
+
+\begin{funcdesc}{setpath}{string}
+Sets the font search path.
+Calls \code{fmsetpath(string)}.
+(XXX Does not work!?!)
+\end{funcdesc}
+
+\begin{funcdesc}{fontpath}{}
+Returns the current font search path.
+\end{funcdesc}
+
+Font handle objects support the following operations:
+
+\renewcommand{\indexsubitem}{(font handle method)}
+\begin{funcdesc}{scalefont}{factor}
+Returns a handle for a scaled version of this font.
+Calls \code{fmscalefont(\var{fh}, \var{factor})}.
+\end{funcdesc}
+
+\begin{funcdesc}{setfont}{}
+Makes this font the current font.
+Note: the effect is undone silently when the font handle object is
+deleted.
+Calls \code{fmsetfont(\var{fh})}.
+\end{funcdesc}
+
+\begin{funcdesc}{getfontname}{}
+Returns this font's name.
+Calls \code{fmgetfontname(\var{fh})}.
+\end{funcdesc}
+
+\begin{funcdesc}{getcomment}{}
+Returns the comment string associated with this font.
+Raises an exception if there is none.
+Calls \code{fmgetcomment(\var{fh})}.
+\end{funcdesc}
+
+\begin{funcdesc}{getfontinfo}{}
+Returns a tuple giving some pertinent data about this font.
+This is an interface to \code{fmgetfontinfo()}.
+The returned tuple contains the following numbers:
+\code{(\var{printermatched}, \var{fixed_width}, \var{xorig}, \var{yorig}, \var{xsize}, \var{ysize}, \var{height}, \var{nglyphs})}.
+\end{funcdesc}
+
+\begin{funcdesc}{getstrwidth}{string}
+Returns the width, in pixels, of the string when drawn in this font.
+Calls \code{fmgetstrwidth(\var{fh}, \var{string})}.
+\end{funcdesc}