CEDAR DOCUMENT STYLE (Mark property value: centerHeader)
CEDAR VERSION# (Mark property value: centerFooter)
Cedar Document Style  title node
A Sample Sheet  subtitle node
Release as [Indigo]<Cedar>Documentation>SampleSheet.tioga, .press
Came from
 [Indigo]<CedarDocs>Manual>SampleSheet.tioga, .press
Last edited By Horning on December 17, 1982 12:11 pm
 by Beach, June 6, 1983 11:37 am
Abstract: This sampler is intended to show "some of everything" from the standard Cedar.style for use with Tioga. It should serve as a reminder of the formats and looks available for preparing uniformly formatted Cedar programs, documentation, and memoranda. It also contains itemized lists of the formats and looks. Mostly, though, the contents are a jumble, words collected to add versimilitude to an otherwise bald and unconvincing assemblage
XEROX   Xerox Corporation — boilerplate node
    Palo Alto Research Center
    3333 Coyote Hill Road
    Palo Alto, California 94304

DRAFT — For Internal Xerox Use Only — DRAFT
Contents  contents nodes, begins new page
Node Format Sampler
Formats
Programs, Prose
Looks
Programs
Text
Prose, References, Poetry
Forms
Memo
Node Format Sampler  This is a head Node, begins a new page
This is a body node, nested under the head node (actually, in the branch that it heads). Note that nesting is displayed on the screen by a small indent which is not reflected in the hardcopy form.
Some people find that this indentation helps them to keep track of the nesting structure of their documents. If, on the other hand, you find it more distracting than helpful, you should change the ScreenRule for Nest in Cedar.style to be the same as the PrintRule. Some node formats cause indentation that is independent of nesting. This indentation is larger than the indentation that indicates nesting. This note node illustrates the difference. It is not nested in the body node above.
However, this note node is nested in the note above it, and hence gets the sum of the two relative indentations.
This is a nested head node
This is a body node, nested in the head node. This is a body node, nested in the head node. This is a body node, nested in the head node. This is a body node, nested in the head node.
This is a block node, also nested in the head node.
This is an indent node, also nested in the head node.
This indent node is nested in the previous one (hence indented relative to it).
This is a quote node. It is nested in the head node, not the indent node.
And this is a center node, nested in the head node.
This is a head node, also nested in the head node
This is a body node, nested in the head, with an embedded program fragment.
Sample: CEDAR PROGRAM  -- This is an example node
IMPORTS Something  -- Online comment in a code node
EXPORTS Another
= { IF a < b THEN a ← b }.
This is a continuation node, nested under the body node with the embedded program fragment.
This is an item node. Item nodes are typically nested in other nodes, and contain the elements of displayed lists (note the hanging indent).
This is another item node.
This lead2 node is set with more leading, which leaves more space between lines, e.g., to accomodate LARGE TYPE. The choices are lead1, lead2, and lead3.
This is a
table node. Only
simple tabs are available.
A table1  node has
smaller tabs for more columns.
A table2 node has even
smaller tabs for still more.
While a table3 node has yet
smaller tabs for lots of columns.
This is a pageBreak node. (Contents are appropriate only if they are to appear at the very bottom of the page. Not needed before first level head nodes.)
Node Formats
Much of the control of the format of a document can be handled consistently by associating "formats" with nodes of the document. The set of formats selected for Cedar is intended to cover the common kinds of textual units in documentation, memos, and programs. It is best to pick a small subset of them for any particular document.
Formats for use in programs
Format code is intended for program statements that do not require special spacing. Nesting is reflected by indentation.
Format unit is intended for program statements that start a new logical unit, and hence should have some extra space in front.
Formats for use in prose
Format block is intended for block-style paragraphs.
Format body is intended for ordinary paragraphs with the first line indented.
Format center is intended for centered paragraphs.
Format contents is intended for headings in tables of contents. The same type fonts are used as for head, but with less leading, and with indentation corresponding to nesting structure.
Format continuation is intended for nodes that logically "continue" previous nodes (e.g., following an example or an itemized list), and hence should not have extra leading at the beginning.
Format display is intended for displayed equations, etc. embedded in text paragraphs.
Format example is intended for things like program statements included within explanatory text, and gets extra indentation to set it off.
Format head is a "generic" format for headings that will expand to one of head1, . . ., head5, as a function of the level of nesting. If it is used in place of the more specific head formats, heading nodes can be copied, levels can be added or removed, etc., with minimum effort.
Format indent is intended for paragraphs that are to be indented (relative to the containing node). In the usual case, this is a head, rather than the preceding body node, although the difference is not visible on the hardcopy.
Format item is intended for elements of an itemized list (like this one). Items are indented relative to their containing node, and continuation lines are further indented.
Formats lead1, lead2, and lead3 are like body, except that they have progressively more inter-line leading, which can be useful for paragraphs with larger format, superscripts, etc.
Format logo is intended for the Xerox logo line at the start of a document. It does more than just set the font to Logo24, it provides extra space before and after, extends into left margin, etc.
Format memoHead is intended for the heading lines at the start of memos.
Format note is intended for fine points. Someday we will have real footnotes.
Format pageBreak is intended to force a new page. It shouldn't have contentunless you want it at the very bottom of the page.
Format quote is intended for displayed quotations.
Format reference is intended for items in reference lists [van Leunen 1978].
Format table is intended for tables with widely-spaced columns.
Formats table1, table2, and table3 provide successively smaller tab stops to accomodate more columns.
Format title is intended for titles, typically at the start of a document.
Format subtitle uses a slightly smaller font, and can be used under a title.
Looks
It is good practice to use the "abstract" (or "intentional") looks wherever possible (e.g., Annotation, rather than Bold, Emphasis, rather than Italic, Keyword, rather than Smaller). This will make it possible to produce other versions of the document where different decisions have been made about the appropriate way to display some abstract property. Also, it is better to avoid looks entirely, if the information can be captured in the format of the containing node (none of the headings in this document have Bold looks).
Looks a b c d e f g h i j k l % n o p q r s t u v w x y z.
look.a  annotation font
look.b  bold font
look.c  Cedar comments
look.d  down for subscriptlower (not yet visible on screen) and a smaller font
look.e  emphasis
look.f  fixed-pitch fontGacha
look.g  GreekHippo
look.hhidden by asterisks (unfortunately prints normally)
look.iitalic
look.k  Cedar KEYWORDS
look.l  larger font
Ð.m  Math font
look.n  Cedar procedure names
look.o  other fontHelvetica
look.pplain font and regular sizeoverrides node format
look.qquaint XEROX logo—for boilerplate format
look.rregular faceoverrides node format
look.s  smaller font
look.tTioga font
look.u  up, for superscripthigher (not yet visible on screen) and a smaller font
look.x  extra large
look.y  yarbitrary for strikeout
look.z  zarbitrary for underlined
Look.s Format block. Mohammed (also Mahomet, Muhammad; 570?-632) asserted a doctrine of unqualified monotheism (suras 8, 22, 33-37, 89, 91, Koran).
Look.l Format lead1. Scholarly writing is formal, accurate, and allusive. It has to be. It does not have to be wooden, finicking, and cabalistic. The idea of this book is to help you achieve the first set of characteristics without sinking into the second.
Look.x Format lead2. "There is no God but Allah."
Of course, a variety of looks can be mixed in a single paragraph, although the appearance of the result is often somewhat less than pleasing. Ai Bj
Programs
Cedar Comment Standing on its own as a unit node
File: SimpleExample.mesa     (note 1.1)
Last edited by: Cattell on May 12, 1982 3:05 pm
DIRECTORY
IOStream, Process, Rope, UserExec;
SimpleExample: MONITOR     --(note 1.2)
IMPORTS IO: IOStream, Process, R: Rope, UserExec =   --(note 1.3)
BEGIN
ROPE: TYPE = R.ROPE    --(note 1.8)
windowCount: INT ← 0; -- a count of the number of calculators on the screen
ReverseName: UserExec.CommandProc = BEGIN  --(note 1.4)
Reverses the user's login name and prints it out in the exec window.
userName: ROPE ← UserExec.GetNameAndPassword[ ].name; --(note 1.5)
execStream: IOStream.Handle ← exec.out; -- exec was passed as arg to this proc (note 1.6)
backwordsName: ROPENIL;
Remove ".PA" if it is on the end of the user name, and check for user name Taylor.
dotPos: INT ← userName.Find["."];   --(note 1.7)
IF dotPos#-1 THEN
userName ← userName.Substr[0, dotPos];
IF userName.Equal[s2: "Taylor", case: FALSE] THEN
execStream.PutF["Hi, Bob\n"];
Now reverse the name: convert chars to upper cases and concatenate them in reverse order
FOR i: INT DECREASING IN [0..userName.Length[ ]) DO
backwordsName ← backwordsName.Cat[R.FromChar[R.Upper[userName.Fetch[i]]]]
     --[1.1] (note 1.9)
