\begindata{lset,270506880}
\V 1
\begindata{lset,270506648}
\V 1
\begindata{lset,270506444}
\V 1
\begindata{cel,270506304}
\V 2
\begindata{text,270506184}
\textdsversion{12}
\template{default}


	\bold{Empower} the Ness in the bottom panel, 

	\bold{click} on a word in this panel, 

	and \bold{see} the definition in the middle panel.\
\enddata{text,270506184}
0 270506184 0 0 0 0 
>OBJ< text
>VIEW< textview
>REF< instructions
\enddata{cel,270506304}
0 0 0 270506304 0 0 0
>OBJ< cel
>VIEW< celview
>REF< 
\enddata{lset,270506444}
\begindata{lset,270537484}
\V 1
\begindata{cel,270537344}
\V 2
\begindata{text,270537224}
\textdsversion{12}
\template{default}



	\bigger{The definition will appear here.\
}
\begindata{bp,537558784}
\enddata{bp,537558784}
\view{bpv,537558784,1097,0,0}
Copyright 1992 Carnegie Mellon University and IBM.  All rights reserved.

\smaller{\smaller{$Disclaimer: 
# Permission to use, copy, modify, and distribute this software and its 
# documentation for any purpose is hereby granted without fee, 
# provided that the above copyright notice appear in all copies and that 
# both that copyright notice, this permission notice, and the following 
# disclaimer appear in supporting documentation, and that the names of 
# IBM, Carnegie Mellon University, and other copyright holders, not be 
# used in advertising or publicity pertaining to distribution of the software 
# without specific, written prior permission.
# 
# IBM, CARNEGIE MELLON UNIVERSITY, AND THE OTHER COPYRIGHT HOLDERS 
# DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING 
# ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS.  IN NO EVENT 
# SHALL IBM, CARNEGIE MELLON UNIVERSITY, OR ANY OTHER COPYRIGHT HOLDER 
# BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY 
# DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, 
# WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS 
# ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 
# OF THIS SOFTWARE.
#  $

}}
\enddata{text,270537224}
1 270537224 0 0 0 0 
>OBJ< text
>VIEW< textview
>REF< definition
\enddata{cel,270537344}
0 0 0 270537344 0 0 0
>OBJ< cel
>VIEW< celview
>REF< 
\enddata{lset,270537484}
2 69 0 0 270506444 270537484 0
>OBJ< 
>VIEW< 
>REF< 
\enddata{lset,270506648}
\begindata{lset,270527844}
\V 1
\begindata{cel,270527704}
\V 2
\begindata{ness,270527436}
\origin{01\\8 Apr 1992 at 23:00:55 EDT\\wjh:  Fred Hansen\\00}
\template{default}
\define{global
}
\define{symbola
menu:[Font~1,SymbolA~86]
attr:[FontFamily symbola Int 0]}
\define{symbol
menu:[Font~1,Symbol~84]
attr:[FontFamily symbol Int 0]}
\define{realsmall
menu:[Font~1,RealSmall~88]
attr:[Script PreviousScriptMovement Point -4]
attr:[FontSize PreviousFontSize Point -4]}
\define{helv
menu:[Font~1,Sans Serif~82]
attr:[FontFamily AndySans Int 0]}
\define{definition
menu:[Region~4,Definition~85]
attr:[LeftMargin LeftMargin Cm 138717]
attr:[RightMargin RightMargin Cm 138717]
attr:[FontSize PreviousFontSize Point -2]}
-- dict.n 


-- In practice this code is used at CMU with the full American Heritage 
Dictionary.  

-- Only a small subset is distributed here.  


-- Note how easily Ness code can include styled text and generate text 
containing copies of that styled text.



marker definitions :=

//

$a:  $A:  $a's:  $A's:  

<ME><LM><GR><MU>a<MR>A<BP>(<LA>)<EP><PS>n.,<PL>a's <RM>or <BD>A's.<NA>1<NB>The 
first letter of the modern English alphabet.<NA>2<NB>Any of the speech sounds 
represented by the letter <IT>a.<NA>3<NB>Something shaped like the letter 
A.<NA>4<NB>The first in a series.<NA>5<NB>The best or highest in quality or 
rank: <IT>grade A milk.<NA>6. a<NB>The sixth tone in the scale of C major or 
the first note in the relative minor scale.<NA>b<NB>The key or scale in which 
A is the tonic.<NA>c<NB>A written or printed note representing this 
tone.<NA>d<NB>A string, key, or pipe tuned to the pitch of this tone.

$and:  

<ME>and<BP>(<SW>nd, <SW>n; <RM><AA>nd <IT>when 
stressed)<EP><PS>conj.<NA>1<NB>Together with or along with; also; in addition; 
as well as. Used to connect words, phrases, or clauses that have the same 
grammatical function in a construction. <NA>2<NB>Added to; plus: <IT>Two and 
two makes four.<NA>3<NB>As a result; in consequence: <IT>Seek, and ye shall 
find.<NA>4<NB><IT>Informal. <RM>To. Used between finite verbs, such as <IT>go, 
come, try, write, <RM>or <IT>see: try and find it; come and 
see.<NA>5<NB><IT>Archaic. <RM>Then. Used to begin a sentence: <IT>And he said 
unto her . . .<NA>6<NB><IT>Archaic. <RM>If: <IT>and it pleases you.<EY>ME <LS> 
OE.<EN><UN>Although frowned upon by some, the use of <IT>and <RM>to begin a 
sentence has a long and respectable history: <IT>""And it came to pass in 
those days'' <RM>(Luke 2:1).

