1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-28 07:45:00 +00:00
Commit Graph

540 Commits

Author SHA1 Message Date
Glenn Morris
21e3f963e7 * lisp/font-lock.el (lisp-font-lock-keywords-2): Add with-eval-after-load. 2013-06-20 23:37:44 -07:00
Glenn Morris
d0341459c1 * lisp/font-lock.el (lisp-font-lock-keywords-2): Treat user-error like error 2013-06-06 17:35:45 -04:00
Glenn Morris
af5c7606d1 * font-lock.el (lisp-font-lock-keywords-2): Add with-coding-priority. 2013-05-23 23:59:55 -07:00
Stefan Monnier
1d5963cc63 * lisp/progmodes/f90.el (f90-mode-syntax-table): Use symbol syntax for "_".
Change all regexps to use things like \_< and \_>.

* lisp/progmodes/ada-mode.el (ada-mode-abbrev-table): Consolidate declaration.
(ada-mode-syntax-table, ada-mode-symbol-syntax-table): Initialize in
the declaration.
(ada-create-syntax-table): Remove.
(ada-capitalize-word): Don't mess with the syntax of "_" since it
already has the right syntax nowadays.
(ada-goto-next-word): Don't change the syntax of "_".

* lisp/progmodes/autoconf.el (autoconf-definition-regexp)
(autoconf-font-lock-keywords, autoconf-current-defun-function):
Handle a _ with symbol syntax.
(autoconf-mode): Don't change the syntax-table for imenu and font-lock.

* lisp/progmodes/vera-mode.el (vera-underscore-is-part-of-word):
* lisp/progmodes/prolog.el (prolog-underscore-wordchar-flag)
(prolog-char-quote-workaround):
* lisp/progmodes/cperl-mode.el (cperl-under-as-char):
* lisp/progmodes/vhdl-mode.el (vhdl-underscore-is-part-of-word):
 Mark as obsolete.
 (vhdl-mode-syntax-table, vhdl-mode-ext-syntax-table): Initialize in
their declaration.
(vhdl-mode-syntax-table-init): Remove.

* lisp/progmodes/ld-script.el (ld-script-mode-syntax-table): Use symbol
syntax for "_".
(ld-script-font-lock-keywords):
Change regexps to use things like \_< and \_>.

* lisp/progmodes/m4-mode.el (m4-mode-syntax-table): Add comment on last change.

* lisp/font-lock.el (lisp-font-lock-keywords-2): Don't highlight obsolete
with-wrapper-hook.

* lisp/mh-e/mh-comp.el (mh-regexp-in-field-p): Minor simplification.
2013-05-08 12:27:53 -04:00
Stefan Monnier
b234d92c06 * lisp/font-lock.el (lisp-font-lock-keywords-2): Don't highlight the "error"
part of "(error-foo)".
2013-03-25 09:47:32 -04:00
Thierry Volpiatto
f2c8840090 * lisp/font-lock.el (lisp-font-lock-keywords-2): Fix highlighting of
&optional.

Fixes: debbugs:13819
2013-02-27 10:25:55 -05:00
Stefan Monnier
913274cbdc Don't use font-lock-syntax-table in lisp modes.
* lisp/font-lock.el (lisp-font-lock-keywords-1, lisp-font-lock-keywords-2):
Don't assume all identifier chars have syntax word.
* lisp/emacs-lisp/lisp-mode.el (lisp-mode-variables):
Remove bar-not-symbol.  Adjust callers.
(lisp-mode-variables): Don't set a font-lock-syntax-table.
2013-02-17 11:58:12 -05:00
Glenn Morris
ef5ae980aa * lisp/font-lock.el (lisp-font-lock-keywords-1): Add defvar-local. 2013-02-15 20:55:31 -05:00
Aaron S. Hawley
9fc9a531a5 Disambiguate function and variable references in docstrings.
* lisp/comint.el (comint-history-isearch-message): Fix ambiguous doc
 string cross-reference(s).

* lisp/ffap.el (ffap-string-at-point-region, ffap-next)
(ffap-string-at-point, ffap-string-around)
(ffap-copy-string-as-kill, ffap-highlight-overlay)
(ffap-literally): Fix ambiguous doc string cross-reference(s).

* lisp/font-lock.el (font-lock-keywords-alist)
(font-lock-removed-keywords-alist): Fix ambiguous doc string
        cross-reference(s).