ENDLOOP;
execStream.PutF["Your user name backwards is: %g\n", IO.rope[backwordsName]];
     --(note 1.13)
END;
Start code registers a Calculate and ReverseName command, which must be invoked for this program to do anything:
UserExec.RegisterCommand[    --(note 1.17)
name: "Calculate", proc: MakeCalculator, briefDoc: "A simple adding machine"];
UserExec.RegisterCommand[
name: "ReverseName", proc: ReverseName, briefDoc: "Reverses your user name"];
END.
CHANGE LOG      --(note 1.18)
Created by Cattell on 21-Apr-82 13:55:09
Changed by Cattell on May 25, 1982 10:58 am
added use of RegisterCommand to fire up a Calculator viewer instead of creating it when program first run.
Text
Prose
Scholarly writing is formal, accurate, and allusive. It has to be. It does not have to be wooden, finicking, and cabalistic. The idea of this book is to help you achieve the first set of characteristics without sinking into the second.
Let us not deceive ourselves. "There is no God but Allah" is a more gripping sentence than
Mohammed (also Mahomet, Muhammad; 570?-632) asserted a doctrine of unqualified monotheism (suras 8, 22, 33-37, 89, 91, Koran).
By its very nature, scholarly prose lacks the rhetorical virtues of reckless passion. Custom and propriety hem the scholar in on every side. His obligation to his material and his obligation to his sources restrain him. He may not gloss over imperfections, smooth out irregularities, turn a blind eye to objections, no matter what good effects these temptations might offer in the way of clarity and simplicity.
On the other hand, the built-in limitations of scholarly prose are no excuse for bad writing. Bad scholarly prose results, as all bad prose does, from laziness and hurry and muddle. Good scholarly prose is probably even harder to produce than other kinds of good prose. All that means is that the scholar must work even harder at it. [van Leunen 1978]
References
[Carroll 1865]
Lewis Carroll
Alice's Adventures in Wonderland

