From: Kim F. Storm Date: Sun, 6 Oct 2002 21:34:07 +0000 (+0000) Subject: (cua-normal-cursor-color): Fixed X-Git-Tag: ttn-vms-21-2-B4~12924 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=496c17d61b1f48506c6e4a34d851121d60033210;p=emacs.git (cua-normal-cursor-color): Fixed initialization to make "Erase Customization" work. --- diff --git a/lisp/emulation/cua-base.el b/lisp/emulation/cua-base.el index c906690356d..5f8fc8533da 100644 --- a/lisp/emulation/cua-base.el +++ b/lisp/emulation/cua-base.el @@ -425,20 +425,19 @@ Can be toggled by [M-p] while the rectangle is active," :type 'boolean :group 'cua) -(defcustom cua-normal-cursor-color nil +(defcustom cua-normal-cursor-color (or (and (boundp 'initial-cursor-color) initial-cursor-color) + (and (boundp 'initial-frame-alist) + (assoc 'cursor-color initial-frame-alist) + (cdr (assoc 'cursor-color initial-frame-alist))) + (and (boundp 'default-frame-alist) + (assoc 'cursor-color default-frame-alist) + (cdr (assoc 'cursor-color default-frame-alist))) + (frame-parameter nil 'cursor-color) + "red") "Normal (non-overwrite) cursor color. Also used to indicate that rectangle padding is not in effect. -Automatically loaded from frame parameters, if nil." - :initialize (lambda (symbol value) - (set symbol (or value - (and (boundp 'initial-cursor-color) initial-cursor-color) - (and (boundp 'initial-frame-alist) - (assoc 'cursor-color initial-frame-alist) - (cdr (assoc 'cursor-color initial-frame-alist))) - (and (boundp 'default-frame-alist) - (assoc 'cursor-color default-frame-alist) - (cdr (assoc 'cursor-color default-frame-alist))) - (frame-parameter nil 'cursor-color)))) +Default is to load cursor color from initial or default frame parameters." + :initialize 'custom-initialize-default :type 'color :group 'cua)