changeset 102162:66c189a65c3d

(Lisp Data Types, Syntax for Strings, Buffer Type): Minor edits. (Frame Configuration Type): Emphasize that it is not primitive. (Font Type): New node. (Type Predicates): Add fontp; type-of now recognizes font object types.
author Chong Yidong <cyd@stupidchicken.com>
date Sat, 21 Feb 2009 13:45:20 +0000
parents 66a030d19217
children 47ff541effb4
files doc/lispref/objects.texi
diffstat 1 files changed, 48 insertions(+), 30 deletions(-) [+]
line wrap: on
line diff
--- a/doc/lispref/objects.texi	Sat Feb 21 13:45:00 2009 +0000
+++ b/doc/lispref/objects.texi	Sat Feb 21 13:45:20 2009 +0000
@@ -33,10 +33,10 @@
   Each primitive type has a corresponding Lisp function that checks
 whether an object is a member of that type.
 
-  Note that Lisp is unlike many other languages in that Lisp objects are
-@dfn{self-typing}: the primitive type of the object is implicit in the
-object itself.  For example, if an object is a vector, nothing can treat
-it as a number; Lisp knows it is a vector, not a number.
+  Lisp is unlike many other languages in that its objects are
+@dfn{self-typing}: the primitive type of each object is implicit in
+the object itself.  For example, if an object is a vector, nothing can
+treat it as a number; Lisp knows it is a vector, not a number.
 
   In most languages, the programmer must declare the data type of each
 variable, and the type is known by the compiler but not represented in
@@ -987,12 +987,13 @@
 @cindex double-quote in strings
 @cindex @samp{\} in strings
 @cindex backslash in strings
-  The read syntax for strings is a double-quote, an arbitrary number of
-characters, and another double-quote, @code{"like this"}.  To include a
-double-quote in a string, precede it with a backslash; thus, @code{"\""}
-is a string containing just a single double-quote character.  Likewise,
-you can include a backslash by preceding it with another backslash, like
-this: @code{"this \\ is a single embedded backslash"}.
+  The read syntax for a string is a double-quote, an arbitrary number
+of characters, and another double-quote, @code{"like this"}.  To
+include a double-quote in a string, precede it with a backslash; thus,
+@code{"\""} is a string containing just a single double-quote
+character.  Likewise, you can include a backslash by preceding it with
+another backslash, like this: @code{"this \\ is a single embedded
+backslash"}.
 
 @cindex newline in strings
   The newline character is not special in the read syntax for strings;
@@ -1355,6 +1356,7 @@
 * Stream Type::         Receive or send characters.
 * Keymap Type::         What function a keystroke invokes.
 * Overlay Type::        How an overlay is represented.
+* Font Type::           Fonts for displaying text.
 @end menu
 
 @node Buffer Type
@@ -1364,23 +1366,23 @@
 (@pxref{Buffers}).  Most buffers hold the contents of a disk file
 (@pxref{Files}) so they can be edited, but some are used for other
 purposes.  Most buffers are also meant to be seen by the user, and
-therefore displayed, at some time, in a window (@pxref{Windows}).  But a
-buffer need not be displayed in any window.
+therefore displayed, at some time, in a window (@pxref{Windows}).  But
+a buffer need not be displayed in any window.  Each buffer has a
+designated position called @dfn{point} (@pxref{Positions}); most
+editing commands act on the contents of the current buffer in the
+neighborhood of point.  At any time, one buffer is the @dfn{current
+buffer}.
 
   The contents of a buffer are much like a string, but buffers are not
 used like strings in Emacs Lisp, and the available operations are
 different.  For example, you can insert text efficiently into an
 existing buffer, altering the buffer's contents, whereas ``inserting''
-text into a string requires concatenating substrings, and the result is
-an entirely new string object.
+text into a string requires concatenating substrings, and the result
+is an entirely new string object.
 
-  Each buffer has a designated position called @dfn{point}
-(@pxref{Positions}).  At any time, one buffer is the @dfn{current
-buffer}.  Most editing commands act on the contents of the current
-buffer in the neighborhood of point.  Many of the standard Emacs
-functions manipulate or test the characters in the current buffer; a
-whole chapter in this manual is devoted to describing these functions
-(@pxref{Text}).
+  Many of the standard Emacs functions manipulate or test the
+characters in the current buffer; a whole chapter in this manual is
+devoted to describing these functions (@pxref{Text}).
 
   Several other data structures are associated with each buffer:
 
@@ -1531,10 +1533,11 @@
 @cindex window layout, all frames
 
   A @dfn{frame configuration} stores information about the positions,
-sizes, and contents of the windows in all frames.  It is actually
-a list whose @sc{car} is @code{frame-configuration} and whose
-@sc{cdr} is an alist.  Each alist element describes one frame,
-which appears as the @sc{car} of that element.
+sizes, and contents of the windows in all frames.  It is not a
+primitive type---it is actually a list whose @sc{car} is
+@code{frame-configuration} and whose @sc{cdr} is an alist.  Each alist
+element describes one frame, which appears as the @sc{car} of that
+element.
 
   @xref{Frame Configurations}, for a description of several functions
 related to frame configurations.
@@ -1613,6 +1616,17 @@
 
   @xref{Overlays}, for how to create and use overlays.
 
+@node Font Type
+@subsection Font Type
+
+  A @dfn{font} specifies how to display text on a graphical terminal.
+There are actually three separate font types---@dfn{font objects},
+@dfn{font specs}, and @dfn{font entities}---each of which has slightly
+different properties.  None of them have a read syntax; their print
+syntax looks like @samp{#<font-object>}, @samp{#<font-spec>}, and
+@samp{#<font-entity>} respectively.  @xref{Low-Level Font}, for a
+description of these Lisp objects.
+
 @node Circular Objects
 @section Read Syntax for Circular Objects
 @cindex circular structure, read syntax
@@ -1769,6 +1783,9 @@
 @item floatp
 @xref{Predicates on Numbers, floatp}.
 
+@item fontp
+@xref{Low-Level Font}.
+
 @item frame-configuration-p
 @xref{Frame Configurations, frame-configuration-p}.
 
@@ -1866,11 +1883,12 @@
 
 @defun type-of object
 This function returns a symbol naming the primitive type of
-@var{object}.  The value is one of the symbols @code{symbol},
-@code{integer}, @code{float}, @code{string}, @code{cons}, @code{vector},
-@code{char-table}, @code{bool-vector}, @code{hash-table}, @code{subr},
-@code{compiled-function}, @code{marker}, @code{overlay}, @code{window},
-@code{buffer}, @code{frame}, @code{process}, or
+@var{object}.  The value is one of the symbols @code{bool-vector},
+@code{buffer}, @code{char-table}, @code{compiled-function},
+@code{cons}, @code{float}, @code{font-entity}, @code{font-object},
+@code{font-spec}, @code{frame}, @code{hash-table}, @code{integer},
+@code{marker}, @code{overlay}, @code{process}, @code{string},
+@code{subr}, @code{symbol}, @code{vector}, @code{window}, or
 @code{window-configuration}.
 
 @example