merge origine/master
[dotfiles.git] / emacs.d / config / init-helm.el
1
2 (require 'helm)
3 (require 'helm-config)
4 (require 'helm-adaptive)
5 (helm-mode 1)
6
7 ;; helm-M-x
8 (global-set-key (kbd "M-x") 'helm-M-x)
9 (setq helm-M-x-fuzzy-match t) ;; optional fuzzy matching for helm-M-x
10
11 ;; helm-mini
12 ;;(global-set-key (kbd "C-x b") 'helm-mini)
13 ;;(global-set-key (kbd "C-o C-j") 'helm-mini)
14 (setq helm-buffers-fuzzy-matching t
15       helm-recentf-fuzzy-match    t)
16
17 ;; helm-find-file
18 ;(global-set-key (kbd "C-x C-f") 'helm-find-files)
19 ;;(global-set-key (kbd "C-o C-f") 'helm-find-files)
20
21
22
23 ;; http://stackoverflow.com/questions/9992475/how-to-show-anything-buffers-always-in-new-window
24 (setq helm-display-function
25       (lambda (buf)
26         (split-window-vertically)
27         (other-window 1)
28         (switch-to-buffer buf)))
29
30
31 ;;;;;;; http://tuhdo.github.io/helm-intro.html
32 ;;;;;(setq helm-split-window-in-side-p           t ; open helm buffer inside current window, not occupy whole other window
33 ;;;;;      helm-move-to-line-cycle-in-source     t ; move to end or beginning of source when reaching top or bottom of source.
34 ;;;;;      helm-ff-search-library-in-sexp        t ; search for library in `require' and `declare-function' sexp.
35 ;;;;;      helm-scroll-amount                    8 ; scroll 8 lines other window using M-<next>/M-<prior>
36 ;;;;;      helm-ff-file-name-history-use-recentf t)
37
38
39
40 (helm-autoresize-mode 1)
41 (helm-adaptive-mode 1)
42 (helm-adaptative-mode 1)
43 (setq helm-adaptive-history 1)
44
45
46 ;;j;(defun helm-buffer-face-mode ()
47 ;;j;  "Helm buffer face"
48 ;;j;  (interactive)
49 ;;j;  (with-helm-buffer
50 ;;j;  (setq line-spacing 2)
51 ;;j;  (buffer-face-set '(:family "Source Code Pro" :height 100))))
52                                                               
53
54 ;;;(add-hook 'helm-update-hook 'helm-buffer-face-mode)
55
56
57 (provide 'init-helm)