1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-12-11 09:20:51 +00:00
Commit Graph

2287 Commits

Author SHA1 Message Date
Chong Yidong
9173a8fbd7 Cleanup of window coordinate positioning code.
Now, text area click input events measure Y from the top of the text
area, excluding the header line if any.

* src/dispnew.c (buffer_posn_from_coords): Assume that X counts from
the start of the text area.

* src/keyboard.c (make_lispy_position): For text area clicks, record Y
pixel position relative to the text area, excluding header line.
Also change X and Y to Lisp_Objects, not pointers; don't return
coordinate values via pointers.  Pass ON_TEXT_AREA coordinate to
buffer_posn_from_coords counting from the start of the text area.
(Fposn_at_x_y, make_lispy_event): Callers changed.

* src/w32term.c (w32_read_socket):
* src/msdos.c (dos_rawgetc):
* src/xterm.c (handle_one_xevent): Likewise.

* src/window.c (coordinates_in_window): Change X and Y to ints rather
than pointers; don't return coordinates via pointers.
(struct check_window_data): Change X and Y from pointers to ints.
(window_from_coordinates): Remove args WX and WY; don't return
coordinates via pointers.
(Fcoordinates_in_window_p, window_from_coordinates):
(check_window_containing, Fwindow_at): Callers changed.
(window_relative_x_coord): New function.

* src/window.h (window_from_coordinates, window_relative_x_coord):
Update prototypes.

* src/xdisp.c (remember_mouse_glyph): Change window_from_coordinates
call.  Use window_relative_x_coord.
(note_mouse_highlight): Change window_from_coordinates call.
2010-11-16 21:37:45 -05:00
Chong Yidong
1985927ce8 Revert changes in 2010-11-16T19:59:24Z!cyd@stupidchicken.com 2010-11-16 16:47:43 -05:00
Stefan Monnier
7100ff9844 * lisp/electric.el (electric-layout-mode): New minor mode.
(electric--after-char-pos): New function.
(electric-indent-post-self-insert-function): Use it.
(electric-layout-rules): New var.
(electric-layout-post-self-insert-function): New function.
(electric-indent-mode): Make them interact better.
2010-11-16 16:14:46 -05:00
Chong Yidong
77cd1a622a Cleanup of window coordinate positioning code.
Now, text area click input events measure Y from the top of the text
area, excluding the header line if any.

* src/dispnew.c (buffer_posn_from_coords): Assume that X counts from
the start of the text area.

* src/keyboard.c (make_lispy_position): For text area clicks, record Y
pixel position relative to the text area, excluding header line.
Also change X and Y to Lisp_Objects, not pointers; don't return
coordinate values via pointers.  Pass ON_TEXT_AREA coordinate to
buffer_posn_from_coords counting from the start of the text area.
(Fposn_at_x_y, make_lispy_event): Callers changed.

* src/w32term.c (w32_read_socket):
* src/msdos.c (dos_rawgetc):
* src/xterm.c (handle_one_xevent): Likewise.

* src/window.c (coordinates_in_window): Change X and Y to ints rather
than pointers; don't return coordinates via pointers.
(struct check_window_data): Change X and Y from pointers to ints.
(window_from_coordinates): Remove args WX and WY; don't return
coordinates via pointers.
(Fcoordinates_in_window_p, window_from_coordinates):
(check_window_containing, Fwindow_at): Callers changed.
(window_relative_x_coord): New function.

* src/window.h (window_from_coordinates, window_relative_x_coord):
Update prototypes.