$bottom:  $bottoms:  $-tomed, -tomtomed:  $-tomed, -tomtoming:  $-tomed, 
-tomtoms:  $bottom out:  $at bottom:  $bottomer:  $bottomers:  

<ME><EC><GG><NT>bot<MM>tom<BP>(b<AO>t<LL><SW>m)<EP><PS>n.<NA>1<NB>The lowest 
or deepest part of something.<NA>2<NB>The underside.<NA>3<NB>The supporting 
part of something; foundation.<NA>4<NB>The basic quality underlying something; 
essence.<NA>5<NB>The solid surface under a body of water.<NA>6<NB>Often 
<BD>bottoms. <RM>Low<BH>lying alluvial land adjacent to a river; 
bottomland.<NA>7<NB>The part of a ship's hull below the water line.<NA>8<NB>A 
ship.<NA>9<NB>Often <BD>bottoms. <RM>The trousers of 
pajamas.<NA>10<NB><IT>Informal. <RM>The buttocks.<NA>11<NB>The seat of a 
chair.<NA>12<NB>Staying power, as of a horse; stamina.<RO><BI>modifier: 
<IT>the bottom drawer.<PT>v.<IF>-tomed, -tom<MM>ing, -toms.<PT>tr.<NA>1<NB>To 
provide with an underside or foundation.<NA>2<NB>To establish; 
found.<NA>3<NB>To grasp the meaning of; fathom.<PT>intr.<NA>1<NB>To be or 
become based or grounded.<NA>2<NB>To rest on or touch the 
bottom.<RO><BI>phrasal verb. <BD>bottom out.<DF>To descend, as securities, to 
the lowest point possible, after which only a rise may occur.<RO><BI>idiom. 
<BD>at bottom. <RM>Basically.<EY>ME <IT>botme <RM><LS> OE 
<IT>botm.<EN><RO>bot<LL>tom<MM>er<PS>n.

$click:  $clicked:  $clicking:  $clicks:  $clicker:  $clickers:  

<NR><LM><PH>click<BP>(kl<AI>k)<EP><PS>n.<NA>1<NB>A brief, sharp, nonresonant 
sound: <IT>the click of a door latch.<NA>2<NB>A mechanical device, such as a 
detent, that snaps into position.<NA>3<NB>An implosive speech sound, common in 
some African languages, produced by drawing air into the mouth and clicking 
the tongue.<PT>v.<IF>clicked, click<MM>ing, clicks.<PT>intr.<NA>1<NB>To 
produce a click or series of clicks.<NA>2<NB><IT>Slang.<NA>a<NB>To become a 
success.<NA>b<NB>To function well together.<PT>tr.<DF>To cause to 
click.<EY>Imit.<EN><RO>click<LL>er<PS>n.

$definition:  $definitions:  $definitional:  

<ME><LM><PH>def<MM>i<MM>ni<MM>tion<BP>(d<AE>f<LP><SW>-n<AI>sh<LL><SW>n)<EP><PS>\
n.<NA>1<NB>The act of stating a precise meaning or significance.<NA>2<NB>The 
statement of the meaning of a word, phrase, or term.<NA>3<NB>The act of making 
clear and distinct: <IT>a definition of one's intentions.<NA>4<NB>The state of 
being closely outlined or determined.<NA>5<NB>A determination of outline, 
extent, or limits: <IT>the definition of a nation's authority.<NA>6<NB>The 
degree of clarity with which a televised image is received or a radio receives 
a given station.<NA>7<NB>The clarity of detail in an optically produced image, 
as a photograph, effected by a combination of resolution and contrast.<EY>ME 
<IT>diffinicioun <RM><LS> OFr. <IT>definition <RM><LS> Lat. <IT>definitio 
<RM><LS> <IT>definire, <RM>to 
define.<EN><RO>def<LP>i<MM>ni<LL>tion<MM>al<PS>adj.

$Empower:  $empowered:  $empowering:  $empowers:  

<ME><LW>em<MM>pow<MM>er<BP>(<AE>m-pou<LL><SW>r)<EP><PS>tr.v.<IF>-ered, 
-er<MM>ing, -ers.<DF>To invest with legal power; authorize.

$in:  $ins:  $in for:  $ins and outs:  $in that:  

<ME>in<BP>(<AI>n)<EP><PS>prep.<NA>1. a<NB>Within the limits, bounds, or area 
of: <IT>was hit in the face; in the spring; in the garden.<NA>b<NB>From the 
outside to a point within; into: <IT>threw the letter in the garbage 
can.<NA>2<NB>To or at a situation or condition of: <IT>was split in two; in 
debt; in love.<NA>3. a<NB>Having the activity, occupation, or function of: 
<IT>in politics; in command.<NA>b<NB>During the act or process of: <IT>tripped 
in racing for the bus.<NA>4. a<NB>With the arrangement or order of: <IT>fell 
in luxuriant folds; in equal payments.<NA>b<NB>After the style or form of: 
<IT>in iambic pentameter.<NA>5. a<NB>With the characteristic, attribute, or 
property of: <IT>a tall man in an afro.<NA>b<NB>Used to indicate a material or 
element from which something is made: <IT>a statue in bronze.<NA>6<NB>With the 
aim or purpose of: <IT>went in search of a dictionary.<NA>7<NB>By the 
instrumentality or means of: <IT>paneled the library in walnut.<NA>8<NB>With 
reference to: <IT>six inches in depth. ...

$middle:  $Middle:  $middled:  $middling:  $middles:  

