summaryrefslogtreecommitdiff
path: root/lisp/cus-start.el
diff options
context:
space:
mode:
authorJan D <jan.h.d@swipnet.se>2015-04-26 13:55:01 +0200
committerJan D <jan.h.d@swipnet.se>2015-04-26 13:55:01 +0200
commitf92ac2e82ed199d6f25d2a59508e08addb1150ac (patch)
treed7d7756e3dbce10d8f73c27815d815499f78c2bd /lisp/cus-start.el
parent5a094119ce79723108abd90a1fcc33721e964823 (diff)
parenta40869789fc5502e3d4e393b7c31d78cb7f29aa1 (diff)
downloademacs-f92ac2e82ed199d6f25d2a59508e08addb1150ac.tar.gz
emacs-f92ac2e82ed199d6f25d2a59508e08addb1150ac.tar.bz2
emacs-f92ac2e82ed199d6f25d2a59508e08addb1150ac.zip
Merge branch 'master' into cairo
Diffstat (limited to 'lisp/cus-start.el')
-rw-r--r--lisp/cus-start.el74
1 files changed, 43 insertions, 31 deletions
diff --git a/lisp/cus-start.el b/lisp/cus-start.el
index 71506cb680e..071aaa6850f 100644
--- a/lisp/cus-start.el
+++ b/lisp/cus-start.el
@@ -1,4 +1,4 @@
-;;; cus-start.el --- define customization properties of builtins
+;;; cus-start.el --- define customization properties of builtins -*- lexical-binding:t -*-
;; Copyright (C) 1997, 1999-2015 Free Software Foundation, Inc.
@@ -33,6 +33,14 @@
;;; Code:
+(defun minibuffer-prompt-properties--setter (symbol value)
+ (set-default symbol value)
+ (if (memq 'cursor-intangible value)
+ (add-hook 'minibuffer-setup-hook 'cursor-intangible-mode)
+ ;; Removing it is a bit trickier since it could have been added by someone
+ ;; else as well, so let's just not bother.
+ ))
+
;; Elements of this list have the form:
;; SYMBOL GROUP TYPE VERSION REST...
;; SYMBOL is the name of the variable.
@@ -46,7 +54,23 @@
;; :risky - risky-local-variable property
;; :safe - safe-local-variable property
;; :tag - custom-tag property
-(let ((all '(;; alloc.c
+(let (standard native-p prop propval
+ ;; This function turns a value
+ ;; into an expression which produces that value.
+ (quoter (lambda (sexp)
+ ;; FIXME: We'd like to use macroexp-quote here, but cus-start
+ ;; is loaded too early in loadup.el for that.
+ (if (or (memq sexp '(t nil))
+ (keywordp sexp)
+ (and (listp sexp)
+ (memq (car sexp) '(lambda)))
+ (stringp sexp)
+ (numberp sexp))
+ sexp
+ (list 'quote sexp)))))
+ (pcase-dolist
+ (`(,symbol ,group ,type ,version . ,rest)
+ '(;; alloc.c
(gc-cons-threshold alloc integer)
(gc-cons-percentage alloc float)
(garbage-collection-messages alloc boolean)
@@ -145,7 +169,12 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of
(shell-file-name execute file)
(exec-path execute
(repeat (choice (const :tag "default directory" nil)
- (directory :format "%v"))))
+ (directory :format "%v")))
+ nil
+ :standard
+ (mapcar 'directory-file-name
+ (append (parse-colon-path (getenv "PATH"))
+ (list exec-directory))))
(exec-suffixes execute (repeat string))
;; charset.c
(charset-map-path installation
@@ -269,10 +298,10 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of
(make-pointer-invisible mouse boolean "23.2")
(menu-bar-mode frames boolean nil
;; FIXME?
-; :initialize custom-initialize-default
+ ;; :initialize custom-initialize-default
:set custom-set-minor-mode)
(tool-bar-mode (frames mouse) boolean nil
-; :initialize custom-initialize-default
+ ;; :initialize custom-initialize-default
:set custom-set-minor-mode)
(frame-resize-pixelwise frames boolean "24.4")
(frame-inhibit-implied-resize frames
@@ -342,19 +371,19 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of
:doc "Prevent point from ever entering prompt"
:format "%t%n%h"
:inline t
- (point-entered minibuffer-avoid-prompt)))
+ (cursor-intangible t)))
(repeat :inline t
:tag "Other Properties"
(list :inline t
:format "%v"
(symbol :tag "Property")
(sexp :tag "Value"))))
- "21.1")
+ "21.1"
+ :set minibuffer-prompt-properties--setter)
(minibuffer-auto-raise minibuffer boolean)
;; options property set at end
(read-buffer-function minibuffer
(choice (const nil)
- (function-item iswitchb-read-buffer)
function))
;; msdos.c
(dos-unsupported-char-glyph display integer)
@@ -550,27 +579,7 @@ since it could result in memory overflow and make Emacs crash."
(x-select-enable-clipboard-manager killing boolean "24.1")
;; xsettings.c
(font-use-system-font font-selection boolean "23.2")))
- this symbol group type standard version native-p rest prop propval
- ;; This function turns a value
- ;; into an expression which produces that value.
- (quoter (lambda (sexp)
- (if (or (memq sexp '(t nil))
- (keywordp sexp)
- (and (listp sexp)
- (memq (car sexp) '(lambda)))
- (stringp sexp)
- (numberp sexp))
- sexp
- (list 'quote sexp)))))
- (while all
- (setq this (car all)
- all (cdr all)
- symbol (nth 0 this)
- group (nth 1 this)
- type (nth 2 this)
- version (nth 3 this)
- rest (nthcdr 4 this)
- ;; If we did not specify any standard value expression above,
+ (setq ;; If we did not specify any standard value expression above,
;; use the current value as the standard value.
standard (if (setq prop (memq :standard rest))
(cadr prop)
@@ -628,7 +637,11 @@ since it could result in memory overflow and make Emacs crash."
(put symbol 'custom-set (cadr prop)))
;; Note this is the _only_ initialize property we handle.
(if (eq (cadr (memq :initialize rest)) 'custom-initialize-delay)
- (push symbol custom-delayed-init-variables))
+ ;; These vars are defined early and should hence be initialized
+ ;; early, even if this file happens to be loaded late. so add them
+ ;; to the end of custom-delayed-init-variables. Otherwise,
+ ;; auto-save-file-name-transforms will appear in M-x customize-rogue.
+ (add-to-list 'custom-delayed-init-variables symbol 'append))
;; If this is NOT while dumping Emacs, set up the rest of the
;; customization info. This is the stuff that is not needed
;; until someone does M-x customize etc.
@@ -649,7 +662,6 @@ since it could result in memory overflow and make Emacs crash."
((eq prop :tag)
(put symbol 'custom-tag propval))))))))
-(custom-add-to-group 'iswitchb 'read-buffer-function 'custom-variable)
(custom-add-to-group 'font-lock 'open-paren-in-column-0-is-defun-start
'custom-variable)