comparison lisp/emulation/cua-base.el @ 49898:53baa12e5cee

Add run-time check to catch users trying to use older versions of CUA-mode, rather than the version distributed with Emacs. Use autoload cookies and eval-after-load.
author Kim F. Storm <storm@cua.dk>
date Fri, 21 Feb 2003 12:50:47 +0000
parents 0d8b17d428b5
children bf90e6638915
comparison
equal deleted inserted replaced
49897:99cc7aecbbec 49898:53baa12e5cee
1247 (defun cua-debug () 1247 (defun cua-debug ()
1248 "Toggle cua debugging." 1248 "Toggle cua debugging."
1249 (interactive) 1249 (interactive)
1250 (setq cua--debug (not cua--debug))) 1250 (setq cua--debug (not cua--debug)))
1251 1251
1252 ;; Install run-time check for older versions of CUA-mode which does not
1253 ;; work with GNU Emacs version 21.4 and newer.
1254 ;;
1255 ;; Except for version 1.2, all of the 1.x and 2.x version of cua-mode
1256 ;; provided the `CUA-mode' feature. Since this is no longer true,
1257 ;; we can warn the user if the `CUA-mode' feature is ever provided.
1258
1259 ;;;###autoload (eval-after-load 'CUA-mode
1260 ;;;###autoload '(error (concat "\n\n"
1261 ;;;###autoload "CUA-mode is now part of the standard GNU Emacs distribution,\n"
1262 ;;;###autoload "so you may now enable and customize CUA via the Options menu.\n\n"
1263 ;;;###autoload "Your " (file-name-nondirectory user-init-file) " loads an older version of CUA-mode which does\n"
1264 ;;;###autoload "not work correctly with this version of GNU Emacs.\n"
1265 ;;;###autoload "To correct this, remove the loading and customization of the\n"
1266 ;;;###autoload "old version from the " user-init-file " file.\n\n")))
1267
1252 ;;; cua-base.el ends here 1268 ;;; cua-base.el ends here