<CE><GL><LM><GR>mid<MM>dle<BP>(m<AI>d<LL>l)<EP><PS>adj.<NA>1<NB>Equally 
distant from extremes or limits; central: <IT>the middle point on a 
line.<NA>2<NB>Being at neither one extreme nor the other; intermediate.<NA>3. 
a<NB>Intervening between an earlier and a later period of time; part of a 
sequence or series: <IT>the middle years.<NA>b<NB><BD>Middle. <IT>Geol. 
<RM>Designating a division between an earlier and a later division: <IT>the 
Middle Paleozoic.<NA>4<NB><BD>Middle. <RM>Designating a stage in the 
development of a language or literature between earlier and later stages: 
<IT>Middle English.<NA>5<NB><IT>Logic. <RM>Designating a term that appears in 
both premises of a syllogism but not in the conclusion.<NA>6<NB><IT>Gram. 
<RM>Of a verb form or voice in which the subject both performs and is affected 
by the action specified.<PT>n.<NA>1<NB>An area or point equidistant between 
extremes; center: <IT>the middle of a circle.<NA>2<NB>Something intermediate 
between extremes; mean.<NA>3<NB>The interior portion: <IT>the middle of the 
chain.<NA>4<NB>The middle part of the human body; waist.<NA>5<NB><IT>Logic. 
<RM>A <CR>middle term<CS>.<PT>tr.v.<IF>-dled, -dling, -dles.<NA>1<NB>To place 
in the middle.<NA>2<NB><IT>Naut. <RM>To fold in the middle: <IT>middle the 
sail.<EY>ME <IT>middel <RM><LS> OE.<EN>

$Ness:  $nesses:  

<ME>ness<BP>(n<AE>s)<EP><PS>n.<DF>A cape or headland.<EY>ME <IT>nasse <RM><LS> 
OE <IT>naessa.<EN>

$on:  $and so on:  $be on to:  $on and off:  $on and on:  

<ME>on<BP>(<AO>n, <TO>n)<EP><PS>prep.<NA>1<NB>Used to 
indicate:<NA>a<NB>Position above and in contact with: <IT>The vase is on the 
table.<NA>b<NB>Contact with any surface, regardless of position: <IT>a picture 
on the wall.<NA>c<NB>Location at or along: <IT>a house on the 
beach.<NA>d<NB>Proximity: <IT>a town on the border.<NA>e<NB>Attachment to or 
suspension from: <IT>beads on a string.<NA>2<NB>Used to 
indicate:<NA>a<NB>Motion or direction toward a position: <IT>He threw the 
books on the floor.<NA>b<NB>Motion toward, against, or onto: <IT>jump on the 
table; the march on Washington.<NA>3<NB>Used to indicate:<NA>a<NB>Occurrence 
at a given time: <IT>on July third.<NA>b<NB>The particular occasion or 
circumstance: <IT>On entering the room, she saw him.<NA>c<NB>The exact moment 
or point of: <IT>on the hour.<NA>4<NB>Used to indicate:<NA>a<NB>The object 
affected by actual, perceptible action: <IT>The spotlight fell on the 
actress.<NA>b<NB>The agent or agency of a specified action: <IT>cut his foot 
on the broken glass; talked on the telephone.<NA>c<NB>The object affected by a 
figurative action: <IT>Have pity on them.<NA>d<NB>The object of an action 
directed, tending, or moving against it: <IT>an attack on the fortress. ...

$panel:  $paneled:  $paneling:  $panels:  $panelled:  $panelling:  

<ME><AT><LW>pan<MM>el<BP>(p<AA>n<LL><SW>l)<EP><PS>n.<NA>1<NB>A flat, usually 
rectangular piece forming a part of a surface in which it is set, and being 
raised, recessed, or framed.<NA>2<NB>The space or section in a fence or 
railing between two posts.<NA>3<NB>A vertical section of fabric; gore.<NA>4. 
a<NB>A thin wooden board, used as a surface for oil painting.<NA>b<NB>A 
painting on such a board.<NA>5. a<NB>A board having switches to control parts 
of an electric device.<NA>b<NB>An <CR>instrument panel<CS>.<NA>6<NB>A section 
of a telephone switchboard.<NA>7. a<NB>The complete list of persons summoned 
for jury duty.<NA>b<NB>Those persons selected from the list to compose a 
jury.<NA>c<NB>A jury.<NA>8. a<NB>A group of people gathered to plan or discuss 
an issue, judge a contest, or act as a team on a radio or television quiz 
program.<NA>b<NB>A discussion by such a group.<PT>tr.v.<IF>-eled, -el<MM>ing, 
-els<AL>-elled, -el<MM>ling, -els.<NA>1<NB>To cover or furnish with 
panels.<NA>2<NB>To decorate with panels.<NA>3<NB>To separate into 
panels.<NA>4<NB>To select or impanel (a jury).<EY>ME, piece of cloth <LS> OFr. 
<LS> Lat. <IT>pannus, <RM>cloth.<EN>

$see:  $saw:  $seen:  $seeing:  $sees:  $see about:  $see through:  $see to:  