* src/xdisp.c (remember_mouse_glyph): Change window_from_coordinates
call.  Use window_relative_x_coord.
(note_mouse_highlight): Change window_from_coordinates call.
2010-11-16 14:59:24 -05:00
Eli Zaretskii
0eb025fb55 Fix and document display of glyphless characters.
src/xdisp.c (set_cursor_from_row): Fix cursor positioning on
 zero-width characters.
 (syms_of_xdisp) <glyphless-char-display>: Doc fix.
 src/.gdbinit (pgx): Adapt to latest changes in `struct glyph'.
 src/w32term.c (x_draw_glyphless_glyph_string_foreground): Draw the
 box before drawing the glyphs inside it.
 src/dispextern.h (enum glyphless_display_method): Rename
 GLYPHLESS_DISPLAY_HEXA_CODE to GLYPHLESS_DISPLAY_HEX_CODE.  All
 users changed.
 src/term.c (append_glyphless_glyph, produce_glyphless_glyph): Fix
 comments.
 (produce_glyphless_glyph): Enclose "U+nnnn" and "empty box"
 whitespace in "[]", to simulate a box.  Don't use uninitialized
 variable `width'.
 lisp/international/characters.el (glyphless-char-display-control):
 Renamed from glyphless-char-control; all users changed.  Doc fix.
 Signal an error if display method is not one of the recognized
 symbols.
 doc/emacs/rmail.texi (Rmail Coding): Characters with no fonts are not
 necessarily displayed as empty boxes.
 doc/emacs/mule.texi (Language Environments, Fontsets): Characters with no
 fonts are not necessarily displayed as empty boxes.
 doc/emacs/display.texi (Text Display): Document display of glyphless
 characters.
 doc/lispref/display.texi (Usual Display): Characters with no fonts are not
 necessarily displayed as empty boxes.
 etc/NEWS: Document display of glyphless characters.
2010-11-13 15:29:31 +02:00
Glenn Morris
ea4f775071 Document count-words-region.
* doc/emacs/basic.texi (Position Info): Add M-x count-words-region.