* lisp/help-mode.el (help-xref-symbol-regexp): Add "call" as a hint for
a cross-reference to a function.

* lisp/info.el (Info-find-emacs-command-nodes): Fix ambiguous doc
 string cross-reference(s).

* lisp/isearch.el (isearch-message-function, isearch-fail-pos): Fix
 ambiguous doc string cross-reference(s).

* lisp/misearch.el (multi-isearch-next-buffer-function): Fix ambiguous
 doc string cross-reference(s).

* lisp/newcomment.el (comment-box): Fix ambiguous doc string
 cross-reference(s).

* lisp/printing.el (pr-txt-printer-alist, pr-ps-printer-alist)
(pr-setting-database): Fix ambiguous doc string
 cross-reference(s).

* lisp/ps-print.el (ps-even-or-odd-pages, ps-spool-buffer-with-faces)
(ps-n-up-filling-database): Fix ambiguous doc string
 cross-reference(s).

* lisp/server.el (server-buffer, server-log): Fix ambiguous doc string
 cross-reference(s).

* lisp/simple.el (newline, delete-backward-char, delete-forward-char)
(minibuffer-history-isearch-message, kill-line, track-eol)
(temporary-goal-column): Fix ambiguous doc string
 cross-reference(s).

* lisp/whitespace.el (whitespace-point)
(whitespace-font-lock-refontify, whitespace-bob-marker)
(whitespace-eob-marker): Fix ambiguous doc string
 cross-reference(s).

* lisp/calc/calc.el (calc-highlight-selections-with-faces)
 (calc-dispatch): Fix ambiguous doc string cross-reference(s).

* lisp/emacs-lisp/edebug.el (edebug-read, edebug-eval-defun): Fix
 ambiguous doc string cross-reference(s).

* lisp/gnus/gnus-start.el (gnus-check-new-newsgroups): Fix ambiguous doc string
 cross-reference(s).

* lisp/gnus/gnus-sum.el (gnus-summary-newsgroup-prefix): Fix ambiguous doc string
 cross-reference(s).

* lisp/international/mule.el (add-to-coding-system-list): Fix ambiguous
 doc string cross-reference(s).

* lisp/progmodes/cc-fonts.el (c-font-lock-keywords-3)
(c++-font-lock-keywords-3, objc-font-lock-keywords-3)
(java-font-lock-keywords-3, idl-font-lock-keywords-3)
(pike-font-lock-keywords-3): Fix ambiguous doc string
 cross-reference(s).

* lisp/progmodes/compile.el (compile): Fix ambiguous doc string
 cross-reference(s).

* lisp/progmodes/etags.el (tags-table-files)
(tags-table-files-function, tags-included-tables-function): Fix
 ambiguous doc string cross-reference(s).

* lisp/progmodes/gdb-mi.el (gdb, gdb-setup-windows)
(gdb-restore-windows): Fix ambiguous doc string
 cross-reference(s).

* lisp/textmodes/flyspell.el (flyspell-mark-duplications-flag)
(flyspell-default-deplacement-commands): Fix ambiguous doc string
 cross-reference(s).

* lisp/textmodes/ispell.el (ispell-accept-output): Fix ambiguous doc
 string cross-reference(s).

* lisp/textmodes/sgml-mode.el (html-tag-help): Fix ambiguous doc string
 cross-reference(s).

* lisp/vc/compare-w.el (compare-ignore-whitespace)
(compare-ignore-case, compare-windows-dehighlight): Fix ambiguous
 doc string cross-reference(s).

* lisp/vc/diff.el (diff): Fix ambiguous doc string cross-reference(s).

* src/insdel.c (Fcombine_after_change_execute, syms_of_insdel): Fix
 ambiguous doc string cross-reference(s).

* src/keyboard.c (Fcommand_execute, syms_of_keyboard): Fix ambiguous
 doc string cross-reference(s).

* src/window.c (Fwindow_point, syms_of_window): Fix ambiguous doc
 string cross-reference(s).

Fixes: debbugs:12686
2013-01-11 18:08:55 -05:00
Paul Eggert
ab422c4d68 Update copyright notices for 2013. 2013-01-01 09:11:05 +00:00
Chong Yidong
a5f2b6ec3b Remove several obsolete vars and functions unlikely to be still in use.
* lisp/vc/log-edit.el (cvs-changelog-full-paragraphs)
(cvs-commit-buffer-require-final-newline): Obsolete variables
removed.