<NR>see<*,S>1<*.S><BP>(s<LE>)<EP><PS>v.<IF>saw<BP>(s<TO>),<EP><IF>seen<BP>(s<LE\
>n),<EP><IF>see<MM>ing, sees.<PT>tr.<NA>1<NB>To perceive with the 
eye.<NA>2<NB>To apprehend as if by the sense of sight: <IT>see with one's 
fingers.<NA>3<NB>To have a mental image of; visualize: <IT>could still see his 
hometown as it once was.<NA>4<NB>To understand; comprehend.<NA>5<NB>To regard; 
view.<NA>6<NB>To believe possible; imagine: <IT>I don't see her as a 
teacher.<NA>7<NB>To foresee.<NA>8<NB>To know through first<BH>hand experience; 
undergo: <IT>""He saw some service on the king's side'' <RM>(Tucker 
Brooke).<NA>9<NB>To be characterized by or bring forth: <IT>""Her long reign 
saw the heyday of verbal humor'' <RM>(Richard Kain).<NA>10<NB>To find out; 
ascertain.<NA>11<NB>To refer to; read: <IT>asked the reader to see page one of 
the preface. ...

$the:  

<ME><GR>the<*,S>1<*.S><BP>(<TH><LE> <IT>before a vowel; <RM><TH><SW> 
<IT>before a consonant<RM>)<EP><US>def.art.<NA>1. a<NB>Used before singular or 
plural nouns and noun phrases that denote particular, specified persons or 
things: <IT>read the newspaper.<NA>b<NB>Used before a noun, and generally 
stressed, emphasizing one of a group or type as the most outstanding or 
prominent: <IT>the social event of 1981.<NA>c<NB>Used before a title or rank 
or office designating its holder: <IT>The Prince of Wales; The President of 
the United States; the Reverend John Doe.<NA>d<NB>Used before nouns that 
designate natural phenomena or points of the compass: <IT>The weather looks 
bad. A wind is coming from the north.<NA>e<NB>Used as the equivalent of a 
possessive adjective before names of some parts of the body: <IT>grab him by 
the neck; an infection of the hand.<NA>f<NB>Used before a noun specifying a 
particular human endeavor: <IT>the law; the film industry; the 
stage.<NA>g<NB>Used before a proper name, as of a monument or ship: <IT>the 
Alamo; the Titanic.<NA>h<NB>Used before the plural form of a numeral denoting 
a specific decade or period in one's life: <IT>rural life in the 
thirties.<NA>2<NB>Used before a singular noun indicating that the noun is 
generic: <IT>The wolf is an endangered species.<NA>3. a<NB>Used before an 
adjective extending it to signify a class and giving it the function of a 
noun: <IT>""The rich were dull and they drank too much'' <RM>(Ernest 
Hemingway).<NA>b<NB>Used before an absolute adjective: <IT>the best we can 
offer.<NA>4<NB>Used before a present participle, signifying the action in the 
abstract: <IT>the weaving of rugs.<NA>5<NB>Used before a noun with the force 
of <IT>per: <IT>sold by the box.<EY>ME <LS> OE <IT><PHON/D>e, <RM>alteration 
of <IT>se, <RM>masc. nominative sing. demonstrative adj.<EN>

$this:  $these:  

<ME>this<BP>(<TH><AI>s)<EP><PS>pron.,<PL>these<BP>(<TH><LE>z).<EP><NA>1. 
a<NB>The person or thing present, nearby, or just mentioned: <IT>This is my 
cat. These are my tools.<NA>b<NB>What is about to be said: <IT>Now don't laugh 
when you hear this.<NA>c<NB>The present occasion or time: <IT>said he'd be 
back before this.<NA>2<NB>The one that is nearer than another or the one 
compared with the other: <IT>This is mine and that's 
yours.<PT>adj.,<PL>these.<NA>1<NB>Being just mentioned or present in space, 
time, or thought: <IT>She left early this morning.<NA>2<NB>Being nearer than 
another or compared with another: <IT>this side and that side.<NA>3<NB>Being 
about to be stated or described: <IT>Just wait till you hear this 
story.<PT>adv.<DF>To this extent; so: <IT>never stayed out this late.<EY>ME 
<LS> OE <IT><PHON/D>is <RM>(nominative and accusative neuter sing.). ...

$word:  $words:  $Word:  $worded:  $wording:  $at a word:  $by word of mouth: 
 $good word:  $have no words for:  $in a word:  $in so many words:  $of few 
words:  $of (one's) word:  $take (one) at (one's) word:  $upon my word:  $word 
for word:  

