Data types are formatted like this: int
,
Point
, Path
. Plurals are formatted in the same way:
ints
, Points
, Paths
. It is poor
typographical practice to typeset a single word using more than one
font, e.g., int
s, Point
s, Path
s. This applies to
data types whose plurals do not end in "s" as well, e.g.,
the plural of the C++
class Polyhedron
is Polyhedra
.
When C++
functions are discussed in this manual, I always include a
pair
of parentheses to make it clear that the item in question is a function
and not a variable, but I generally do not
include the arguments. For example, if I mention the
function
foo()
, this doesn't imply that foo()
takes no
arguments. If it were appropriate, I would include the argument type:
foo(int)
or the argument type and a placeholder name:
foo(int arg)
or I would write
foo(void)
to indicate that foo()
takes no arguments. Also, I
generally don't indicate the return type, unless it is relevant. If it
is a member function
of a class, I may indicate this,
e.g.,, bar_class::foo()
, or not,
depending on whether this information is relevant. This convention
differs from that used in the Function Index, which is generated
automatically by Texinfo. There, only the name of the function appears,
without parentheses, parameters, or return values. The class type
of member functions may appear in the Function Index, (e.g.,
bar_class::foo
), but only in index entries that have been entered
explicitly by the author; such entries are not generated by Texinfo
automatically.
Examples are formatted as follows:
Point p0(1, 2, 3); Point p1(5, 6, 7.9); Path pa(p0, p1); p0.show("p0:"); -| p0: (1, 2, 3)
The beautiful mathematical typesetting produced by TeX unfortunately does not appear in the Info and HTML versions of this manual. In these, the following symbols are used to replace the proper mathematical symbols.
a^2
as
"a squared".
x_1
as
"x sub one".
x * y
as
"x times y".
sqrt(x)
as
"the square root of x".
In addition, examples can contain the following symbols:
This manual does not use all of the symbols provided by Texinfo. If you
find a symbol you don't understand in this manual (which shouldn't
happen), see page 103 of the Texinfo manual.
Symbols: