]> git.eshelyaron.com Git - emacs.git/commitdiff
; * doc/emacs/search.texi (Word Search): Document 'dictionary-search'.
authorEli Zaretskii <eliz@gnu.org>
Sat, 12 Oct 2024 07:17:10 +0000 (10:17 +0300)
committerEshel Yaron <me@eshelyaron.com>
Mon, 14 Oct 2024 17:38:41 +0000 (19:38 +0200)
(cherry picked from commit 0f8f0773183a07a229b23d3f970723ceb9585aef)

doc/emacs/search.texi

index 292b7d25a01cc31a6bb9b05b57304b33f7034796..40b04bc8e501df16d6288e8e0819abdd601307c8 100644 (file)
@@ -792,6 +792,46 @@ search engine whose @acronym{URL} is specified by the variable
 Wowser Manual}).  If the region is not active, or doesn't contain any
 words, this command prompts the user for a URL or keywords to search.
 
+@findex dictionary-search
+@findex dictionary
+@findex dictionary-tooltip-mode
+@cindex dictionary server protocol (DICT)
+@cindex word definition search
+@vindex dictionary-server
+  You can also search for definitions of a word by querying dictionary
+servers via the @sc{dict} protocol defined by @acronym{RFC} 2229.  Emacs
+includes a client for this protocol.  Type @w{@kbd{M-x dictionary-search
+@key{RET}}} to connect to a @sc{dict} server and ask it to provide the
+available definitions of a word.  This command prompts for the word to
+look up, using the word at point as the default, then asks the @sc{dict}
+server to provide the definitions of that word in one or more
+dictionaries.  By default, the command first tries to connect to the
+@sc{dict} server installed on the local host, and if that fails, it
+tries @file{dict.org} after your confirmation; customize the variable
+@code{dictionary-server} to specify, as a string, the URL of a single
+server to use (use @samp{localhost} if you want to query only the local
+server).  Normally, @code{dictionary-search} tells the server to look up
+the word in all the dictionaries available to the server, but if you
+invoke the command with a prefix argument, it will prompt for a single
+dictionary to look.  The list of dictionaries available to a server can
+be displayed by pressing the @samp{Select dictionary} button shown in
+the @file{*Dictionary*} buffer, described below.
+
+  First time you use @code{dictionary-search}, it creates a new
+@file{*Dictionary*} buffer and turns on a special mode in it.  The
+buffer shows buttons for selecting a dictionary, searching a definition
+of another word, etc.  Subsequent @code{dictionary-search} commands
+reuse this buffer.  To create another such buffer (e.g., too look up
+other words, perhaps in another dictionary), type @w{@kbd{M-x dictionary
+@key{RET}}}.
+
+  If you turn on @code{dictionary-tooltip-mode} in a buffer, Emacs will
+look up the definitions of the word at mouse pointer and show those
+definitions in a tool tip.  This is handy when you are reading text with
+many words about whose meaning you are unsure.
+
+  For other options of dictionary-search, see the @code{dictionary}
+customization group (@pxref{Specific Customization}).
 
 @node Symbol Search
 @section Symbol Search