<ME>word<BP>(w<TU>rd)<EP><PS>n.<NA>1<NB>A sound or a combination of sounds, or 
its representation in writing or printing, that symbolizes and communicates a 
meaning and may consist of a single morpheme or of a combination of 
morphemes.<NA>2<NB>Something that is said; an utterance, remark, or comment: 
<IT>May I say a word about that?<NA>3<NB><IT>Computer Sci. <RM>A set of bits 
comprising the smallest unit of addressable computer 
memory.<NA>4<NB><BD>words. <RM>A discourse or talk; speech.<NA>5<NB><BD>words. 
<RM>The text of a vocal musical composition; lyrics.<NA>6<NB>An assurance or 
promise; sworn intention: <IT>kept his word.<NA>7. a<NB>A command or 
direction; an order: <IT>executed at the general's word.<NA>b<NB>A verbal 
signal; a password or watchword.<NA>8. a<NB>News: <IT>the latest 
word.<NA>b<NB>Rumor: <IT>Word has it she's married.<NA>9<NB><BD>words. 
<RM>Hostile or angry remarks made back and forth; 
quarrel.<NA>10<NB><BD>Word.<NA>a<NB>The <CR>Logos<CS>.<NA>b<NB>The Scriptures 
or Gospel: <IT>the Word of God.<PT>tr.v.<IF>word<MM>ed, word<MM>ing, 
words.<DF>To express in words.<RO><BI>idioms. <BD>at a word.<DF>In immediate 
response. <BD>by word of mouth.<DF>Orally; by speech. <BD>good word.<NA>1<NB>A 
favorable utterance or word: <IT>She put in a good word for 
me.<NA>2<NB>Favorable news. <BD>have no words for.<DF>To be unable to describe 
or talk about. <BD>in a word.<DF>In short: <IT>You are, in a word, a fool. 
<BD>in so many words.<DF>Precisely as stated; exactly. <BD>of few words. 
<RM>Not conversational or loquacious; laconic: <IT>a man of few words. <BD>of 
(one's) word. <RM>That can be depended on to keep one's promise: <IT>a man of 
his word. <BD>take (one) at (one's) word.<DF>To be convinced of another's 
sincerity and act in accordance with his statement. <BD>upon my word. 
<RM>Indeed; assuredly: <IT>Upon my word, I've never heard of such a thing. 
<BD>word for word.<DF>In the same words.<EY>ME <LS> OE.<EN>


\\\\



-- formatting typesetter entries

--	An entry begins with <ME>, <CE>, or <NR>

--	and extends to the next succeeding <EE> or \\n\\n.  Extraneous text is 
ignored.


--	The entry is scanned for the following

--	non-macro characters and the indicated replacements are made.

--

--		=	"-" (hyphen for making suffix or prefix entry)

--		^	"--"	(em-dash)

--		"	"`"


--	If "<<" is encountered, preceding spaces and subsequent

--	digits and spaces are deleted.  (This is actually done elsewhere.)


--	Macros of form <....> are converted by looking in ConTab,

--	which has an item for each <...> macro.

--	If no item is found for <...>, it is not replaced or modified in the text.

--	Following the <...> in the item is the replacement text.

--	The replacement text extends from just after the >

--	to just before the next <, except as noted under $'

--	If the replacement begins with % the item specifies the "field" 

--		to which the word may apply.  The field name is appended

--		to the end of entry, preceded by two spaces.

--	If the replacement begins with $, it and the next character are discarded,

--	but used to control formatting:

--		$.  -  the current style group is terminated and a new

--				group is initiated with the plain style

--		$& - the current style group is terminated and after the

--				replacement text, the next group will have

--				the style of the ampersand

--		$- - the current style group is terminated, but after the

--				replacement text, the style resumes its old value

--				for the next group

--		$' - the item is terminated with $ instead of the next <


marker ConTab := 


-- A

	"<AA>a\symbola{H}"		-- lowercase 'a' with breve ??	(symbola)

	~ "<AB>%Anthropology" -- 'Anthropology' (field)

	~ "<AE>e\symbola{H}"		-- lowercase 'e' with breve ??	(symbola)

	~ "<AI>i\symbola{H}"		-- lowercase 'i' with breve ??	(symbola)

	~ "<AL>$\bold{&} also "	-- roman ' also ' ; followed by bold

	~ "<AO>o\symbola{H}"		-- lowercase 'o' with breve ??	(symbola)

	~ "<AS>$. "		-- sets roman text with space (?)

	~ "<AT>%Art"	-- 'Art' (field)

	~ "<AU>u\symbola{H}"		-- lowercase 'u' with breve ??	(symbola)

	~ "<AV>$- Variant of "   -- roman "variant of "


-- B

	~ "<BB>%Bible"	-- 'Bible' (field)

	~ "<BD>$\bold{&}"		-- start bold type

	~ "<BG>%Biography" -- 'Biography' (field)

	~ "<BH>-"		-- breaking hyphen

	~ "<BI>$\bold{\italic{&}}"		-- bold-italic

	~ "<BL>%Biology"	-- 'Biology (field)

	~ "<BP>$. "		-- start pronunciation

	~ "<BR>%British"	-- 'British' (field)

	~ "<BT>%Botany"	-- 'Botany' (field)


-- C

	~ "<CA>%British Commonwealth" -- (field)

	~ "<CE>$\bold{&}"		-- before cross ref main entry word

	~ "<CH>%Chemistry" -- (field)

	~ "<CN>%Name"	-- before christian name; treat as (field)

	~ "<CR>"		-- start cross-reference word

	~ "<CS>"		-- stop cross-reference word


-- D

	~ "<DA>\^{d}"		-- lowercase 'a' with diaeresis

	~ "<DE>\^{k}"		-- lowercase 'e' with diaeresis

	~ "<DF>$.  "		-- start definition

	~ "<DI>\^{o}"		-- lowercase 'i' with diaeresis

	~ "<DL>\^{P}"		-- capital 'D' with bar accent through it

	~ "<DM>\symbola{(}"		-- solid diamond	(symbola)

	~ "<DO>\^{v}"		-- lowercase 'o' with diaeresis

	~ "<DU>u\^{(}"		-- lowercase 'u' with diaeresis	??


-- E

	~ "<EC>%Economics, Finance, Econometrics" -- (field)

	~ "<EE>\\n"		-- end of entry

	~ "<EN>$.]"		-- end of etymology, sets closing bracket

	~ "<EP>$."		-- end pron., start text type, no space

	~ "<ER>"		-- format 0050: before Alpha character numbers

	~ "<EY>$. ["		-- start of etymology; set space & open bracket

	~ "<EX>"		-- start of example


-- F

	~ "<FL>\^{~}"		-- set musical flat	??

	~ "<FT>\^{~}"		-- set musical flat	??


-- G

	~ "<GG>%Geography" -- (field)

	~ "<GL>%Geology"	-- (field)

	~ "<GR>%Grammar" -- (field)


--H		see below


-- I

	~ "<ID>$-\italic{\^{f}}"		-- sets italic 'ae'

	~ "<IF>$\bold{&} "		-- inflection spellings

	~ "<IO>%Idiom"	-- Idiom  (field)

	~ "<IT>$\italic{&}"		-- start italic font

	~ "<IX>ART INSTRUCTIONS:  "	-- art insertion instructions

    

-- K

	~ "<KA>\\n   "		-- before alphabetic introductory text

	~ "<KB>\\n\\n"		-- after alphabetic introductory text

	~ "<KN>"		-- format 0060: before College Name


-- L

	~ "<LA>\symbol{`}a"		-- lowercase 'a' with macron	??	(symbola)

	~ "<LC>$'<dot>$"	-- accent dot over letter		??

	~ "<LD>\symbol{`}oo"		-- lowercase 'oo' with macron	??	(symbol)

	~ "<LE>\symbol{`}e"		-- lowercase 'e' with macron	??	(symbol)

	~ "<LI>\symbol{`}i"		-- lowercase 'i' with macron	??	(symbol)

	~ "<LL>\\\symbola{\bold{"}}"		-- bold prime with break/hyphen	??	(symbola)

	~ "<LM>%Literature, Rhetoric, Philosophy" -- (field)

	~ "<LO>\symbol{`}o"		-- lowercase 'o' with macron	??	(symbol)

	~ "<LP>\\\symbola{"}"		-- light prime with break/hyphen	??	(symbola)

	~ "<LS>$'<$"		-- less-than sign

	~ "<LU>\symbol{`}u"		-- lowercase 'u' with macron	??	(symbola)

	~ "<LW>%Law"	-- (field)


