aboutsummaryrefslogtreecommitdiff
path: root/man/man1/dict.html
blob: 48d086baf89a619f1422f3094090c21f00d89251 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
<head>
<title>dict(1) - Plan 9 from User Space</title>
<meta content="text/html; charset=utf-8" http-equiv=Content-Type>
</head>
<body bgcolor=#ffffff>
<table border=0 cellpadding=0 cellspacing=0 width=100%>
<tr height=10><td>
<tr><td width=20><td>
<tr><td width=20><td><b>DICT(1)</b><td align=right><b>DICT(1)</b>
<tr><td width=20><td colspan=2>
    <br>
<p><font size=+1><b>NAME     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    dict, adict &ndash; dictionary browser<br>
    
</table>
<p><font size=+1><b>SYNOPSIS     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    <tt><font size=+1>dict</font></tt> [ <tt><font size=+1>&#8722;k</font></tt> ] [ <tt><font size=+1>&#8722;d</font></tt> <i>dictname</i> ] [ <tt><font size=+1>&#8722;c</font></tt> <i>command</i> ] [ <i>pattern</i> ] <tt><font size=+1>adict</font></tt> [
    <tt><font size=+1>&#8722;d</font></tt> <i>dictname</i> ] [ <i>pattern</i> ]<br>
    
</table>
<p><font size=+1><b>DESCRIPTION     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    <i>Dict</i> is a dictionary browser. If a <i>pattern</i> is given on the command
    line, <i>dict</i> prints all matching entries; otherwise it repeatedly
    accepts and executes commands. The options are<br>
    <tt><font size=+1>&#8722;d</font></tt> <i>dictname</i>&nbsp;&nbsp;&nbsp;Use the given dictionary. A list of available dictionaries
    is printed by option <tt><font size=+1>&#8722;d?</font></tt>. The default is the first dictionary
    on the list that is installed on the system.<br>
    <tt><font size=+1>&#8722;c</font></tt> <i>command</i>&nbsp;&nbsp;&nbsp;Execute one command and quit. The command syntax is
    described below.<br>
    <tt><font size=+1>&#8722;k</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Print a pronunciation key. 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    Patterns are regular expressions (see <a href="../man7/regexp.html"><i>regexp</i>(7)</a>), with an implicit
    leading <tt><font size=+1>^</font></tt> and trailing <tt><font size=+1>$</font></tt>. Patterns are matched against an index
    of headwords and variants, to form a &#8216;match set&#8217;. By default,
    both patterns and the index are folded: upper case characters
    are mapped into their lower case equivalents, and Latin accented
    characters are mapped into their non-accented equivalents. In
    interactive mode, there is always a &#8216;current match set&#8217; and a
    &#8216;current entry&#8217; within the match set. Commands can change either
    or both, as well as print the entries or information about them.
    
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    Commands have an address followed by a command letter. Addresses
    have the form:<br>
    <tt><font size=+1>/</font></tt><i>re</i><tt><font size=+1>/</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Set the match set to all entries matching the regular expression
    <i>re</i>, sorted in dictionary order. Set the current entry to the first
    of the match set.<br>
    <tt><font size=+1>!</font></tt><i>re</i><tt><font size=+1>!</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Like <tt><font size=+1>/</font></tt><i>re</i><tt><font size=+1>/</font></tt> but use exact matching, i.e., without case and accent
    folding.<br>
    <i>n</i>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;An integer <i>n</i> means change the current entry to the <i>n</i>th of the
    current match set.<br>
    <tt><font size=+1>#</font></tt><i>n</i>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The integer <i>n</i> is an absolute byte offset into the raw dictionary.
    (See the <tt><font size=+1>A</font></tt> command, below.)<br>
    <i>addr</i><tt><font size=+1>+</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;After setting the match set and current entry according to
    <i>addr</i>, change the match set and current entry to be the next entry
    in the dictionary (not necessarily in the match set) after the
    current entry.<br>
    <i>addr</i><tt><font size=+1>&#8722;</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;Like <i>addr</i><tt><font size=+1>+</font></tt> but go to previous dictionary entry. 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    The command letters come in pairs: a lower case and the corresponding
    upper case letter. The lower case version prints something about
    the current entry only, and advances the current entry to the
    next in the match set (wrapping around to the beginning after
    the last). The upper case version prints something about
    all of the match set and resets the current entry to the beginning
    of the set.<br>
    <tt><font size=+1>p</font></tt>,<tt><font size=+1>P</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;Print the whole entry.<br>
    <tt><font size=+1>h</font></tt>,<tt><font size=+1>H</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;Print only the headword(s) of the entry.<br>
    <tt><font size=+1>a</font></tt>,<tt><font size=+1>A</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;Print the dictionary byte offset of the entry.<br>
    <tt><font size=+1>r</font></tt>,<tt><font size=+1>R</font></tt>&nbsp;&nbsp;&nbsp;&nbsp;Print the whole entry in raw format (without translating special
    characters, etc.). 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    If no command letter is given for the first command, <tt><font size=+1>H</font></tt> is assumed.
    After an <tt><font size=+1>H</font></tt>, the default command is <tt><font size=+1>p</font></tt>. Otherwise, the default command
    is the previous command. 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    <i>Adict</i> is a dictionary browser for <a href="../man1/acme.html"><i>acme</i>(1)</a>. When run with no arguments,
    it creates a new <i>acme</i> window named <tt><font size=+1>/adict/</font></tt> listing the installed
    dictionaries. Clicking with button 3 on a dictionary name will
    create a new empty window named <tt><font size=+1>/adict/</font></tt><i>dict</i><tt><font size=+1>/.</font></tt> Typing and then
    clicking on a pattern in this window will create
    a new lookup window named <tt><font size=+1>/adict/</font></tt><i>dict</i><tt><font size=+1>/</font></tt><i>pattern</i> containing the dictionary&#8217;s
    definition of <i>pattern</i>. Clicking with button 3 on any word in this
    new window will create new lookup windows. 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    If <i>adict</i> is run with a <i>pattern ,</i> it starts with the <tt><font size=+1>/adict/</font></tt><i>dict</i><tt><font size=+1>/</font></tt><i>pattern</i>
    window. 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    If <i>adict</i> is run with no pattern but with a <tt><font size=+1>&#8722;d</font></tt> option, it starts
    with the <tt><font size=+1>/adict/</font></tt><i>dict</i><tt><font size=+1>/</font></tt> window.<br>
    
</table>
<p><font size=+1><b>FILES     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    <tt><font size=+1>/usr/local/plan9/dict<br>
    </font></tt>
    <table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

        dictionaries<br>
        
    </table>
    
</table>
<p><font size=+1><b>SEE ALSO     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    <a href="../man7/regexp.html"><i>regexp</i>(7)</a><br>
    
</table>
<p><font size=+1><b>SOURCE     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    <tt><font size=+1>/usr/local/plan9/src/cmd/dict<br>
    /usr/local/plan9/bin/adict<br>
    </font></tt>
</table>
<p><font size=+1><b>BUGS     </b></font><br>

<table border=0 cellpadding=0 cellspacing=0><tr height=2><td><tr><td width=20><td>

    A font with wide coverage of the Unicode Standard should be used
    for best results. (Try <tt><font size=+1>/usr/local/plan9/font/pelm/unicode.9.font</font></tt>.)
    
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    If the <i>pattern</i> doesn&#8217;t begin with a few literal characters, matching
    takes a long time. 
    <table border=0 cellpadding=0 cellspacing=0><tr height=5><td></table>
    
    The dictionaries are not distributed outside Bell Labs, though
    see <tt><font size=+1>/usr/local/plan9/dict/README</font></tt> for information on using free
    dictionaries prepared by Project Gutenberg.<br>
    
</table>

<td width=20>
<tr height=20><td>
</table>
<!-- TRAILER -->
<table border=0 cellpadding=0 cellspacing=0 width=100%>
<tr height=15><td width=10><td><td width=10>
<tr><td><td>
<center>
<a href="../../"><img src="../../dist/spaceglenda100.png" alt="Space Glenda" border=1></a>
</center>
</table>
<!-- TRAILER -->
</body></html>