* lisp/font-lock.el (font-lock-reference-face): Use
define-obsolete-variable-alias.

* lisp/international/mule.el (set-char-table-default): Remove.
(set-coding-priority, make-coding-system, generic-char-p)
(charset-list, charset-bytes, charset-id): Use declare to mark
obsolete.

* lisp/mail/supercite.el (sc-version): Remove obsolete function.
(sc-describe): Don't mark as obsolete, since it is bound.
(sc-submit-bug-report): Remove.

* lisp/progmodes/compile.el (compile-internal): Remove obsolete
function.
(compilation-parse-errors-function): Fix typo.

* lisp/vc/emerge.el (emerge-mode): Make it an obsolete alias.
(emerge-version): Remove.

* lisp/vc/pcvs-defs.el (cvs-buffer-name-alist)
(cvs-invert-ignore-marks): Remove references to obsolete vars.
* lisp/vc/vc-hooks.el (vc-default-registered): Don't use
vc-master-templates.

* lisp/vc/pcvs-defs.el (cvs-diff-buffer-name, cvs-diff-ignore-marks)
* lisp/vc/vc-hooks.el (vc-ignore-vc-files, vc-master-templates)
* lisp/vc/vc.el (vc-checkout-carefully): Likewise.

* src/chartab.c (Fset_char_table_default): Obsolete function removed.
2012-09-24 20:23:25 +08:00
Chong Yidong
865fe16fd2 Update docstrings and comments to use "init file" terminology.
* bookmark.el (bookmark-bmenu-toggle-filenames): Doc fixes.
* comint.el (comint-prompt-read-only):
* custom.el (defcustom):
* hi-lock.el (hi-lock-mode):
* ibuffer.el (ibuffer-formats):
* ielm.el (ielm-prompt-read-only):
* novice.el (disable-command):
* saveplace.el (toggle-save-place):
* speedbar.el (speedbar-supported-extension-expressions):
* startup.el (auto-save-list-file-prefix, init-file-user)
(after-init-hook, inhibit-startup-echo-area-message):
* strokes.el (strokes-help):
* time-stamp.el (time-stamp):
* calendar/calendar.el (calendar, diary-file):
* calendar/diary-lib.el (diary-mail-entries, diary)
(diary-list-entries-hook):
* calendar/holidays.el (holidays, calendar-holidays):
* calendar/lunar.el (lunar-phases):
* calendar/solar.el (sunrise-sunset):
* emulation/edt.el (edt-load-keys):
* emulation/viper.el (viper-mode):
* eshell/em-alias.el (eshell-command-aliases-list):
* eshell/esh-util.el (eshell-convert-numeric-arguments):
* international/ogonek.el (ogonek-information):
* net/tramp-cmds.el (tramp-bug):
* net/quickurl.el (quickurl-reread-hook-postfix):
* play/decipher.el (decipher-font-lock-keywords):
* progmodes/cc-styles.el (c-set-style):
* progmodes/idlw-shell.el (idlwave-shell-prompt-pattern):
* progmodes/inf-lisp.el (inferior-lisp-prompt):
* progmodes/octave-mod.el (octave-mode):
* progmodes/sql.el (sql-mode, sql-interactive-mode, sql-password):
* progmodes/verilog-mode.el (verilog-read-defines):
* textmodes/two-column.el (2C-mode): Likewise.
2012-09-17 13:41:04 +08:00
Glenn Morris
36e8d1eb27 * lisp/font-lock.el (font-lock-add-keywords): Doc fix
(quote face names since most non-font-lock faces are not also variables).
2012-08-20 00:30:40 -07:00
Stefan Monnier
f58e0fd503 Reduce use of (require 'cl).
* admin/bzrmerge.el: Use cl-lib.
* leim/quail/hangul.el: Don't require CL.
* leim/quail/ipa.el: Use cl-lib.
* vc/smerge-mode.el, vc/pcvs.el, vc/pcvs-util.el, vc/pcvs-info.el:
* vc/diff-mode.el, vc/cvs-status.el, uniquify.el, scroll-bar.el:
* register.el, progmodes/sh-script.el, net/gnutls.el, net/dbus.el:
* msb.el, mpc.el, minibuffer.el, international/ucs-normalize.el:
* international/quail.el, info-xref.el, imenu.el, image-mode.el:
* font-lock.el, filesets.el, edmacro.el, doc-view.el, bookmark.el:
* battery.el, avoid.el, abbrev.el: Use cl-lib.
* vc/pcvs-parse.el, vc/pcvs-defs.el, vc/log-view.el, vc/log-edit.el:
* vc/diff.el, simple.el, pcomplete.el, lpr.el, comint.el, loadhist.el:
* jit-lock.el, international/iso-ascii.el, info.el, frame.el, bs.el:
* emulation/crisp.el, electric.el, dired.el, cus-dep.el, composite.el:
* calculator.el, autorevert.el, apropos.el: Don't require CL.
* emacs-bytecomp.el (byte-recompile-directory, display-call-tree)
(byte-compile-unfold-bcf, byte-compile-check-variable):
* emacs-byte-opt.el (byte-compile-trueconstp)
(byte-compile-nilconstp):
* emacs-autoload.el (make-autoload): Use pcase.
* face-remap.el (text-scale-adjust): Simplify pcase patterns.
2012-07-10 07:51:54 -04:00
Chong Yidong
4b56d0fe74 Face cleanups. Remove some uses of old-style face spec and :bold/:italic.
* faces.el (set-face-attribute): Doc fix.
(modify-face): Don't use :bold and :italic.
(error, warning, success): Tweak definitions.

* cus-edit.el (custom-modified, custom-invalid, custom-rogue)
(custom-modified, custom-set, custom-changed, custom-themed)
(custom-saved, custom-button, custom-button-mouse)
(custom-button-pressed, custom-state, custom-comment-tag)
(custom-variable-tag, custom-group-tag-1, custom-group-tag)
(custom-group-subtitle): Use new-style face specs.
(custom-invalid-face, custom-rogue-face, custom-modified-face)
(custom-set-face, custom-changed-face, custom-saved-face)
(custom-button-face, custom-button-pressed-face)
(custom-documentation-face, custom-state-face)
(custom-comment-face, custom-comment-tag-face)
(custom-variable-tag-face, custom-variable-button-face)
(custom-face-tag-face, custom-group-tag-face-1)
(custom-group-tag-face): Remove obsolete face alias.

* epa.el (epa-validity-high, epa-validity-medium)
(epa-validity-low, epa-mark, epa-field-name, epa-string)
(epa-field-name, epa-field-body):
* font-lock.el (font-lock-comment-face, font-lock-string-face)
(font-lock-keyword-face, font-lock-builtin-face)
(font-lock-function-name-face, font-lock-variable-name-face)
(font-lock-type-face, font-lock-constant-face):
* ido.el (ido-first-match, ido-only-match, ido-subdir)
(ido-virtual, ido-indicator, ido-incomplete-regexp):
* speedbar.el (speedbar-button-face, speedbar-file-face)
(speedbar-directory-face, speedbar-tag-face)
(speedbar-selected-face, speedbar-highlight-face)
(speedbar-separator-face):
* whitespace.el (whitespace-newline, whitespace-space)
(whitespace-hspace, whitespace-tab, whitespace-trailing)
(whitespace-line, whitespace-space-before-tab)
(whitespace-space-after-tab, whitespace-indentation)
(whitespace-empty):
* emulation/cua-base.el (cua-global-mark):
* eshell/em-prompt.el (eshell-prompt):
* net/newst-plainview.el (newsticker-new-item-face)
(newsticker-old-item-face, newsticker-immortal-item-face)
(newsticker-obsolete-item-face, newsticker-date-face)
(newsticker-statistics-face, newsticker-default-face):
* net/newst-reader.el (newsticker-feed-face)
(newsticker-extra-face, newsticker-enclosure-face):
* net/newst-treeview.el (newsticker-treeview-face)
(newsticker-treeview-new-face, newsticker-treeview-old-face)
(newsticker-treeview-immortal-face)
(newsticker-treeview-obsolete-face)
(newsticker-treeview-selection-face):
* net/rcirc.el (rcirc-my-nick, rcirc-other-nick)
(rcirc-bright-nick, rcirc-server, rcirc-timestamp)
(rcirc-nick-in-message, rcirc-nick-in-message-full-line)
(rcirc-prompt, rcirc-track-keyword, rcirc-url, rcirc-keyword):
* nxml/nxml-outln.el (nxml-heading, nxml-outline-indicator)
(nxml-outline-active-indicator, nxml-outline-ellipsis):
* play/mpuz.el (mpuz-unsolved, mpuz-solved, mpuz-trivial)
(mpuz-text):
* progmodes/vera-mode.el (vera-font-lock-number)
(vera-font-lock-function, vera-font-lock-interface):
* textmodes/table.el (table-cell): Use new-style face specs, and
don't use the old :bold and :italic attributes.

* erc-button.el (erc-button):
* erc-goodies.el (erc-bold-face, erc-inverse-face)
(erc-underline-face, fg:erc-color-*):
* erc-match.el (erc-current-nick-face, erc-dangerous-host-face)
(erc-pal-face, erc-fool-face, erc-keyword-face):
* erc-stamp.el (erc-timestamp-face): Likewise.

* erc.el (erc-direct-msg-face, erc-header-line, erc-input-face)
(erc-command-indicator-face, erc-notice-face, erc-action-face)
(erc-error-face, erc-my-nick-face, erc-nick-default-face)
(erc-nick-msg-face): Use new-style face specs, and avoid :bold.

* progmodes/ebrowse.el (ebrowse-tree-mark, ebrowse-root-class)
(ebrowse-member-attribute, ebrowse-default, ebrowse-file-name)
(ebrowse-member-class, ebrowse-progress): Likewise.
(ebrowse-tree-mark-face, ebrowse-root-class-face)
(ebrowse-file-name-face, ebrowse-default-face)
(ebrowse-member-attribute-face, ebrowse-member-class-face)
(ebrowse-progress-face): Remove obsolete faces.

* progmodes/flymake.el (flymake-errline, flymake-warnline):
Inherit from error and warning faces respectively.

* textmodes/flyspell.el (flyspell-incorrect, flyspell-duplicate):
Likewise.
(flyspell-incorrect-face, flyspell-duplicate-face): Remove
obsolete aliases.

* display.texi (Face Attributes): Font family does not accept
wildcards.  De-document obsolete :bold and :italic attributes.
(Defining Faces): Use new-style face spec format.
2012-06-09 00:39:49 +08:00
Leo Liu
39773899f3 * lisp/font-lock.el (lisp-font-lock-keywords-2): Add pcase, pcase-let
and pcase-let*.
2012-04-20 19:36:21 +08:00
Chong Yidong
fb7ada5f94 Remove * characters from the front of variable docstrings. 2012-04-09 21:05:48 +08:00
Leo Liu
50e94f0c5d * lisp/font-lock.el (lisp-font-lock-keywords-2): Add letrec. 2012-03-16 20:26:22 +08:00
Glenn Morris
44e97401cd Standardize possessive apostrophe usage in manuals, docs, and comments
Ref: http://lists.gnu.org/archive/html/emacs-devel/2012-02/msg00649.html
2012-02-28 00:17:21 -08:00
Chong Yidong
c98c62764a * font-lock.el (font-lock-specified-p): Rename from font-lock-spec-present.
Callers changed.
2012-02-27 10:34:12 +08:00
Alan Mackenzie
487915d738 Check there is a font-lock specification before initial fontification. 2012-02-26 13:02:52 +00:00
Alan Mackenzie
2cb228f753 Add new parameter :after-hook to define-minor-mode. Use this in the
definition of font-lock-mode.
2012-02-23 18:51:22 +00:00
Leo Liu
1be3ca5ad7 Rename condition-case-no-debug to condition-case-unless-debug 2012-02-10 23:59:29 +08:00
Glenn Morris
f8cdeef0bc * lisp/font-lock.el (lisp-font-lock-keywords-2): Add with-wrapper-hook. 2012-02-04 18:27:35 -08:00
Glenn Morris
acaf905b11 Add 2012 to FSF copyright years for Emacs files 2012-01-05 01:46:05 -08:00
Paul Eggert
99d990817c Spelling fixes. 2011-12-18 22:21:24 -08:00
Paul Eggert
40ba43b4b7 Spelling fixes. 2011-11-19 23:30:16 -08:00
Paul Eggert
dbdb703130 Spelling fixes. 2011-11-11 02:04:08 -08:00
Chong Yidong
67e729a5f7 * lisp/font-lock.el (font-lock-maximum-size): Mark as obsolete. 2011-10-17 18:21:48 -04:00
Chong Yidong
39eeb2f7c5 Minor fix to last change. 2011-08-20 23:02:39 -04:00
Chong Yidong
2c34e8dad7 Add some docstrings to font-lock.el.
* font-lock.el (font-lock-fontify-region)
(font-lock-unfontify-region, font-lock-default-fontify-buffer)
(font-lock-default-unfontify-buffer)
(font-lock-default-fontify-region)
(font-lock-default-unfontify-region): Add docstrings (Bug#8624).
2011-08-20 23:00:52 -04:00
Juri Linkov
bc987f8b80 * lisp/faces.el (error, warning, success): New faces with definitions
copied from old default values of `font-lock-warning-face',
`compilation-warning', `compilation-info'.

* lisp/font-lock.el (font-lock-warning-face): Inherit from `error'.

* lisp/progmodes/compile.el (compilation-error): Inherit from `error'.
(compilation-warning): Inherit from `warning'.
(compilation-info): Inherit from `success'.

* lisp/dired.el (dired-marked): Inherit from `warning'.
(dired-flagged): Inherit from `error'.

Fixes: debbugs:6117
2011-08-18 14:36:19 +03:00
Lars Magne Ingebrigtsen
f2182a765a * font-lock.el (font-lock-maximum-decoration): Mention what numeric levels mean.
Fixes: debbugs:6935
2011-07-14 15:50:25 +02:00
Dan Nicolaescu
bf6012e5b1 Use "yellow" on low color terminals for comments
* font-lock.el (font-lock-comment-face): Use the high contrast
"yellow" color for font-lock-comment-face on low color terminals
using a dark background color.

Fixes: debbugs:4221
2011-07-13 17:33:08 +02:00
Chong Yidong
73fed7aeda Revert last change (2011-07-05T14:25:21Z!larsi@gnus.org). 2011-07-05 11:23:15 -04:00
Lars Magne Ingebrigtsen
bad327838e * font-lock.el (font-lock-builtin-face): Change from Orchid to
MediumBlue on light-coloured backgrounds to avoid confusion with
the doc string.

Fixes: debbugs:6693
2011-07-05 16:25:21 +02:00
Chong Yidong
2f11b3f1ce * font-lock.el (font-lock-builtin-face): Change light background color
to dark slate blue.

Fixes: debbugs:6693
2011-07-04 16:00:56 -04:00
Stefan Monnier
2403c841a8 Silence various byte-compiler warnings.
* lisp/emacs-lisp/byte-run.el (make-obsolete-variable): New argument
`access-type' and new obsolescence format.
* lisp/emacs-lisp/bytecomp.el (byte-compile-warn-obsolete): Adjust to
new format.
(byte-compile-check-variable): New `access-type' argument.
Only warn if the access-type is obsolete.
(byte-compile-dynamic-variable-bind, byte-compile-variable-ref)
(byte-compile-variable-set): Adjust callers.
* lisp/help-fns.el (describe-variable): Adjust to new obsolescence format.
* lisp/mail/sendmail.el (mail-mailer-swallows-blank-line): Only mark
setting it as obsolete.
* lisp/simple.el (minibuffer-completing-symbol):
* lisp/font-lock.el (font-lock-beginning-of-syntax-function): Only mark read
access as obsolete.
* lisp/minibuffer.el (minibuffer-completing-file-name): Don't make it
obsolete yet.
* lisp/international/quail.el (quail-mouse-choose-completion): Remove unused
code referring to obsolete var.
(quail-choose-completion-string): Remove.
* lisp/server.el (server-clients-with, server-kill-buffer-query-function)
(server-kill-emacs-query-function): Silence "unused `proc'" warnings.
* lisp/proced.el (proced-send-signal):
* lisp/emacs-lisp/lisp.el (lisp-complete-symbol):
Replace completion-annotate-function with completion-extra-properties.
2011-06-01 16:32:04 -03:00
Juanma Barranquero
33256f149f lisp/font-lock.el: Remove obsolete code.
* font-lock.el (font-lock-refresh-defaults):
  Don't bind `hi-lock--inhibit-font-lock-hook', removed in
  2010-10-09T04:09:19Z!cyd@stupidchicken.com and 2010-10-11T23:57:49Z!lekktu@gmail.com
2011-04-05 17:20:21 +02:00
Glenn Morris
be99652196 font-lock.el tweak for bug#2159.
* lisp/font-lock.el (lisp-font-lock-keywords-1):
Don't highlight `)' in some setf expressions.
2011-03-07 20:28:14 -08:00
Glenn Morris
73b0cd5003 Convert consecutive FSF copyright years to ranges. 2011-01-24 20:08:28 -08:00
Glenn Morris
e9bffc61f2 Refill some copyright headers. 2011-01-15 18:21:30 -08:00
Stefan Monnier
77ab81d054 Merge from emacs-23 2011-01-14 12:18:41 -05:00
Chong Yidong
a03b542a78 * font-lock.el (font-lock-verbose): Default to nil. 2011-01-12 23:30:23 -05:00
Glenn Morris
5df4f04cd3 Add 2011 to FSF/AIST copyright years. 2011-01-02 15:50:46 -08:00
Glenn Morris
6aecca9993 Remove obsolete variable font-lock-defaults-alist.
* lisp/font-core.el (font-lock-defaults-alist): Remove variable.
(font-lock-mode): Doc fix.
(font-lock-default-function): Do not consult font-lock-defaults-alist.
* lisp/font-lock.el (font-lock-refresh-defaults): Doc fix.
(font-lock-set-defaults): Doc fix.
Do not consult font-lock-defaults-alist.

* etc/NEWS: Mention above change.
2010-10-05 21:14:05 -07:00
Juanma Barranquero
6664fc59a8 Merge changes from emacs-23 branch. 2010-09-14 16:41:53 +02:00
Stefan Monnier
71e657fcb8 * lisp/font-lock.el (font-lock-beginning-of-syntax-function):
Mark as obsolete.
2010-09-11 15:00:19 +02:00
Stefan Monnier
cf38dd4298 New syntax-propertize functionality.
* lisp/font-lock.el (font-lock-syntactic-keywords): Make obsolete.
(font-lock-fontify-syntactic-keywords-region): Move handling of
font-lock-syntactically-fontified to...
(font-lock-default-fontify-region): ...here.
Let syntax-propertize-function take precedence.
(font-lock-fontify-syntactically-region): Cal syntax-propertize.

* lisp/emacs-lisp/regexp-opt.el (regexp-opt-depth): Skip named groups.

* lisp/emacs-lisp/syntax.el (syntax-propertize-function)
(syntax-propertize-chunk-size, syntax-propertize--done)
(syntax-propertize-extend-region-functions): New vars.
(syntax-propertize-wholelines, syntax-propertize-multiline)
(syntax-propertize--shift-groups, syntax-propertize-via-font-lock)
(syntax-propertize): New functions.
(syntax-propertize-rules): New macro.
(syntax-ppss-flush-cache): Set syntax-propertize--done.
(syntax-ppss): Call syntax-propertize.

* lisp/progmodes/ada-mode.el (ada-set-syntax-table-properties)
(ada-after-change-function, ada-initialize-syntax-table-properties)
(ada-handle-syntax-table-properties): Only define when
syntax-propertize is not available.
(ada-mode): Use syntax-propertize-function.

* lisp/progmodes/autoconf.el (autoconf-mode):
Use syntax-propertize-function.
(autoconf-font-lock-syntactic-keywords): Remove.

* lisp/progmodes/cfengine.el (cfengine-mode):
Use syntax-propertize-function.
(cfengine-font-lock-syntactic-keywords): Remove.

* lisp/progmodes/cperl-mode.el (cperl-mode): Use syntax-propertize-function.

* lisp/progmodes/fortran.el (fortran-mode): Use syntax-propertize-function.
(fortran--font-lock-syntactic-keywords): New var.
(fortran-line-length): Update syntax-propertize-function and
fortran--font-lock-syntactic-keywords.

* lisp/progmodes/gud.el (gdb-script-syntax-propertize-function): New var;
replaces gdb-script-font-lock-syntactic-keywords.
(gdb-script-mode): Use it.

* lisp/progmodes/js.el (js--regexp-literal): Define while compiling.
(js-syntax-propertize-function): New var; replaces
js-font-lock-syntactic-keywords.
(js-mode): Use it.

* lisp/progmodes/make-mode.el (makefile-syntax-propertize-function):
New var; replaces makefile-font-lock-syntactic-keywords.
(makefile-mode): Use it.
(makefile-imake-mode): Adjust.

* lisp/progmodes/mixal-mode.el (mixal-syntax-propertize-function): New var;
replaces mixal-font-lock-syntactic-keywords.
(mixal-mode): Use it.

* lisp/progmodes/octave-mod.el (octave-syntax-propertize-sqs): New function
to replace octave-font-lock-close-quotes.
(octave-syntax-propertize-function): New function to replace
octave-font-lock-syntactic-keywords.
(octave-mode): Use it.

* lisp/progmodes/perl-mode.el (perl-syntax-propertize-function): New fun to
replace perl-font-lock-syntactic-keywords.
(perl-syntax-propertize-special-constructs): New fun to replace
perl-font-lock-special-syntactic-constructs.
(perl-font-lock-syntactic-face-function): New fun.
(perl-mode): Use it.

* lisp/progmodes/python.el (python-syntax-propertize-function): New var to
replace python-font-lock-syntactic-keywords.
(python-mode): Use it.
(python-quote-syntax): Simplify and adjust to new use.

* lisp/progmodes/ruby-mode.el (ruby-here-doc-beg-re):
Define while compiling.
(ruby-here-doc-end-re, ruby-here-doc-beg-match)
(ruby-font-lock-syntactic-keywords, ruby-comment-beg-syntax)
(syntax-ppss, ruby-in-ppss-context-p, ruby-in-here-doc-p)
(ruby-here-doc-find-end, ruby-here-doc-beg-syntax)
(ruby-here-doc-end-syntax): Only define when
syntax-propertize is not available.
(ruby-syntax-propertize-function, ruby-syntax-propertize-heredoc):
New functions.
(ruby-in-ppss-context-p): Update to new syntax of heredocs.
(electric-indent-chars): Silence bytecompiler.
(ruby-mode): Use prog-mode, syntax-propertize-function, and
electric-indent-chars.

* lisp/progmodes/sh-script.el (sh-st-symbol): Remove.
(sh-font-lock-close-heredoc, sh-font-lock-open-heredoc): Add eol arg.
(sh-font-lock-flush-syntax-ppss-cache, sh-font-lock-here-doc): Remove.
(sh-font-lock-quoted-subshell): Assume we've already matched $(.
(sh-font-lock-paren): Set syntax-multiline.
(sh-font-lock-syntactic-keywords): Remove.
(sh-syntax-propertize-function): New function to replace it.
(sh-mode): Use it.

* lisp/progmodes/simula.el (simula-syntax-propertize-function): New var to
replace simula-font-lock-syntactic-keywords.
(simula-mode): Use it.

* lisp/progmodes/tcl.el (tcl-syntax-propertize-function): New var to
replace tcl-font-lock-syntactic-keywords.
(tcl-mode): Use it.

* lisp/progmodes/vhdl-mode.el (vhdl-mode): Use syntax-propertize-function
if available.
(vhdl-fontify-buffer): Adjust.

* lisp/textmodes/bibtex.el (bibtex-mode): Use syntax-propertize-function.

* lisp/textmodes/reftex.el (font-lock-syntactic-keywords): Don't declare
since we don't use it.

* lisp/textmodes/sgml-mode.el (sgml-syntax-propertize-function): New var to
replace sgml-font-lock-syntactic-keywords.
(sgml-mode): Use it.

* lisp/textmodes/tex-mode.el (tex-common-initialization, doctex-mode):
Use syntax-propertize-function.

* lisp/textmodes/texinfo.el (texinfo-syntax-propertize-function): New fun
to replace texinfo-font-lock-syntactic-keywords.
(texinfo-mode): Use it.

* test/indent/octave.m: Remove some `fixindent' not needed any more.
2010-09-11 01:13:42 +02:00
Stefan Monnier
b073dc4b4b Misc cleanups and simplifications.
* lisp/font-lock.el (save-buffer-state): Remove `varlist' arg.
(font-lock-unfontify-region, font-lock-default-fontify-region):
Update usage correspondingly.
(font-lock-fontify-syntactic-keywords-region):
Set parse-sexp-lookup-properties buffer-locally here.
(font-lock-fontify-syntactically-region): Remove unused `ppss' arg.
* lisp/progmodes/ada-mode.el: Replace "(set '" with setq.
(ada-mode): Simplify.
(ada-create-case-exception, ada-adjust-case-interactive)
(ada-adjust-case-region, ada-format-paramlist, ada-indent-current)
(ada-search-ignore-string-comment, ada-move-to-start)
(ada-move-to-end): Use with-syntax-table.
* lisp/progmodes/fortran.el (fortran-line-length): Don't recompute
syntactic keywords redundantly a second time.
* lisp/progmodes/js.el (require): Require is already "eval-and-compile".
(js--re-search-forward): Avoid `eval'.  Preserve the error data.
(js--re-search-backward): Use js--re-search-forward.
* lisp/progmodes/octave-mod.el (electric-indent-chars): Silence bytecomp.
2010-09-08 18:21:23 +02:00