Commit 39ead8cd authored by Stefan Monnier's avatar Stefan Monnier

* lisp/progmodes/cc-cmds.el (c-subword-mode): Alias to subword-mode.

(c-update-modeline):
* lisp/progmodes/cc-langs.el (c-mode-menu): Use c-subword-mode.
* lisp/progmodes/cc-mode.el (subword-mode): Move autoload to cc-cmds.el.
(c-mode-base-map): Use c-subword-mode.
parent b1978229
2014-12-18 Stefan Monnier <monnier@iro.umontreal.ca>
* progmodes/cc-cmds.el (c-subword-mode): Alias to subword-mode.
(c-update-modeline):
* progmodes/cc-langs.el (c-mode-menu): Use c-subword-mode.
* progmodes/cc-mode.el (subword-mode): Move autoload to cc-cmds.el.
(c-mode-base-map): Use c-subword-mode.
2014-12-18 Eli Zaretskii <eliz@gnu.org>
* international/mule-diag.el (describe-font-internal): Display
additional info returned by font-info.
* international/mule-diag.el (describe-font-internal):
Display additional info returned by font-info.
* linum.el (linum--face-width): Rename from linum--face-height,
and use the new functionality of font-info.
......@@ -21,8 +29,8 @@
2014-12-17 Sam Steingold <sds@gnu.org>
* emacs-lisp/package.el (package--list-loaded-files): Handle
`(nil ...)' elements in `load-history'.
* emacs-lisp/package.el (package--list-loaded-files):
Handle `(nil ...)' elements in `load-history'.
2014-12-17 Teodor Zlatanov <tzz@lifelogs.com>
......@@ -152,8 +160,8 @@
2014-12-13 Fabián Ezequiel Gallina <fgallina@gnu.org>
* progmodes/python.el (python-shell-parse-command): Quote
`python-shell-interpreter`. (Bug#19289)
* progmodes/python.el (python-shell-parse-command):
Quote `python-shell-interpreter`. (Bug#19289)
2014-12-12 Stefan Monnier <monnier@iro.umontreal.ca>
......
......@@ -258,9 +258,11 @@ With universal argument, inserts the analysis as a comment on that line."
"a" "")
(if c-hungry-delete-key "h" "")
(if (and
;; subword might not be loaded.
(boundp 'subword-mode)
(symbol-value 'subword-mode))
;; (cc-)subword might not be loaded.
(boundp 'c-subword-mode)
(symbol-value 'c-subword-mode))
;; FIXME: subword-mode already comes with its
;; own lighter!
"w"
"")))
;; FIXME: Derived modes might want to use something else
......@@ -1304,6 +1306,17 @@ keyword on the line, the keyword is not inserted inside a literal, and
(declare-function subword-forward "subword" (&optional arg))
(declare-function subword-backward "subword" (&optional arg))
(cond
((and (fboundp 'subword-mode) (not (fboundp 'c-subword-mode)))
;; Recent Emacsen come with their own subword support. Use that.
(define-obsolete-function-alias 'c-subword-mode 'subword-mode "24.3")
(define-obsolete-variable-alias 'c-subword-mode 'subword-mode "24.3"))
(t
;; Autoload directive for emacsen that doesn't have an older CC Mode
;; version in the dist.
(autoload 'c-subword-mode "cc-subword"
"Mode enabling subword movement and editing keys." t)))
;; "nomenclature" functions + c-scope-operator.
(defun c-forward-into-nomenclature (&optional arg)
"Compatibility alias for `c-forward-subword'."
......
......@@ -318,9 +318,9 @@ the evaluated constant value at compile time."
:style toggle :selected c-auto-newline]
["Hungry delete" c-toggle-hungry-state
:style toggle :selected c-hungry-delete-key]
["Subword mode" subword-mode
:style toggle :selected (and (boundp 'subword-mode)
subword-mode)])))
["Subword mode" c-subword-mode
:style toggle :selected (and (boundp 'c-subword-mode)
c-subword-mode)])))
;;; Syntax tables.
......
......@@ -108,11 +108,6 @@
;; with your version of Emacs, you are incompatible!
(cc-external-require 'easymenu)
;; Autoload directive for emacsen that doesn't have an older CC Mode
;; version in the dist.
(autoload 'subword-mode "subword"
"Mode enabling subword movement and editing keys." t)
;; Load cc-fonts first after font-lock is loaded, since it isn't
;; necessary until font locking is requested.
; (eval-after-load "font-lock" ; 2006-07-09: font-lock is now preloaded.
......@@ -379,7 +374,7 @@ control). See \"cc-mode.el\" for more info."
;; conflicts with OOBR
;;(define-key c-mode-base-map "\C-c\C-v" 'c-version)
;; (define-key c-mode-base-map "\C-c\C-y" 'c-toggle-hungry-state) Commented out by ACM, 2005-11-22.
(define-key c-mode-base-map "\C-c\C-w" 'subword-mode)
(define-key c-mode-base-map "\C-c\C-w" 'c-subword-mode)
)
;; We don't require the outline package, but we configure it a bit anyway.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment