[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 250/352: Improve wcheck-language-data doc
From: |
Stefan Monnier |
Subject: |
[elpa] 250/352: Improve wcheck-language-data doc |
Date: |
Mon, 07 Jul 2014 14:04:39 +0000 |
monnier pushed a commit to branch master
in repository elpa.
commit 0d77b7473a6e170cd74d5919d789db1d90c9aab5
Author: Teemu Likonen <address@hidden>
Date: Fri Jun 24 14:18:42 2011 +0300
Improve wcheck-language-data doc
---
wcheck-mode.el | 35 +++++++++++++++++++----------------
1 files changed, 19 insertions(+), 16 deletions(-)
diff --git a/wcheck-mode.el b/wcheck-mode.el
index a532213..1e5f50f 100644
--- a/wcheck-mode.el
+++ b/wcheck-mode.el
@@ -433,8 +433,8 @@ read-or-skip-faces
Action options
==============
-\"Actions\" are any kind of operations that can be triggered
-for marked text in an Emacs buffer. Actions are presented to user
+\"Actions\" are any kind of operations that can be executed for
+marked text in an Emacs buffer. Actions are presented to user
through a menu which is activated either by (1) clicking the
right mouse button on a marked text or (2) executing interactive
command `wcheck-actions' while the cursor (the point) is on a
@@ -462,7 +462,7 @@ action-args
The output is parsed with `action-parser' function (see
below) and function's return value is used to construct an
action menu for user. The format and effect of
- `action-parser' function's return value is discussed below.
+ `action-parser' function's return value is described below.
When `action-program' is an Emacs Lisp function the function
is called with one argument: a vector returned by
@@ -471,7 +471,7 @@ action-args
strings or give other actions for the marked text in the
buffer. Function's return value is used to construct an
action menu for user. The format and effect of
- `action-program' function's return value is discussed below.
+ `action-program' function's return value is described below.
action-parser
VALUE of this option is an Emacs Lisp function which is
@@ -530,7 +530,7 @@ argument: a vector returned by `wcheck-marked-text-at'
function
for the marked text in question.
Effectively `action-program' function or `action-program'
-executable program with `action-parser' function present a
+executable program with `action-parser' function provide a
feature that can offer spelling suggestions for user: just return
suggestions as a list of strings. Alternatively they can offer
any kind of useful actions by calling custom functions. There are
@@ -588,19 +588,19 @@ my-finnish-syntax-table. It could be defined like this:
(modify-syntax-entry ?- \"w\" my-finnish-syntax-table)
-That is, it copies `text-mode-syntax-table' (which `wcheck-mode'
-uses by default) and sets the syntactic meaning of the ASCII
-hyphen character (-) to a word character (\"w\"). `wcheck-mode'
-and its regular expression search will use that syntax table when
+It copies `text-mode-syntax-table' (which `wcheck-mode' uses by
+default) and sets the syntactic meaning of the ASCII hyphen
+character (-) to a word character (\"w\"). `wcheck-mode' and its
+regular expression search will use that syntax table when
scanning buffers' content in that language.
Below is an example on how to add an \"Add to dictionary\"
feature to the actions menu, among spelling suggestions. First,
-there's the language configuration. The following example is
-similar to the \"British English\" configuration above except
-that `action-parser' function is a bit more complicated. It's a
-lambda expression which calls `wcheck-parser-ispell-suggestions'
-and then adds \"Add to dictionary\" option in the front of the
+there's the language configuration. The example is similar to the
+\"British English\" configuration above except that
+`action-parser' function is a bit more complicated. It's a lambda
+expression which calls `wcheck-parser-ispell-suggestions' and
+then adds \"Add to dictionary\" option in the front of the
spelling suggestions list. Choosing that option from the actions
menu will call function add-word-to-dictionary (which doesn't
exist yet).
@@ -623,11 +623,14 @@ Then write code that adds a new string to the dictionary.
(defun add-word-to-dictionary (marked-text)
;; MARKED-TEXT is a vector returned by
;; `wcheck-marked-text-at' function.
+
(let ((word (aref marked-text 0))
(language (aref marked-text 4)))
+
;; Do the actual job here. That is, write code that adds
;; the string stored in variable \"word\" to the
;; appropriate dictionary.
+
(message \"Added word \\\"%s\\\" to the %s dictionary\"
word language)))
@@ -675,7 +678,7 @@ other major modes FIXMEs are marked everywhere.
The following example adds a language \"email\" for highlighting
email addresses from buffer and creating an action menu which has
-option to start composing mail to that address. First, here's the
+option to start composing mail to that address. Here's the
language configuration:
(\"email\"
@@ -705,7 +708,7 @@ Then the needed functions:
Note that detecting all valid email addresses is difficult and a
much more advanced parser is needed for that. Feel free to
-replace the above detection function with a better one."
+replace the detection function with a better one."
:group 'wcheck
:type
- [elpa] 238/352: Poistetaan turha #' lambda-rakenteiden edestä, (continued)
- [elpa] 238/352: Poistetaan turha #' lambda-rakenteiden edestä, Stefan Monnier, 2014/07/07
- [elpa] 245/352: Correction in wcheck-language-data doc: "variable" -> "value", Stefan Monnier, 2014/07/07
- [elpa] 240/352: Mainostetaan funktiota wcheck-marked-text-at julkiseen käyttöön, Stefan Monnier, 2014/07/07
- [elpa] 246/352: Fix type in doc: "wcheck-parse-" "wcheck-parser-", Stefan Monnier, 2014/07/07
- [elpa] 235/352: Wcheck-versionumero: 2011.02.20, Stefan Monnier, 2014/07/07
- [elpa] 233/352: Uusi ominaisuus: tarkistusohjelman tulosteen jäsennysfunktio, Stefan Monnier, 2014/07/07
- [elpa] 251/352: Clarify the use of regexp-start, -body and -end, Stefan Monnier, 2014/07/07
- [elpa] 241/352: Korjataan wcheck-jump-backward -bugi, Stefan Monnier, 2014/07/07
- [elpa] 239/352: Tyylillistä hienosäätöä funktioon wcheck-make-overlay, Stefan Monnier, 2014/07/07
- [elpa] 243/352: Add README file, Stefan Monnier, 2014/07/07
- [elpa] 250/352: Improve wcheck-language-data doc,
Stefan Monnier <=
- [elpa] 244/352: Copy Emacs wiki page's content to new README file, Stefan Monnier, 2014/07/07
- [elpa] 249/352: Fix a typo in wcheck-language-data doc string, Stefan Monnier, 2014/07/07
- [elpa] 253/352: Add \< and \> to regexps in "email" language example, Stefan Monnier, 2014/07/07
- [elpa] 252/352: Rephrase grouping construct \(\) description in doc string, Stefan Monnier, 2014/07/07
- [elpa] 247/352: Escape \\< with \\=\\< in wcheck-language-data doc string, Stefan Monnier, 2014/07/07
- [elpa] 248/352: Clearer reference to the license text, Stefan Monnier, 2014/07/07
- [elpa] 255/352: Copy examples from wcheck-language-data doc to README, Stefan Monnier, 2014/07/07
- [elpa] 254/352: Rephrase some parts of README, Stefan Monnier, 2014/07/07
- [elpa] 261/352: Merge branch 'action', Stefan Monnier, 2014/07/07
- [elpa] 258/352: README: Move copyright and license text to the end, Stefan Monnier, 2014/07/07