* doc/lispintro/emacs-lisp-intro.texi: Rename the `count-words-region' example,
since there is now a standard command of that name.

* etc/NEWS: Mention it.
2010-11-12 19:48:16 -08:00
Stefan Monnier
78835dd054 * lisp/shell.el (shell-dir-cookie-re): New custom variable.
(shell-dir-cookie-watcher): New function.
2010-11-12 09:13:48 -05:00
Stefan Monnier
cbf83ce9f9 * lisp/progmodes/modula2.el: Use SMIE and skeleton.
(m2-mode-syntax-table): (*..*) can be nested.
Add //...\n.  Fix paren syntax.
(m2-mode-map): Remove LF and TAB bindings.
(m2-indent): Add safety property.
(m2-smie-grammar): New var.
(m2-smie-refine-colon, m2-smie-refine-of, m2-smie-backward-token)
(m2-smie-forward-token, m2-smie-refine-semi, m2-smie-rules): New funs.
(m2-mode): Use define-derived-mode.
(m2-newline, m2-tab): Remove.
(m2-begin, m2-case, m2-definition, m2-else, m2-for, m2-header)
(m2-if, m2-loop, m2-module, m2-or, m2-procedure, m2-with, m2-record)
(m2-stdio, m2-type, m2-until, m2-var, m2-while, m2-export)
(m2-import): Use define-skeleton.
* test/indent/modula2.mod: New file.
2010-11-11 16:06:15 -05:00
Lars Magne Ingebrigtsen
5c0c0f77b0 Decode utf-8 strings in mixed environments by default.
Done via the new `erc-coding-system-precedence' variable.
2010-11-05 15:17:46 +01:00
Chong Yidong
7977dcb80e etc/NEWS: Move --with-crit-dir option to emacs-23. 2010-11-03 15:53:47 -04:00
Chong Yidong
42d9cffad2 etc/NEWS: Remove VC changes, since they are backported to 23.3.
Edit selection changes.
2010-10-31 23:20:57 -04:00
Chong Yidong
33658d4e47 etc/NEWS: Add placeholder for finder-inf.el changes. 2010-10-30 20:24:34 -04:00
Stefan Monnier
c4d17d50ea SMIE: change indent rules format, improve smie-setup.
* lisp/emacs-lisp/smie.el (smie-precs-precedence-table)
(smie-merge-prec2s, smie-bnf-precedence-table, smie-prec2-levels):
Mark them pure so the tables gets built at compile time.
(smie-bnf-precedence-table): Store the closer-alist in the table.
(smie-prec2-levels): Preserve the closer-alist.
(smie-blink-matching-open): Be more forgiving in case of indentation.
(smie-hanging-p): Rename from smie-indent--hanging-p.
(smie-bolp): Rename from smie-indent--bolp.
(smie--parent, smie--after): New dynamic vars.
(smie-parent-p, smie-next-p, smie-prev-p): New funs.
(smie-indent-rules): Remove.
(smie-indent--offset-rule): Remove fun.
(smie-rules-function): New var.
(smie-indent--rule): New fun.
(smie-indent--offset, smie-indent-keyword, smie-indent-after-keyword)
(smie-indent-exps): Use it.
(smie-setup): Setup paren blinking; add keyword args for token
functions; extract closer-alist from op-levels.
(smie-indent-debug-log): Remove var.
(smie-indent-debug): Remove fun.
* lisp/progmodes/prolog.el (prolog-smie-indent-rules): Remove.
(prolog-smie-rules): New fun to replace it.
(prolog-mode-variables): Simplify.
* lisp/progmodes/octave-mod.el (octave-smie-closer-alist): Remove, now that
it's setup automatically.
(octave-smie-indent-rules): Remove.
(octave-smie-rules): New fun to replace it.
(octave-mode): Simplify.
2010-10-29 15:20:28 -04:00
Glenn Morris
1d83b0e93e Mention server-port. 2010-10-26 00:42:46 -07:00
Chong Yidong
9317e49920 Merge read-color and facemenu-read-color (Bug#7242).
* lisp/facemenu.el (facemenu-read-color): Alias for read-color.
(facemenu-set-foreground, facemenu-set-background): Use
read-color.

* lisp/faces.el (read-color): Use the completion code from
facemenu-read-color.  Require match in completion.  Doc fix.

* lisp/frame.el (set-background-color, set-foreground-color)
(set-cursor-color, set-mouse-color, set-border-color): Use
read-color.
2010-10-24 14:43:31 -04:00
Jan Djärv
a6ac7fc4fd Mention faceName for Lucid menu/dialog fonts. 2010-10-23 11:18:19 +02:00
Glenn Morris
17284e3024 Replace digest-doc and sorted-doc C programs with Lisp commands.
* lib-src/digest-doc.c, lib-src/sorted-doc.c: Remove files.
* lib-src/Makefile.in (UTILITIES): Remove digest-doc and sorted-doc.
(digest-doc${EXEEXT}, sorted-doc${EXEEXT}): Remove rules.
* lib-src/makefile.w32-in (ALL): Remove digest-doc and sorted-doc.
($(BLD)/sorted-doc.exe, $(BLD)/digest-doc.exe, sorted-doc, digest-doc)
($(BLD)/digest-doc.$(O), $(BLD)/sorted-doc.$(O)): Remove rules.
(install): Don't install digest-doc.exe or sorted-doc.exe.

* lisp/help-fns.el (doc-file-to-man, doc-file-to-info): New commands.

* doc/lispref/help.texi (Documentation Basics): Remove mentions of
digest-doc and sorted-doc.

* INSTALL, nt/README, nt/README.W32: Do not mention digest-doc and sorted-doc.

* etc/NEWS: Mention this change.
2010-10-22 19:46:06 -07:00
Chong Yidong
917794d547 etc/NEWS: Document change to mode-line-format. 2010-10-19 15:24:39 -04:00
Chong Yidong
782b5e8d92 Move built-in theme directory to etc/.
* custom.el: Custom themes no longer use load-path.
(custom-theme-load-path): New option.  Change built-in theme
directory to etc/.
(custom-enabled-themes): Add custom-theme-load-path dependency.
(custom-theme--load-path): New function.
(load-theme, custom-available-themes): Use it.

* cus-theme.el (describe-theme-1): Use custom-theme--load-path.
(customize-themes): Link to custom-theme-load-path variable.
2010-10-16 14:27:08 -04:00
Eli Zaretskii
4c0f50c956 Fix last change in etc/NEWS. 2010-10-15 18:44:01 +02:00
Eli Zaretskii
7c9b11be16 Fix bug #7196.
NEWS: Expand the entry about "Selection changes".
2010-10-15 13:33:17 +02:00
Eli Zaretskii
d1b08c883f Fix bug #7195 with NEWS entry for of select-active-region'. 2010-10-15 13:00:57 +02:00
Juanma Barranquero
2e288d54f0 Rename image-library-alist' to dynamic-library-alist'.
* etc/NEWS: Mention `dynamic-library-alist'.

* lisp/image.el (image-library-alist): Declare as obsolete alias.
  (image-type-available-p): Use `dynamic-library-alist'.

* lisp/term/w32-win.el (dynamic-library-alist):
  Use instead of `image-library-alist'.

* nt/INSTALL: Refer to `dynamic-library-alist'.

* src/image.c (Vimage_library_alist)
  (syms_of_image) <image-library-alist>: Move to src/emacs.c and rename.
  (lookup_image_type): Use Vdynamic_library_alist.
  (Finit_image_library): Doc fix.

* src/emacs.c (Vdynamic_library_alist)
  (syms_of_emacs) <dynamic-library-alist>: Move from src/image.c and rename.
  Doc fix.

* src/lisp.h (Vdynamic_library_alist): Declare extern.
2010-10-13 16:50:06 +02:00
Chong Yidong
f065864f08 Placeholder entry for Custom theme changes. 2010-10-11 23:12:33 -04:00
Glenn Morris
360ac53066 etc/NEWS. 2010-10-07 20:17:31 -07: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
Glenn Morris
4583e7960f * lisp/emacs-lisp/cl.el: No longer provide cl-19.
* etc/NEWS: Mention this change.
2010-10-05 19:30:53 -07:00
Glenn Morris
7b0e3048f0 NEWS update. 2010-10-04 21:19:58 -07:00
Dan Nicolaescu
1fbcf4289f Mention the 'g' binding in VC diff,log, etc. 2010-10-03 17:43:11 -07:00
Glenn Morris
77f3894962 Remove directory-sep-char, obsolete since 21.1.
* lisp/subr.el (directory-sep-char): Remove obsolete variable.
* lisp/net/tramp-compat.el: Don't mess about with the byte-compiler unless
it is "necessary".

* doc/lispref/files.texi (File Name Components): Remove ignored
section about deleted variable directory-sep-char.

* etc/NEWS: Mention above change.
2010-10-03 14:23:13 -07:00
Glenn Morris
67141a37c1 Remove vc-header-alist, obsolete since 21.1.
* lisp/vc/vc-hooks.el (vc-header-alist): Remove obsolete variable.
* lisp/vc/vc.el (vc-static-header-alist): Doc fix.
* lisp/vc/vc-cvs.el (vc-cvs-header):
* lisp/vc/vc-rcs.el (vc-rcs-header):
* lisp/vc/vc-sccs.el (vc-sccs-header):
* lisp/vc/vc-svn.el (vc-svn-header): Do not consult vc-header-alist.
* lisp/obsolete/vc-mcvs.el (vc-mcvs-header):
* lisp/progmodes/cperl-mode.el (cperl-mode): Only set vc-header-alist
on XEmacs.

* etc/NEWS: Mention above change.
2010-10-03 14:05:47 -07:00
Michael Albinus
4ddf410ae5 Add user option `remote-file-name-inhibit-cache'. 2010-10-03 18:43:22 +02:00
Glenn Morris
922ad43e81 * lisp/subr.el (make-local-hook): Remove function obsolete since 21.1.
* lisp/progmodes/cc-mode.el (make-local-hook): Don't do cc-bytecomp stuff.
(c-basic-common-init, c-font-lock-init): Only call make-local-hook on
XEmacs.
* lisp/progmodes/cc-styles.el (make-local-hook): Don't do cc-bytecomp stuff.
(c-make-styles-buffer-local): Only call make-local-hook on XEmacs.

* lisp/gnu/gnus-util.el (gnus-make-local-hook): Simplify.

* etc/NEWS: Mention above change.
2010-10-02 18:53:04 -07:00
Chong Yidong
2a847524ab * lisp/server.el (server-process-filter, server-return-error): Give
emacsclient time to shut down after receiving an error string.

* etc/NEWS: Document tweak to emacsclient exit status.
2010-10-02 20:03:44 -04:00
Eli Zaretskii
383ebd154f Invoke kill-emacs on SIGINT on Windows as well.
src/emacs.c (main): Remove !WINDOWSNT conditional.
 (Fkill_emacs): Don't mention exemption on MS-Windows.
 etc/NEWS: Fix the news entry regarding SIGINT in batch mode.
2010-10-02 10:24:14 +02:00
Glenn Morris
3226d6cacf Remove some functions, variables and aliases obsolete since at least 21.1.
* doc/misc/misc.texi (Shell Mode): Remove reference to old function name.

* src/character.c (Fchar_bytes): Remove obsolete function.
(syms_of_character): Remove Schar_bytes.
* lisp/subr.el (char-bytes): Remove obsolete function.

* lisp/emacs-lisp/checkdoc.el (checkdoc-minor-keymap): Remove obsolete alias.

* lisp/isearch.el (isearch-return-char): Remove obsolete function.

* lisp/mouse.el: No longer provide mldrag.
(mldrag-drag-mode-line, mldrag-drag-vertical-line):
Remove obsolete aliases.

* lisp/comint.el (comint-kill-output): Remove obsolete alias.

* lisp/shell.el: Comment fix.

* lisp/composite.el (decompose-composite-char): Remove obsolete function.
* lisp/ps-def.el (decompose-composite-char): Remove unused function.

* lisp/iswitchb.el (iswitchb-default-keybindings): Remove obsolete function.

* lisp/outline.el (outline-visible): Remove obsolete function.

* lisp/term/pc-win.el (x-frob-font-slant, x-frob-font-weight):
* lisp/faces.el (internal-find-face, internal-get-face)
(frame-update-faces, frame-update-face-colors)
(x-frob-font-weight, x-frob-font-slant)
(internal-frob-font-weight, internal-frob-font-slant)
(x-make-font-bold, x-make-font-demibold, x-make-font-unbold)
(x-make-font-italic, x-make-font-oblique, x-make-font-unitalic)
(x-make-font-bold-italic): Remove functions and aliases, obsolete
since Emacs 21.1.
* lisp/emulation/viper-util.el (viper-get-face):
* lisp/obsolete/lucid.el (find-face, get-face): Use facep.
* lisp/vc/ediff-init.el (ediff-valid-color-p, ediff-get-face):
Remove unused functions.
* lisp/vc/ediff-util.el (ediff-submit-report): Doc fix.

* etc/NEWS: Mention above changes.
2010-10-01 19:46:13 -07:00
Glenn Morris
9c524fcb89 Run kill-emacs-hook in batch mode, and on SIGINT in batch mode.
See thread http://lists.gnu.org/archive/html/emacs-devel/2010-09/msg00795.html

* src/emacs.c (fatal_error_signal): Also run Fkill_emacs on SIGINT.
(main) [!WINDOWSNT]: Handle SIGINT with fatal_error_signal
in batch-mode.
(Fkill_emacs): Doc fix.  Also run the hook in batch mode.
(kill-emacs-hook): Doc fix.

* lisp/emacs-lisp/bytecomp.el (byte-compile-file): Use kill-emacs-hook to
delete tempfile if interrupted during compilation.

* doc/lispref/os.texi (Killing Emacs): Hook now runs in batch mode.

* etc/NEWS: Mention these changes.
2010-10-01 19:30:11 -07:00
Glenn Morris
cf16af4234 etc/NEWS updates. 2010-09-29 19:23:25 -07:00
Glenn Morris
b2fa3a0916 Minor NEWS fix. 2010-09-27 19:41:18 -07:00
Lars Magne Ingebrigtsen
8ea189f7bf Compile with imagemagick support by default. 2010-09-27 22:53:35 +02:00
Chong Yidong
4b9832a6f2 Rename libxml2 functions, and make parse tree format consistent with xml.el.
* xml.c: Switch to GNU indentation.
(make_dom): Change parse tree format to match xml.el.
(Fxml_parse_html_string_internal): Rename from html-parse-string.
(Fxml_parse_string_internal): Rename from xml-parse-string.

* configure.in: Announce whether libxml2 is linked to.
2010-09-21 23:10:16 -04:00
Michael Mauger
7479021013 SQL Mode, Version 2.8 - sql-list-all and sql-list-table functions.
* progmodes/sql.el: Version 2.8
	(sql-login-params): Updated widget structure; changes still
	needed.
	(sql-product-alist): Add :list-all and :list-table features for
	SQLite, Postgres and MySQL products.
	(sql-redirect): Handle default value.
	(sql-execute, sql-execute-feature): New functions.
	(sql-read-table-name): New function.
	(sql-list-all, sql-list-table): New functions. User API
	(sql-mode-map, sql-interactive-mode-map): Add key definitions
	for above functions.
	(sql-mode-menu, sql-interactive-mode-menu): Add menu definitions
	for above functions.
	(sql-postgres-login-params): Add user and database defaults.
	(sql-buffer-live-p): Bug fix.
	(sql-product-history); New variable.
	(sql-read-product): New function. Use it.
	(sql-set-product, sql-product-interactive): Use it.
	(sql-connection-history): New variable.
	(sql-read-connection): New function. Use it.
	(sql-connect): New function.
	(sql-for-each-login): Redesign function interface.
	(sql-make-alternate-buffer-name, sql-save-connection): Use it.
	(sql-get-login-ext, sql-get-login): Use it. Handle default values.
	(sql-comint): Check for program. Existing live buffer.
	(sql-comint-postgres): Add port parameter.
2010-09-18 22:11:18 -04:00
Esa Peuha
b2957ea8ea Fix typos in etc/NEWS. 2010-09-18 11:15:02 +02:00
Stefan Monnier
b879a6e297 Fix and improve last syntax-propertize patch
* lisp/emacs-lisp/syntax.el (syntax-propertize-precompile-rules): New macro.
(syntax-propertize-rules): Add var-ref case.  Fix offset computation
when adding surrounding \(..\).

* lisp/progmodes/fortran.el (fortran--font-lock-syntactic-keywords): Remove.
(fortran-make-syntax-propertize-function): New function; replaces
fortran-font-lock-syntactic-keywords.
(fortran-mode): Use it.
(fortran-line-length): Use it.  Improve interactive spec.

* lisp/progmodes/js.el (js-mode): Fix last change (bug#7054).

* lisp/textmodes/tex-mode.el (tex-syntax-propertize-rules)
(latex-syntax-propertize-rules): New consts; replace
tex-font-lock-syntactic-keywords.
(tex-env-mark, latex-env-before-change): New functions.
(latex-electric-env-pair-mode): New minor mode.
(tex-font-lock-verb): Change arguments; do move point.
(tex-font-lock-syntactic-face-function): Adjust to new verbatim
representation as a form of comment.
(tex-font-lock-keywords-1): Remove workaround, now unneeded.
(doctex-syntax-propertize-rules): New const; replaces
doctex-font-lock-syntactic-keywords.
(tex-common-initialization, doctex-mode): Use syntax-propertize-rules.
2010-09-18 02:35:00 +02:00
Michael Albinus
459bba37ea * NEWS: Some Tramp methods are discontinued. 2010-09-13 17:43:33 +02:00
Stefan Monnier
7cf78aac59 * doc/lispref/syntax.texi (Syntax Flags): Document new `c' flag. 2010-09-11 15:58:57 +02:00
Michael Mauger
9250002f81 SQL Mode, Version 2.6
* progmodes/sql.el: Version 2.6
	(sql-dialect): Synonym for "sql-product".
	(sql-find-sqli-buffer, sql-set-sqli-buffer-generally)
	(sql-set-sqli-buffer, sql-show-sqli-buffer, sql-interactive-mode):
	Set "sql-buffer" to buffer name not buffer object so multiple sql
	interactive buffers work properly.  Reverts misguided changes in
	earlier work.
	(sql-comint): Make sure different buffer name is used if "*SQL*"
	buffer is for a different product.
	(sql-make-alternate-buffer-name): Fix bug with "sql-database"
	login param.
	(sql-oracle, sql-sybase, sql-informix, sql-sqlite, sql-mysql)
	(sql-solid, sql-ingres, sql-ms, sql-postgres, sql-interbase)
	(sql-db2, sql-linter, sql-product-interactive, sql-rename-buffer):
	Accept new buffer name or prompt for one.
	(sql-port): Default to zero.
	(sql-comint-mysql): Handle "sql-port" as a numeric.
	(sql-port-history): Delete unused variable.
	(sql-get-login): Default "sql-port" to a number.
	(sql-product-alist): Correct Postgres prompt and terminator
	regexp.
	(sql-sqlite-program): Dynamically detect presence of "sqlite" or
	"sqlite3" executables.
	(sql-sqlite-login-params): Add "*.sqlite[23]?" database name
	pattern.
	(sql-buffer-live-p): New function.
	(sql-mode-menu, sql-send-string): Use it.
	(sql-mode-oracle-font-lock-keywords): Improve SQL*Plus REMARK
	syntax pattern.
	(sql-mode-postgres-font-lock-keywords): Support Postgres V9.
	(sql-mode-sqlite-font-lock-keywords): Hilight sqlite commands.
2010-09-10 23:17:02 -04: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
Lars Magne Ingebrigtsen
71c17aecc3 * NEWS: Mention the new libxml2 functions. 2010-09-10 19:51:48 +02:00
Glenn Morris
8740c12d69 * etc/NEWS: Misc fixes for ImageMagick section. 2010-09-08 19:21:12 -07:00