This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
*** elscreen.el 2012-10-03 11:34:53.000000000 +0900 | |
--- elscreen_new.el 2012-10-03 11:35:35.000000000 +0900 | |
*************** | |
*** 37,43 **** | |
;;; User Customizable Variables: | |
! (defconst elscreen-version "2012-04-11") | |
(defgroup elscreen nil |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(narrow-to-region (save-excursion (or (when (move-to-window-line 1) (point)) | |
(point-min))) | |
(save-excursion (or (when (move-to-window-line -1) (point)) | |
(point-max)))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'recentf) | |
(defun recentf-ido-find-files-and-dirs (arg) | |
"Find a recent file and a directory using Ido." | |
(interactive "P") | |
(let* ((show-full-path-p (cond (arg t) (t nil))) | |
(file-assoc-list ;表示する候補名とフルパス | |
(mapcar (lambda (x) | |
(cond ((equal (substring x (- (length x) 1) (length x)) "/") ;末尾がスラッシュ | |
(cons (file-name-directory x) x)) | |
(t |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun ido-smart-select-text-throw () | |
(let ((match (ido-name (car ido-matches)))) | |
(throw 'ido | |
(setq ido-selected | |
(if match | |
(replace-regexp-in-string "/\\'" "" match) | |
ido-text) | |
ido-text ido-selected | |
ido-final-text ido-text)))) | |
(defun ido-smart-select-text () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'cl-lib) | |
(cl-defun ido-choose-visible-window () | |
"ウィンドウ切り替えをido補完で.選択中のウィンドウは切り替え候補から外す." | |
(interactive) | |
(let ((alist (mapcar (lambda (win) | |
(cons (buffer-name (window-buffer win)) | |
win)) | |
(remove (selected-window) | |
(window-list)))) | |
result) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun ibuffer-ido-find-file () | |
"Like `ido-find-file', but default to the directory of the buffer at point." | |
(interactive) | |
(let ((default-directory | |
(let ((buf (ibuffer-current-buffer))) | |
(if (buffer-live-p buf) | |
(with-current-buffer buf | |
default-directory) | |
default-directory)))) | |
(ido-find-file-in-dir default-directory))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'smartchr nil t) | |
(defun smartchr-braces () | |
"Insert a pair of braces like below. | |
\n {\n `!!'\n}" | |
;; foo { | |
;; `!!' | |
;; } | |
(lexical-let (beg end) | |
(smartchr-make-struct |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun iedit-dwim-get-string () | |
(cond ((iedit-region-active) | |
(setq mark-active nil) | |
(run-hooks 'deactivate-mark-hook) | |
(buffer-substring-no-properties | |
(region-beginning) (region-end))) | |
(t | |
(current-word)))) | |
(defun iedit-dwim (arg) | |
"Starts iedit but uses \\[narrow-to-defun] to limit its scope." |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(lazyload (highlight-symbol-all | |
highlight-symbol-moccur | |
highlight-symbol-occur-by-moccur) "highlight-symbol" nil | |
(defun highlight-symbol-all (&optional nlines) | |
"Use all for highlighted symbols." | |
(interactive "P") | |
(if (thing-at-point 'symbol) | |
(all (highlight-symbol-get-symbol) nlines) | |
(error "No symbol at point."))) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(require 'ace-jump-mode) | |
(define-key global-map (kbd "C-c SPC") 'ace-jump-mode) | |
(defun add-keys-to-ace-jump-mode (prefix c &optional mode) | |
(define-key global-map | |
(read-kbd-macro (concat prefix (string c))) | |
`(lambda () | |
(interactive) | |
(funcall (if (eq ',mode 'word) | |
#'ace-jump-word-mode |
OlderNewer