Washington Square Press edition, 1960
[Knuth 1968]
Donald E. Knuth
The Art of Computer Programming, vol. 1
Addison-Wesley
[van Leunen 1978]
Mary-Claire van Leunen
A Handbook for Scholars
Knopf
Poetry  The Mouse's Tale
Fury said to
a mouse, That
he met in the
house, Let
us both go
to law: I
will prose-
cute you.
come, I'll
take no de-
nial: We
must have
the trial;

For really
this morn-
ing I've
nothing
to do.'
Said the
mouse to
the cur,
Such a
trial, dear
sir, With
no jury
or judge
would
be wast-
ing our
breath.'
I'll be
judge,
I'll be
jury,
said
cun-
ning
old
Fury:
I' ll
try the
whole
cause
and
con-
demn
death.' you to
[Carroll 1865]
Inter-Office Memorandum
To Recipients  DateCTRL-T
From Your name  Location PARC/CSL
Subject Topic  FileFile Name
head Node, repeat as needed, nest for subheads if appropriate
body node, repeat as needed
 Computing Sciences Laboratory
 Xerox Corporation
 Palo Alto Research Center
 Palo Alto, California 94304
 415 494-4000
Destination Address Field
Dear Name Field
File: BusinessLetter.form This form is designed to match the current PARC letterhead. It is organized as a set of Tioga fields to be filled in. To use it, select the XEROX logo node above and use the NEXT key to select the first field to be replaced, the Destination Address Field (the NEXT key is the blank key second from the bottom on the right side of the keyboard). This is a body paragraph node and may be replaced by selecting it as a field and then simply typing

    Sincerely,



    Your Name Field
CSL Notebook Entry
To Recipients  DateCTRL-T
From Your name  Location PARC/CSL
Subject Topic  FileFile Name
Release as TargetFileName
Draft
 WorkingFileName (this form is on [Indigo]<CedarDocs>Style>Memo.form)
Last editedby Person (this form was last edited by Rick Beach, June 6, 1983 11:31 am)
Abstract A pithy descriptive paragraph, if appropriate
head Node, repeat as needed, nest for subheads if appropriate
body node, repeat as needed