X-Git-Url: https://git.distorted.org.uk/~mdw/profile/blobdiff_plain/e8532c79c42b256fe1db82e60fc70d6dc78a5ded..9817e1919d7fc19194c63e87ddafe1e3e04cb538:/dot/emacs?ds=sidebyside diff --git a/dot/emacs b/dot/emacs index 035d132..8749882 100644 --- a/dot/emacs +++ b/dot/emacs @@ -33,7 +33,7 @@ (if (file-exists-p boot) (load boot)))) -(require 'cl) +(require 'cl-lib) (require 'dot-emacs) (unless (mdw-emacs-version-p 25) @@ -139,12 +139,16 @@ (not (and (fboundp 'daemonp) (daemonp))) (progn (setq server-temp-file-regexp (concat "^" tmpdir "\\|/draft$") edit-server-new-frame nil + server-raise-frame nil gnuserv-frame t) - (trap (let ((warning-suppress-types - (cons '(server) - (and (boundp 'warning-suppress-types) - warning-suppress-types)))) - (server-start))) + (trap (progn + (require 'server) + (let ((state (server-running-p))) + (if state + (message "Emacs server %s: not starting" + (cond ((eq state t) "already running") + (t "maybe running"))) + (server-start))))) (trap (progn (require 'edit-server) (edit-server-start) @@ -384,7 +388,9 @@ wdired-allow-to-change-permissions 'advanced) (setq read-quoted-char-radix 16) ;C-q HEX-STUFF [RET] (setq case-fold-file-names nil) ;Don't translate file names (grr...) -(setq scroll-step 5) ;Don't scroll too much at a time +(setq scroll-step 5 ;Don't scroll too much at a time + hscroll-step 8 + auto-hscroll-mode 'current-line) (setq custom-unlispify-tag-names nil ;Display variable names properly custom-unlispify-menu-entries nil custom-buffer-done-kill t) @@ -519,8 +525,8 @@ ("application/x-pdf" "\\.pdf\\'" ("xdg-open" file) nil)))) (dolist (e entries) (setq w3m-content-type-alist - (cons e (remove* (car e) w3m-content-type-alist - :key #'car :test #'string=)))))) + (cons e (cl-remove (car e) w3m-content-type-alist + :key #'car :test #'string=)))))) (setq w3-do-incremental-display t w3-use-menus '(file edit view go bookmark options @@ -773,6 +779,7 @@ (global-set-key [?\C-c ?w ?b] 'w3m-bookmark-view) (global-set-key [?\C-c ?w ?c] 'mdw-set-frame-colour) (global-set-key [?\C-c ?w ?d] 'mdw-divvy-window) + (global-set-key [?\C-c ?w ?f] 'mdw-set-fallback-window) (global-set-key [?\C-c ?w ?h] 'windmove-left) (global-set-key [?\C-c ?w ?j] 'windmove-down) (global-set-key [?\C-c ?w ?k] 'windmove-up) @@ -812,10 +819,10 @@ (eval-after-load "hippie-exp" '(setq hippie-expand-try-functions-list - (remove-if (lambda (name) - (memq name '(try-expand-list - try-expand-list-all-buffers))) - hippie-expand-try-functions-list))) + (cl-remove-if (lambda (name) + (memq name '(try-expand-list + try-expand-list-all-buffers))) + hippie-expand-try-functions-list))) (autoload 'dired-jump "dired-x") (autoload 'dired-jump-other-window "dired-x") @@ -908,9 +915,9 @@ (setq completion-ignored-extensions (append `(".hc" ".hi") completion-ignored-extensions)) -(dolist (dir (remove-if-not (lambda (ext) - (= (aref ext (- (length ext) 1)) ?/)) - completion-ignored-extensions)) +(dolist (dir (cl-remove-if-not (lambda (ext) + (= (aref ext (- (length ext) 1)) ?/)) + completion-ignored-extensions)) (if (/= (aref dir 0) ?/) (setq completion-ignored-extensions (cons (concat "/" dir)