aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero2011-03-16 02:28:20 +0100
committerJuanma Barranquero2011-03-16 02:28:20 +0100
commit5ba5fb816df11ef82326f16c8d9da88169bde721 (patch)
treea29a57f54bee0182b2b3f88be9c8404929ceced6
parent62973b416261f9b43e9026807651554e3cf2c9c3 (diff)
downloademacs-5ba5fb816df11ef82326f16c8d9da88169bde721.tar.gz
emacs-5ba5fb816df11ef82326f16c8d9da88169bde721.zip
lisp/progmodes/delphi.el: Fix typos.
-rw-r--r--lisp/ChangeLog13
-rw-r--r--lisp/progmodes/delphi.el75
2 files changed, 50 insertions, 38 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index db21eb97cc0..93a6e720a78 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,6 +1,17 @@
12011-03-16 Juanma Barranquero <lekktu@gmail.com>
2
3 * progmodes/delphi.el (delphi-search-path, delphi-indent-level)
4 (delphi-verbose, delphi-comment-face, delphi-string-face)
5 (delphi-keyword-face, delphi-ignore-changes, delphi-indent-line)
6 (delphi-mode-abbrev-table, delphi-debug-buffer, delphi-tab)
7 (delphi-find-unit, delphi-find-current-xdef, delphi-fill-comment)
8 (delphi-new-comment-line, delphi-font-lock-defaults)
9 (delphi-debug-mode-map, delphi-mode-syntax-table, delphi-mode):
10 Fix typos in docstrings.
11
12011-03-15 Ken Manheimer <ken.manheimer@gmail.com> 122011-03-15 Ken Manheimer <ken.manheimer@gmail.com>
2 13
3 * allout.el (allout-make-topic-prefix) (allout-rebullet-heading): 14 * allout.el (allout-make-topic-prefix, allout-rebullet-heading):
4 Invert the roles of character and string values for INSTEAD, so a 15 Invert the roles of character and string values for INSTEAD, so a
5 string is used for the more common case of a defaulting prompt. 16 string is used for the more common case of a defaulting prompt.
6 17
diff --git a/lisp/progmodes/delphi.el b/lisp/progmodes/delphi.el
index c376b25fae0..0f823c806e0 100644
--- a/lisp/progmodes/delphi.el
+++ b/lisp/progmodes/delphi.el
@@ -26,14 +26,14 @@
26 26
27;; To enter Delphi mode when you find a Delphi source file, one must override 27;; To enter Delphi mode when you find a Delphi source file, one must override
28;; the auto-mode-alist to associate Delphi with .pas (and .dpr and .dpk) 28;; the auto-mode-alist to associate Delphi with .pas (and .dpr and .dpk)
29;; files. Emacs, by default, will otherwise enter Pascal mode. E.g. 29;; files. Emacs, by default, will otherwise enter Pascal mode. E.g.
30;; 30;;
31;; (autoload 'delphi-mode "delphi") 31;; (autoload 'delphi-mode "delphi")
32;; (setq auto-mode-alist 32;; (setq auto-mode-alist
33;; (cons '("\\.\\(pas\\|dpr\\|dpk\\)$" . delphi-mode) auto-mode-alist)) 33;; (cons '("\\.\\(pas\\|dpr\\|dpk\\)$" . delphi-mode) auto-mode-alist))
34 34
35;; To get keyword, comment, and string literal coloring, be sure that font-lock 35;; To get keyword, comment, and string literal coloring, be sure that font-lock
36;; is running. One can manually do M-x font-lock-mode in a Delphi buffer, or 36;; is running. One can manually do M-x font-lock-mode in a Delphi buffer, or
37;; one can put in .emacs: 37;; one can put in .emacs:
38;; 38;;
39;; (add-hook 'delphi-mode-hook 'turn-on-font-lock) 39;; (add-hook 'delphi-mode-hook 'turn-on-font-lock)
@@ -56,8 +56,8 @@
56;; When you have entered Delphi mode, you may get more info by pressing 56;; When you have entered Delphi mode, you may get more info by pressing
57;; C-h m. 57;; C-h m.
58 58
59;; This delphi mode implementation is fairly tolerant of syntax errors, relying 59;; This Delphi mode implementation is fairly tolerant of syntax errors, relying
60;; as much as possible on the indentation of the previous statement. This also 60;; as much as possible on the indentation of the previous statement. This also
61;; makes it faster and simpler, since there is less searching for properly 61;; makes it faster and simpler, since there is less searching for properly
62;; constructed beginnings. 62;; constructed beginnings.
63 63
@@ -74,15 +74,16 @@
74 "True if in debug mode.") 74 "True if in debug mode.")
75 75
76(defcustom delphi-search-path "." 76(defcustom delphi-search-path "."
77 "*Directories to search when finding external units. It is a list of 77 "*Directories to search when finding external units.
78directory strings. If only a single directory, it can be a single 78It is a list of directory strings. If only a single directory,
79string instead of a list. If a directory ends in \"...\" then that 79it can be a single string instead of a list. If a directory
80directory is recursively searched." 80ends in \"...\" then that directory is recursively searched."
81 :type 'string 81 :type 'string
82 :group 'delphi) 82 :group 'delphi)
83 83
84(defcustom delphi-indent-level 3 84(defcustom delphi-indent-level 3
85 "*Indentation of Delphi statements with respect to containing block. E.g. 85 "*Indentation of Delphi statements with respect to containing block.
86E.g.
86 87
87begin 88begin
88 // This is an indent of 3. 89 // This is an indent of 3.
@@ -117,7 +118,7 @@ end; end;"
117 :group 'delphi) 118 :group 'delphi)
118 119
119(defcustom delphi-verbose t ; nil 120(defcustom delphi-verbose t ; nil
120 "*If true then delphi token processing progress is reported to the user." 121 "*If true then Delphi token processing progress is reported to the user."
121 :type 'boolean 122 :type 'boolean
122 :group 'delphi) 123 :group 'delphi)
123 124
@@ -137,17 +138,17 @@ differs from the default."
137 :group 'delphi) 138 :group 'delphi)
138 139
139(defcustom delphi-comment-face 'font-lock-comment-face 140(defcustom delphi-comment-face 'font-lock-comment-face
140 "*Face used to color delphi comments." 141 "*Face used to color Delphi comments."
141 :type 'face 142 :type 'face
142 :group 'delphi) 143 :group 'delphi)
143 144
144(defcustom delphi-string-face 'font-lock-string-face 145(defcustom delphi-string-face 'font-lock-string-face
145 "*Face used to color delphi strings." 146 "*Face used to color Delphi strings."
146 :type 'face 147 :type 'face
147 :group 'delphi) 148 :group 'delphi)
148 149
149(defcustom delphi-keyword-face 'font-lock-keyword-face 150(defcustom delphi-keyword-face 'font-lock-keyword-face
150 "*Face used to color delphi keywords." 151 "*Face used to color Delphi keywords."
151 :type 'face 152 :type 'face
152 :group 'delphi) 153 :group 'delphi)
153 154
@@ -720,9 +721,9 @@ routine.")
720 (delphi-progress-done))))) 721 (delphi-progress-done)))))
721 722
722(defvar delphi-ignore-changes t 723(defvar delphi-ignore-changes t
723 "Internal flag to control if the delphi-mode responds to buffer changes. 724 "Internal flag to control if the Delphi mode responds to buffer changes.
724Defaults to t in case the delphi-after-change function is called on a 725Defaults to t in case the `delphi-after-change' function is called on a
725non-delphi buffer. Set to nil in a delphi buffer. To override, just do: 726non-Delphi buffer. Set to nil in a Delphi buffer. To override, just do:
726 (let ((delphi-ignore-changes t)) ...)") 727 (let ((delphi-ignore-changes t)) ...)")
727 728
728(defun delphi-after-change (change-start change-end old-length) 729(defun delphi-after-change (change-start change-end old-length)
@@ -1521,8 +1522,8 @@ non-delphi buffer. Set to nil in a delphi buffer. To override, just do:
1521 indent))) 1522 indent)))
1522 1523
1523(defun delphi-indent-line () 1524(defun delphi-indent-line ()
1524 "Indent the current line according to the current language construct. If 1525 "Indent the current line according to the current language construct.
1525before the indent, the point is moved to the indent." 1526If before the indent, the point is moved to the indent."
1526 (interactive) 1527 (interactive)
1527 (delphi-save-match-data 1528 (delphi-save-match-data
1528 (let ((marked-point (point-marker)) ; Maintain our position reliably. 1529 (let ((marked-point (point-marker)) ; Maintain our position reliably.
@@ -1547,7 +1548,7 @@ before the indent, the point is moved to the indent."
1547 (set-marker marked-point nil)))) 1548 (set-marker marked-point nil))))
1548 1549
1549(defvar delphi-mode-abbrev-table nil 1550(defvar delphi-mode-abbrev-table nil
1550 "Abbrev table in use in delphi-mode buffers.") 1551 "Abbrev table in use in Delphi mode buffers.")
1551(define-abbrev-table 'delphi-mode-abbrev-table ()) 1552(define-abbrev-table 'delphi-mode-abbrev-table ())
1552 1553
1553(defmacro delphi-ensure-buffer (buffer-var buffer-name) 1554(defmacro delphi-ensure-buffer (buffer-var buffer-name)
@@ -1568,7 +1569,7 @@ before the indent, the point is moved to the indent."
1568;; Debugging helpers: 1569;; Debugging helpers:
1569 1570
1570(defvar delphi-debug-buffer nil 1571(defvar delphi-debug-buffer nil
1571 "Buffer to write delphi-mode debug messages to. Created on demand.") 1572 "Buffer to write Delphi mode debug messages to. Created on demand.")
1572 1573
1573(defun delphi-debug-log (format-string &rest args) 1574(defun delphi-debug-log (format-string &rest args)
1574 ;; Writes a message to the log buffer. 1575 ;; Writes a message to the log buffer.
@@ -1679,7 +1680,7 @@ before the indent, the point is moved to the indent."
1679 1680
1680(defun delphi-tab () 1681(defun delphi-tab ()
1681 "Indent the region, when Transient Mark mode is enabled and the region is 1682 "Indent the region, when Transient Mark mode is enabled and the region is
1682active. Otherwise, indent the current line or insert a TAB, depending on the 1683active. Otherwise, indent the current line or insert a TAB, depending on the
1683value of `delphi-tab-always-indents' and the current line position." 1684value of `delphi-tab-always-indents' and the current line position."
1684 (interactive) 1685 (interactive)
1685 (cond ((use-region-p) 1686 (cond ((use-region-p)
@@ -1768,8 +1769,8 @@ value of `delphi-tab-always-indents' and the current line position."
1768 nil)) 1769 nil))
1769 1770
1770(defun delphi-find-unit (unit) 1771(defun delphi-find-unit (unit)
1771 "Finds the specified delphi source file according to `delphi-search-path'. 1772 "Find the specified Delphi source file according to `delphi-search-path'.
1772If no extension is specified, .pas is assumed. Creates a buffer for the unit." 1773If no extension is specified, .pas is assumed. Creates a buffer for the unit."
1773 (interactive "sDelphi unit name: ") 1774 (interactive "sDelphi unit name: ")
1774 (let* ((unit-file (if (string-match "^\\(.*\\)\\.[a-z]+$" unit) 1775 (let* ((unit-file (if (string-match "^\\(.*\\)\\.[a-z]+$" unit)
1775 unit 1776 unit
@@ -1791,7 +1792,7 @@ If no extension is specified, .pas is assumed. Creates a buffer for the unit."
1791 "Find the definition of the identifier under the current point, searching 1792 "Find the definition of the identifier under the current point, searching
1792in external units if necessary (as listed in the current unit's use clause). 1793in external units if necessary (as listed in the current unit's use clause).
1793The set of directories to search for a unit is specified by the global variable 1794The set of directories to search for a unit is specified by the global variable
1794delphi-search-path." 1795`delphi-search-path'."
1795 (interactive) 1796 (interactive)
1796 (error "delphi-find-current-xdef: not implemented yet")) 1797 (error "delphi-find-current-xdef: not implemented yet"))
1797 1798
@@ -1802,7 +1803,7 @@ it is a routine."
1802 (error "delphi-find-current-body: not implemented yet")) 1803 (error "delphi-find-current-body: not implemented yet"))
1803 1804
1804(defun delphi-fill-comment () 1805(defun delphi-fill-comment ()
1805 "Fills the text of the current comment, according to `fill-column'. 1806 "Fill the text of the current comment, according to `fill-column'.
1806An error is raised if not in a comment." 1807An error is raised if not in a comment."
1807 (interactive) 1808 (interactive)
1808 (save-excursion 1809 (save-excursion
@@ -1888,8 +1889,8 @@ An error is raised if not in a comment."
1888 (delphi-progress-done))))))) 1889 (delphi-progress-done)))))))
1889 1890
1890(defun delphi-new-comment-line () 1891(defun delphi-new-comment-line ()
1891 "If in a // comment, does a newline, indented such that one is still in the 1892 "If in a // comment, do a newline, indented such that one is still in the
1892comment block. If not in a // comment, just does a normal newline." 1893comment block. If not in a // comment, just does a normal newline."
1893 (interactive) 1894 (interactive)
1894 (let ((comment (delphi-current-token))) 1895 (let ((comment (delphi-current-token)))
1895 (if (not (eq 'comment-single-line (delphi-token-kind comment))) 1896 (if (not (eq 'comment-single-line (delphi-token-kind comment)))
@@ -1923,7 +1924,7 @@ comment block. If not in a // comment, just does a normal newline."
1923 nil ; Syntax begin movement doesn't apply 1924 nil ; Syntax begin movement doesn't apply
1924 (font-lock-fontify-region-function . delphi-fontify-region) 1925 (font-lock-fontify-region-function . delphi-fontify-region)
1925 (font-lock-verbose . delphi-fontifying-progress-step)) 1926 (font-lock-verbose . delphi-fontifying-progress-step))
1926 "Delphi mode font-lock defaults. Syntactic fontification is ignored.") 1927 "Delphi mode font-lock defaults. Syntactic fontification is ignored.")
1927 1928
1928(defvar delphi-debug-mode-map 1929(defvar delphi-debug-mode-map
1929 (let ((kmap (make-sparse-keymap))) 1930 (let ((kmap (make-sparse-keymap)))
@@ -1944,7 +1945,7 @@ comment block. If not in a // comment, just does a normal newline."
1944 ("x" delphi-debug-show-is-stable) 1945 ("x" delphi-debug-show-is-stable)
1945 )) 1946 ))
1946 kmap) 1947 kmap)
1947 "Keystrokes for delphi-mode debug commands.") 1948 "Keystrokes for Delphi mode debug commands.")
1948 1949
1949(defvar delphi-mode-map 1950(defvar delphi-mode-map
1950 (let ((kmap (make-sparse-keymap))) 1951 (let ((kmap (make-sparse-keymap)))
@@ -1964,7 +1965,7 @@ comment block. If not in a // comment, just does a normal newline."
1964 "Keymap used in Delphi mode.") 1965 "Keymap used in Delphi mode.")
1965 1966
1966(defconst delphi-mode-syntax-table (make-syntax-table) 1967(defconst delphi-mode-syntax-table (make-syntax-table)
1967 "Delphi mode's syntax table. It is just a standard syntax table. 1968 "Delphi mode's syntax table. It is just a standard syntax table.
1968This is ok since we do our own keyword/comment/string face coloring.") 1969This is ok since we do our own keyword/comment/string face coloring.")
1969 1970
1970;;;###autoload 1971;;;###autoload
@@ -1976,7 +1977,7 @@ This is ok since we do our own keyword/comment/string face coloring.")
1976\\[delphi-fill-comment]\t- Fill the current comment. 1977\\[delphi-fill-comment]\t- Fill the current comment.
1977\\[delphi-new-comment-line]\t- If in a // comment, do a new comment line. 1978\\[delphi-new-comment-line]\t- If in a // comment, do a new comment line.
1978 1979
1979M-x indent-region also works for indenting a whole region. 1980\\[indent-region] also works for indenting a whole region.
1980 1981
1981Customization: 1982Customization:
1982 1983
@@ -1996,21 +1997,21 @@ Customization:
1996 `delphi-search-path' (default .) 1997 `delphi-search-path' (default .)
1997 Directories to search when finding external units. 1998 Directories to search when finding external units.
1998 `delphi-verbose' (default nil) 1999 `delphi-verbose' (default nil)
1999 If true then delphi token processing progress is reported to the user. 2000 If true then Delphi token processing progress is reported to the user.
2000 2001
2001Coloring: 2002Coloring:
2002 2003
2003 `delphi-comment-face' (default font-lock-comment-face) 2004 `delphi-comment-face' (default font-lock-comment-face)
2004 Face used to color delphi comments. 2005 Face used to color Delphi comments.
2005 `delphi-string-face' (default font-lock-string-face) 2006 `delphi-string-face' (default font-lock-string-face)
2006 Face used to color delphi strings. 2007 Face used to color Delphi strings.
2007 `delphi-keyword-face' (default font-lock-keyword-face) 2008 `delphi-keyword-face' (default font-lock-keyword-face)
2008 Face used to color delphi keywords. 2009 Face used to color Delphi keywords.
2009 `delphi-other-face' (default nil) 2010 `delphi-other-face' (default nil)
2010 Face used to color everything else. 2011 Face used to color everything else.
2011 2012
2012Turning on Delphi mode calls the value of the variable delphi-mode-hook with 2013Turning on Delphi mode calls the value of the variable `delphi-mode-hook'
2013no args, if that value is non-nil." 2014with no args, if that value is non-nil."
2014 (interactive) 2015 (interactive)
2015 (kill-all-local-variables) 2016 (kill-all-local-variables)
2016 (use-local-map delphi-mode-map) 2017 (use-local-map delphi-mode-map)