-- M

	~ "<MA>$\bold{&} also "	-- lowercase 'also' between main entries

	~ "<MD>%Medicine" -- (field)

	~ "<ME>$\bold{&}"		-- before main entry word

	~ "<MI>%Military"	-- (field)

	~ "<MM>\symbola{\realsmall{7}}"\symbola{	}	-- syllable break in entry word 
 (symbola, realsmall)

	~ "<MR>$\bold{&} or\bold{ }"	-- sets 'or' between entry words

	~ "<MS>$'<nat>$"	-- sets nut space for musical natural 	??

	~ "<MT>%Mathematics" -- (field)

	~ "<MU>%Music"	-- (field)

	~ "<MY>%Mythology" -- (field)

	~ "<MZ>%Measurement" -- (field)


-- N

	~ "<N1>$\bold{&}\\n"		-- N1 = NA w/ forced line break

	~ "<NA>$\bold{&}  "		-- numbered definition; start bold

	~ "<NB>$.\bold{.} "		-- end of definition number; back to roman

	~ "<NL>\\\symbola{\bold{"}}"		-- sets bold prime, no break		??	(symbola)

	~ "<NP>\\\symbola{"}"		-- sets lite prime, no break		??	(symbola)

	~ "<NR>$\bold{&}"		-- before non-referencing word

	~ "<NT>%Nautical" -- (field)


-- O

	~ "<OC>."		-- sets angstrom below character  ??

	~ "<OP> or "		-- sets 'or' between pronunciations

	~ "<OR>$\bold{&} or\bold{ }"	-- sets 'or' between secondary entry words


-- P

	~ "<PC>%Psychology" -- (field)

	~ "<PH>%Physics"	-- (field)

	~ "<PL>$\bold{&} \italic{pl.} "	-- before plural, sets 'pl.', starts bold

	~ "<PO>%Politics"	-- (field)

	~ "<PP>nj"		-- phonetic lowercase 'nj'	??

	~ "<PS>$\italic{&  }"		-- part of speech; italic

	~ "<PT>$\italic{&} --"	-- embedded p.o.s. - space, em dash, italic

	~ "<PV>$.  \bold{\italic{phrasal verb.}} "	-- phrasal verb  (not usually 
used) ???


-- R

	~ "<RL>%Religion" -- (field)

	~ "<RM>$."		-- start roman type

	~ "<RO>$\bold{&}\bold{ --}"	-- before run-on entry, space, em dash, bold

	~ "<RX>R\subscript{x}"		-- sets 'Rx' symbol		??


-- S

	~ "<SD>oo\symbola{H}"		-- sets lowercase 'oo' with breve	??	(symbola)

	~ "<SH>#"		-- sets musical sharp	??

	~ "<SL>%Slang"	-- (field)

	~ "<SP>#"		-- sets number sign/space symbol	??

	~ "<SQ>\symbola{V}"		-- sets square root symbol	(symbola)

	~ "<ST>%Sports"	-- (field)

	~ "<SW>\symbol{e}"		-- schwa	??	(symbol)

	~ "<SY>$.\bold{\italic{\\n   Synonyms:}}  "	-- synonyms


-- T

	~ "<TA>\^{b}"		-- lowercase 'a' with circumflex

	~ "<TB>!?"		-- nut space for 'interrobang' (?^H!)  ??

	~ "<TE>\^{j}"		-- lowercase 'e' with circumflex

	~ "<TH>$-\italic{th}"	-- italic lowercase 'th'

	~ "<TI>\^{n}"		-- lowercase 'i' with circumflex

	~ "<TM>%Trademark" -- trademark word (field)

	~ "<TO>\^{t}"		-- lowercase 'o' with circumflex

	~ "<TR>\^{~}"		-- nut space 'thorn' character

	~ "<TU>\^{\{}"		-- u with circumflex


-- U

	~ "<UL>_"		-- sets macron below character	??

	~ "<UN>$.\\n   \bold{\italic{Usage:}}  " -- usage

	~ "<UO>."		-- sets angstrom below character

	~ "<US>$\italic{&} "		-- before a usage indicator word: space, italic


-- V

	~ "<VV>%Vulgar slang" -- (field)


-- X

	~ "<XA>a."		-- sets 'a.' after number in defn.

	~ "<XB>b."		-- sets 'b.' after number in defn.

	~ "<XX>" 		-- undefined condition


-- Z

	~ "<ZD>"		-- format 3001: used for folios

	~ "<ZO>%Zoology"	-- (field)


-- Numeric macros

	~ "<1A>$.  \bold{1. a.} "	-- sets 1.<V>a.<J> in definition

	~ "<3D>\symbol{`}d"		-- sets phonetic 'd'	??	(symbol)

	~ "<41>$'<41a>$"	-- sets phonetic character '41a'  ??

	~ "<88>"		-- undefined field


-- Function Codes

	~ "<#1>$."		-- normal font

	~ "<#2>$\helv{&}"		-- small caps font	(helv)


	~ "<*BD>$\bold{&}"	-- bold mode

	~ "<*IT>$\italic{&}"		-- italic mode

	~ "<*RM>$."		-- roman mode

	~ "< << >\\n"		-- line end

	~ "<*.I>$."		-- cancel inferior character (subscript)

	~ "<*.S>$."		-- cancel superior character (superscript)

	~ "<*,I>$\subscript{&}"		-- first level inferior character

	~ "<*,S>$\superscript{&}"		-- first level superior character

	~ "<=>="		-- equal sign

	~ "<\\">\\""		-- quote

	~ "<'>'"		-- right quote

	~ "<`>`"		-- left quote

	~ "<+> + "		-- plus in etymology

	~ "<->-"		-- "-"

	~ "<+/->\^{1}"		-- plus/minus

	~ "<...>\symbola{<}"		-- ellipses	(symbola)


-- Fractions

	~ "<1/2>\^{=}"

	~ "<3/4>\^{>}"

	~ "<1/3>1/3"

	~ "<3/8>3/8"

	~ "<1/5>1/5"

	~ "<5/8>5/8"

	~ "<4/5>4/5"

	~ "<1/4>\^{<}"


-- Special characters

	~ "<ACUTE>\^{4}"	-- accent acute over previous character  	??

	~ "<ACUTE2>\^{4}"	-- 	(?)  ??

	~ "<ANGST>\^{0}"	-- angstrom sign over previous character (circle)  ??

	~ "<ATSIGN>@"	-- @

	~ "<BASDOT>."	-- dot beneath previous character		??

	~ "<BREVE>\symbola{H}"	-- breve over previous character		??	(symbola)

	~ "<BULLET>\symbola{7}"	-- bullet		(symbola)

	~ "<CEDILL>\^{8}"	-- cedilla under previous character		??

	~ "<CFLEX>^"	-- circumflex over previous character   	??

	~ "<CIRDOT>\symbola{E}"	-- circle with a dot in it	??	(symbola)

	~ "<DAGGAR>\symbola{-}"	--	??	(symbola)

	~ "<DDG>\symbola{`}"		-- double dagger	??	(symbola)

	~ "<DEG>\^{0}"		-- degree sign

	~ "<DIAR>\^{(}"		-- diaresis over previous character	??

	~ "<DIV>\symbola{8}"		-- division sign	(symbola)

	~ "<DOT>\^{7}"		-- dot over previous character	??

	~ "<FLAT>\^{~}"		-- musical flat		??

	~ "<GRAVE>`"	-- accent grave over previous character	??

	~ "<GTR>>"		-- >

	~ "<HANDR>\symbola{^}"	-- right pointing hand	??	(symbola)

	~ "<HOOK>\^{8}"	-- like a cedilla under previous character	??

	~ "<ICFLEX>\symbola{Z}"	-- inverted circumflex over previous character	??	
(symbola)

--	~ "<IDW>"		-- ???

--	~ "<INT>"		-- ???

	~ "<INVQU>\^{?}"	-- inverted question mark ???

	~ "<L/AE>\^{f}"		-- ligature ae

	~ "<L/OE>oe"	-- ligature oe		??

	~ "<LBRACE>\{"	-- \{

	~ "<LESS>$'<$"	-- <

	~ "<LONG>-"	-- macron over previous letter (used in spelling) ??

	~ "<LSLASH>l/"	-- slashed lower l	??

	~ "<NOT=>\symbola{9}"	-- not equal	(symbola)

	~ "<OSLASH>\^{x}"	-- O slashed

	~ "<PARMRK>\^{6}"	-- backward-P paragraph mark

	~ "<PHON/D>\symbol{`}d"	-- d with a macron	??	(symbol)

	~ "<POISON>\symbola{p}"	-- Mr. Yuk	??	(symbol)

	~ "<RBRACE>\}"	-- \}

	~ "<ROOT>\symbola{V}"	-- sq root sign	(symbola)

	~ "<SCHWA>\symbol{'}"	-- upside-down little e	??	(symbol)

	~ "<SECMRK>\^{'}"	-- section mark: S with disjointure

	~ "<SIM>\bigger{\subscript{~}}"		-- middle tilde	??

	~ "<TILDE>~"	-- tilde over previous character	??

	~ "<TRI>\symbol{D}"		-- triangle	??	(symbol)

	~ "<V> "		-- variable white space (?)

	~ "<VRULE>\symbola{=}"	-- vertical rule ??	(symbola)

	~ "<X>\symbola{4}"		-- times sign	(symbola)


-- UNDEFINED MACROS (no-ops)

	~ "<AW><AY><BC><BN><BO><BY><CD><CG><CM><CP>"

	~ "<DB><DD><DP><DR><DY><EL><EM><EO><EU><GC>"

	~ "<GM><LN><LT><MC><ML><MO><MV><MW><NE><ND>"

	~ "<NK><PA><PE><PG><PI><QS><RT><SB><SC><SE><SI>"

	~ "<SK><SO><VS><XC><XO><UM><Z><ZC><ZD><ZL><ZP>"

	~ "<2>"


-- H		start of entries for given letter

	~ "<HA><HB><HC><HD><HE><HF><HG><HH><HI><HJ>" 

	~ "<HK><HL><HM><HN><HO><HP><HQ><HR><HS><HT>" 

	~ "<HU><HV><HW><HX><HY><HZ>" 


	~ "<"		-- (terminate last entry)




marker groupStart	-- where most recent style group starts

marker groupStyle	-- style for most recent style group ("" if none)


function appendtext(d, t)

	return finish(replace(finish(d), t))

end function


-- first(r) is a control code, . & ' or -;  rest(r) is the replacement 

--	the replacement may contain styles, but is not affected by the

--	styles of the style group

-- the replacement goes in place marked as dest

function DoStyledReplacement(dest, r)

	if first(r) = "'" then

		-- text contains "<" and is terminated with $

		return appendtext(dest, extent(second(r), 

				start(search(finish(first(r)), "$"))))

	end if

	if groupStyle /= "" then	-- terminate previous group

		addstyles(extent(GroupStart, dest), groupStyle)

	end if

	dest := appendtext(dest, rest(r))

	GroupStart := dest

	if first(r) = "." then

		groupStyle := ""

	elif first(r) = "&" then

		groupStyle := first(r)

	end if

	return dest

end function


-- reformat an entry;  return the ATK version

function formatandinsert(dest, e)

	marker m, r, t, initialStart

	marker fields := newbase()	-- the set of fields collected from macros


	dest := replace(dest, "")

	initialStart := dest

	groupStart := dest

	groupStyle := ""


	while e /= "" do

		m := anyof(e, "=\\^\\"<")

		dest := appendtext(dest, extent(e, start(m)))

		e := extent(finish(m), e)

		if m = "<" then


			if next(m) = "<" then

				-- delete spaces and number around <<

				r := dest

				while r = " " and extent(r, groupStart) = "" do 

					r := previous(r) 

				end while

				dest := replace(extent(next(r), dest), "")

				parseint(finish(next(m)))

				e := extent(finish(span(finish(whereItWas()), " ")), e)

			else

				m := extent(m, search(e, ">"))

				e := extent(finish(m), e)

				t := search(ConTab, m)

				r := extent(next(t), start(search(finish(t), "<")))

				if t = "" then 

					dest := appendtext(dest, m)

				elif first(r) = "%" then 	-- field

					if fields = "" then fields ~:= "  \{"  

					else fields ~:= ", " end if

					fields ~:= rest(r)

				elif r = "" then		-- no replacement

				elif first(r) = "$" then

					dest := DoStyledReplacement(dest, rest(r))

				else dest := appendtext(dest, r)


				end if

			end if


		elif m = "=" then

			dest := appendtext(dest, "-")		-- hyphen

		elif m = "^" then

			dest := appendtext(dest, "--")	-- em-dash

		elif m = "\\"" then

			dest := appendtext(dest, "`")		-- right quote

		else	-- must be empty because no more operations

			exit while

		end if

	end while

	if groupStyle /= "" then

		addstyles(extent(GroupStart, dest), groupStyle)

	end if

	if fields /= "" then 

		return extent(initialStart, appendtext(dest, fields ~ "\}"))

	end if

	return extent(initialStart, dest)

end function



-- Search the "dictionary" for the definition and return it

--

function FindEntry(w)

	marker d := search(definitions, "$" ~ w ~":")

	d := finish(search(finish(d), "\\n"))

	return extent(d, start(search(d, "\\n")))

end function



-- insert in finish(dest) the given definition, surrounded by newlines.

--

function AppendDefn(dest, defn)

	if defn = "" then 

		return replace(dest, "\\nNO DEFINITION FOUND\\n")

	else

		return formatandinsert(start(last(replace(dest, "\\n\\n"))), defn)

	end if

end function


-- set current selection to the word surrounding its former start

-- return the word

--

function SelectedWord()

	if currentselection(currentinset) /= "" then

		textview_beginning_of_line(currentinset)

	end if

	textview_forward_character(currentinset)

	textview_backward_word(currentinset)

	textview_ctrl_at(currentinset)

	textview_forward_word(currentinset)

	textview_select_region(currentinset)

	return currentselection(currentinset)

end function


extend "instructions"

	on mouse "any"

		dohit(currentinset, mouseaction, mousex, mousey)

		if mouseaction = mouseleftup then

			marker w := SelectedWord()

			marker target := base(currentselection(inset("definition")))

			replace (target, "")

			AppendDefn(target, FindEntry(w))				

		end if

	end mouse

end extend\
\enddata{ness,270527436}
1 270527436 0 0 0 0 
>OBJ< ness
>VIEW< nessview
>REF< ness
\enddata{cel,270527704}
0 0 0 270527704 0 0 0
>OBJ< cel
>VIEW< celview
>REF< 
\enddata{lset,270527844}
2 33 0 0 270506648 270527844 0
>OBJ< 
>VIEW< 
>REF< 
\enddata{lset,270506880}
