(custom-set-variables

 ;; custom-set-variables was added by Custom.

 ;; If you edit it by hand, you could mess it up, so be careful.

 ;; Your init file should contain only one such instance.

 ;; If there is more than one, they won't work right.

 '(ansi-color-faces-vector

   [default bold shadow italic underline bold bold-italic bold])

 '(ansi-color-names-vector

   ["#3F3F3F" "#CC9393" "#7F9F7F" "#F0DFAF" "#8CD0D3" "#DC8CC3" "#93E0E3" "#DCDCCC"])

 '(beacon-color "#ff9da4")

 '(custom-safe-themes

   (quote

("b59d7adea7873d58160d368d42828e7ac670340f11f36f67fa8071dbf957236a" "82d2cac368ccdec2fcc7573f24c3f79654b78bf133096f9b40c20d97ec1d8016" "1b8d67b43ff1723960eb5e0cba512a2c7a2ad544ddb2533a90101fd1852b426e" "3d47d88c86c30150c9a993cc14c808c769dad2d4e9d0388a24fee1fbf61f0971" "6ee6f99dc6219b65f67e04149c79ea316ca4bcd769a9e904030d38908fd7ccf9" default)))

 '(fci-rule-color "#383838")

 '(flycheck-color-mode-line-face-to-color (quote mode-line-buffer-id))

 '(nrepl-message-colors

   (quote

("#CC9393" "#DFAF8F" "#F0DFAF" "#7F9F7F" "#BFEBBF" "#93E0E3" "#94BFF3" "#DC8CC3")))

 '(pdf-view-midnight-colors (quote ("#DCDCCC" . "#383838")))

 '(tool-bar-mode nil)

 '(vc-annotate-background "#2B2B2B")

 '(vc-annotate-color-map

   (quote

((20 . "#BC8383")

(40 . "#CC9393")

(60 . "#DFAF8F")

(80 . "#D0BF8F")

(100 . "#E0CF9F")

(120 . "#F0DFAF")

(140 . "#5F7F5F")

(160 . "#7F9F7F")

(180 . "#8FB28F")

(200 . "#9FC59F")

(220 . "#AFD8AF")

(240 . "#BFEBBF")

(260 . "#93E0E3")

(280 . "#6CA0A3")

(300 . "#7CB8BB")

(320 . "#8CD0D3")

(340 . "#94BFF3")

(360 . "#DC8CC3"))))

 '(vc-annotate-very-old-color "#DC8CC3"))

(custom-set-faces

 ;; custom-set-faces was added by Custom.

 ;; If you edit it by hand, you could mess it up, so be careful.

 ;; Your init file should contain only one such instance.

 ;; If there is more than one, they won't work right.

 '(default ((t (:family "Hack" :foundry "SRC" :slant normal :weight bold :height 125 :width normal))))

 '(rainbow-delimiters-depth-1-face ((t (:foreground "dark orange"))))

 '(rainbow-delimiters-depth-2-face ((t (:foreground "deep pink"))))

 '(rainbow-delimiters-depth-3-face ((t (:foreground "chartreuse"))))

 '(rainbow-delimiters-depth-4-face ((t (:foreground "deep sky blue"))))

 '(rainbow-delimiters-depth-5-face ((t (:foreground "yellow"))))

 '(rainbow-delimiters-depth-6-face ((t (:foreground "orchid"))))

 '(rainbow-delimiters-depth-7-face ((t (:foreground "spring green"))))

 '(rainbow-delimiters-depth-8-face ((t (:foreground "sienna1")))))



;; 문법강조

(global-font-lock-mode t)


;; 튜토리얼 메시지 없애기

(setq inhibit-startup-message t)



;; 영역이 선택된 상태에서 붙여넣기 입력시 선택 영역을 지우고 paste 하도록 변경

(delete-selection-mode t)




;; 커서 모양

;; (setq-default cursor-type 'box)

(setq-default cursor-type 'bar)

;; (setq-default cursor-type 'hbar)



;; 커서 라인 표시하기

(global-hl-line-mode 1)




;; 화면 왼쪽에 라인넘버 표시

(global-linum-mode t)



;; 선택 영역 표시

(transient-mark-mode t)


;; 자동 저장 비활성화

(setq make-backup-files nil)


;; ;;autopair

;; (require 'autopair)

;; (autopair-global-mode)





;; 윈도우 제목 설정

(setq frame-title-format "Emacs - %b")

(setq icon-title-format "Emacs - %b")

;; (setq frame-title-format

;;   '(buffer-file-name

;;     "Emacs - [%f]"

;;     (dired-directory dired-directory "Emacs - [%b]")))

 

;; 미니버퍼 히스토리를 저장한다.

(savehist-mode 1)




;==============================================================================

;; cc mode

;==============================================================================




;; cc mode

(require 'cc-mode)



(setq auto-mode-alist

  (append

    '(("\\.C$"    . c++-mode)

      ("\\.H$"    . c++-mode)

      ("\\.cc$"   . c++-mode)

      ("\\.cpp$"  . c++-mode)

      ("\\.hh$"   . c++-mode)

      ("\\.c$"    . c-mode)

      ("\\.h$"    . c-mode)

      ("\\.m$"    . objc-mode)

      ("\\.java$" . java-mode)

     ) auto-mode-alist))



; set k&r style

;; 참고 : http://davidha.wordpress.com/2009/05/15/emacs-cc-modes-built-in-styles-gallery/

(setq

  c-default-style "k&r"

  c-basic-offset 4

  cperl-indent-level 4)



(add-hook 'c-mode-common-hook

  (lambda ()

    (setq c-basic-offset 4)

    ))





;; =============================================================================

;; 상태표시줄(status bar)에 디렉토리를 포함한 파일명 표시

;; =============================================================================



(setq-default mode-line-buffer-identification

              (list 'buffer-file-name

                    (propertized-buffer-identification "%12f")

                    (propertized-buffer-identification "%12b")))





;==============================================================================

;; 최근 열었던 파일 가져오기

;==============================================================================


(recentf-mode 1)

(setq recentf-max-saved-items 1200)

 

;; 제외할 파일

(add-to-list 'recentf-exclude "Temporary Internet Files")

 

;; 자동 저장기능 활성화

;;(setq recentf-auto-save-timer

;;  (run-with-idle-timer 30 t 'recentf-save-list))

 

(global-set-key [f12] 'recentf-open-files)



;; 탭키를 이용하여 최근 파일명 완성하기

(defun recentf-open-files-compl ()

  (interactive)

  (let* ((all-files recentf-list)

      (tocpl (mapcar (function

          (lambda (x) (cons (file-name-nondirectory x) x))) all-files))

      (prompt (append '("File name: ") tocpl))

    (fname (completing-read (car prompt) (cdr prompt) nil nil)))

    (find-file (cdr (assoc-string fname tocpl nil)))))

 

(global-set-key "\C-c\C-r" 'recentf-open-files-compl)




;; ;==============================================================================

;; ;; Auto Save & Backup File

;; ;==============================================================================


;; (setq make-backup-files t)

;; (setq auto-save-default t)

 

;; (setq

;;   make-backup-files t

;;   backup-by-copying t

;;   delete-old-versions t

;;   kept-new-versions 10

;;   kept-old-versions 10

;;   version-control t)      ;; Make numbered backups

 

;; ;; create the autosave dir if necessary, since emacs won't.

;; (make-directory "~/.autosave.d/" t)

 

;; ;; 디렉토리 설정

;; (setq

;;   bacnkup-directory-alist `((".*" . ,"~/.autosave.d/"))

;;   auto-save-file-name-transforms `((".*" ,"~/.autosave.d/" t))

;;   tramp-auto-save-directory "~/.autosave.d/")

 

;; ;; ftp 파일에 대해 백업파일 설정

;; (setq ange-ftp-auto-save 1)           ;; only 0 or 1 (DO NOT USE t or nil !!!)

;; (setq ange-ftp-make-backup-files t)

 

;; ;; auto-save every 100 input events

;; (setq auto-save-interval 100)

 

;; ;; auto-save after 30 seconds idle time

;; (setq auto-save-timeout 30)


;; 상태표시줄에 시간 표시하기

(require 'time)


;;(setq display-time-24hr-format t)

;;(setq display-time-day-and-date t)

(setq display-time-string-forms

  '(year "-" month "-" day

    " " 24-hours ":" minutes

    (if time-zone " (") time-zone (if time-zone ")")

    (if mail " Mail" "")))

(display-time)





;==============================================================================

;; 버퍼 선택 툴

;==============================================================================

 

(require 'bs)

(global-set-key [C-tab] 'bs-show)

;;(global-set-key '[C-tab] 'bs-cycle-next)

;;(global-set-key [C-S-tab] 'bs-cycle-next)

;;(global-set-key [C-S-tab] 'bs-cycle-previous)

;; ("all"                . bs-config--all)

;; ("files"              . bs-config--only-files)

;; ("files-and-scratch"  . bs-config--files-and-scratch)

;; ("all-intern-last"    . bs-config--all-intern-last)

;; (setq bs-default-configuration "all")

(setq bs-default-configuration "files-and-scratch")

 

(defun my-bs--get-modification-time-string (_start-buffer _all-buffers)

  "Return last modified time of file"

  (let ((file (buffer-file-name)))

    (if (and file (listp (visited-file-modtime)))

      (if (eq (car (visited-file-modtime)) -1)

        (string)

        (format-time-string "%Y-%m-%d %H:%M:%S" (visited-file-modtime)))

      (string))))

 

(setq bs-attributes-list

  '((""       1   1 left  bs--get-marked-string)

    ("M"      1   1 left  bs--get-modified-string)

    ("R"      2   2 left  bs--get-readonly-string)

    ("Buffer" 50 50 left  bs--get-name)

    (""       2   2 left  "  ")

    ("Size"   8   8 right bs--get-size-string)

    (""       2   2 left  "  ")

    ("Last Modified"   19   19 left my-bs--get-modification-time-string)

    (""       2   2 left  "  ")

    ("Mode"   20 20 left bs--get-mode-name)

    (""       2   2 left  "  ")

    ("File"   20 20 left  bs--get-file-name)))




;; 특정 문자열 강조

(setq bs-mode-font-lock-keywords

  (list

    ;; dev server

    '("61.222.123.2" 0 font-lock-function-name-face)

    ;; prd server

    '("219.212.111.94" 0 font-lock-keyword-face)

    ;;'("emacs" 0 font-lock-function-name-face)

    ;;'("scratch" 0 font-lock-keyword-face)

    ;;'("emacs" 0 font-lock-comment-face)

    ))











;==============================================================================

;; 비주얼 북마크

;; (필요 : https://github.com/joodland/bm)

;==============================================================================


;;(add-to-list 'load-path "~/.emacs.d/elpa/bm-20170815.1609/")

 

(require 'bm)


;; 모든 버퍼의 북마크로 이동한다

(setq bm-cycle-all-buffers t)

 

;; M$ Visual Studio key setup.

(global-set-key (kbd "<C-f2>") 'bm-toggle)

(global-set-key (kbd "<f2>")   'bm-next)

(global-set-key (kbd "<S-f2>") 'bm-previous)

 

(defun left-margin-mouse-get-line-at-click ()

  (save-excursion

    (let ((click-y (cdr (cdr (mouse-position))))

        (line-move-visual-store line-move-visual))

      (setq line-move-visual t)

      (goto-char (window-start))

      (next-line (1- click-y))

      (setq line-move-visual line-move-visual-store)

      ;; If you are using tabbar substitute the next line with

      ;; (line-number-at-pos))))

      (1+ (line-number-at-pos)))))

 

(defun left-margin-mouse-goto-line-at-click ()

  (interactive)

  (goto-line (left-margin-mouse-get-line-at-click)))

 

(defun left-margin-mouse-toggle-boomark ()

  (interactive)

  (left-margin-mouse-goto-line-at-click)

  (bm-toggle))

 

;; 라인넘버 표시줄을 이용해 북마크한다.

(global-set-key (kbd "<left-margin> <down-mouse-1>") 'left-margin-mouse-goto-line-at-click)

(global-set-key (kbd "<left-margin> <mouse-1>") 'bm-toggle)





;; =============================================================================

;; 패키지 시스템(MELPA)

;; =============================================================================


(when (>= emacs-major-version 24)

  (require 'package)

  (package-initialize)

  (add-to-list 'package-archives '("melpa" . "http://melpa.milkbox.net/packages/") t))

;;package-list


;; =============================================================================

;; auto-complete  ;; 패키지 시스템 설정후 오토 컴플릿트 다운로드

;; =============================================================================


;;(add-to-list 'load-path "~/.emacs.d/elpa/auto-complete-20170124.1845/")


(require 'auto-complete)

(require 'auto-complete-config)


(add-to-list 'ac-dictionary-directories "~/.emacs.d/elpa/auto-complete-20161029.643/dict")

(setq ac-comphist-file  "~/.emacs.d/elpa/auto-complete-20161029.643/ac-comphist.dat")


;; 자동완성 활성화

(global-auto-complete-mode t)


;; 자동완성 목록만 표시

(setq ac-expand-on-auto-complete nil)


;; TAB 키 누르면 자동완성 시작

(ac-set-trigger-key "TAB")


;; 5글자 입력시 자동완성 시작

(setq ac-auto-start 3)


;; 자동완성 후보목록

(setq ac-auto-show-menu t)          ;; 목록 표시함

;; (setq ac-auto-show-menu nil)     ;; 목록 표시않함

;; (setq ac-auto-show-menu 0.2)     ;; 0.2 초 후 목록 표시함


(setq ac-menu-height 10)            ;; 10 lines


;; 대소문자

;; (setq ac-ignore-case t)          ;; 구분않함

(setq ac-ignore-case 'smart)      ;; 입력값에 대문자가 있을 경우에만 구분

;; (setq ac-ignore-case nil)        ;; 항상 구분


(set-face-foreground 'ac-candidate-face "blue4")

(set-face-background 'ac-candidate-face "DodgerBlue1")


(set-face-foreground 'ac-selection-face "white")

(set-face-background 'ac-selection-face "steelblue")


(set-face-foreground 'ac-completion-face "white")

(set-face-background 'ac-completion-face "black")




;; =============================================================================

;; yasnippet   ;; 다운로드후 설정

;; =============================================================================


;;(add-to-list 'load-path "~/.emacs.d/elpa/yasnippet-20161221.1953/")


(require 'yasnippet)


;;(setq yas/root-directory "~/.emacs.d/elpa/yasnippet-20161221.1953/snippets")


;; yasnippet 활성화

(yas-global-mode 1)



;; ==================== auto-complete-c-headers

;; let's define a function which initailizes auto-complete-c-headers and gets called for c/c++ hooks

(defun my:ac-c-header-init ()

  (require 'auto-complete-c-headers)

  (add-to-list 'ac-sources 'ac-source-c-headers))

;; now let's call this function from c/c++ hooks

(add-hook 'c++-mode-hook 'my:ac-c-header-init)

(add-hook 'c-mode-hook 'my:ac-c-header-init)



;; ==================== flycheck

(require 'flycheck)

(add-hook 'after-init-hook #'global-flycheck-mode)



;==============================================================================

;; prog mode 설정하기(emacs 24+ only)

;; (참조 : http://www.gnu.org/software/emacs/manual/html_node/elisp/Basic-Major-Modes.html)

;==============================================================================

;; prog mode 에 설정을 해두면 각각의 언어에서 별도 설정을 하지 않아도 된다.

;; prog mode 를 상속하지 않는 경우 별도로 설정해야 한다.


;==============================================================================

;; prog mode 설정하기(emacs 24+ only)

;; (참조 : http://www.gnu.org/software/emacs/manual/html_node/elisp/Basic-Major-Modes.html)

;==============================================================================

;; prog mode 에 설정을 해두면 각각의 언어에서 별도 설정을 하지 않아도 된다.

;; prog mode 를 상속하지 않는 경우 별도로 설정해야 한다.


(defun set-default-programming-style ()

    ;; -------------------------------------------------------------------------

    ;; 엔터 입력시 들여쓰기

    (local-set-key (kbd "RET") 'newline-and-indent)

    ;; -------------------------------------------------------------------------

    ;; 탭키를 일반 에디터에서 작동하는 방식으로 변경

    ;; (local-set-key (kbd "TAB") 'self-insert-command)

    ;; 탭키 입력시 영역지정되어 있으면 영역 들여쓰기. 영역없으면 탭키.

    (local-set-key (kbd "TAB") 'indent-block)

    ;; 들여쓰기 할 때 실제 탭문자 입력

    (setq indent-tabs-mode t)

    ;; 탭 사이즈 4

    (setq tab-width 4)

    ;; -------------------------------------------------------------------------

    ;; 줄번호 표시

    (linum-mode 1)

    ;; -------------------------------------------------------------------------

    ;; 대응하는 괄호 표시

    (show-paren-mode t)

    ;; -------------------------------------------------------------------------

    ;; 커서라인 표시

    (global-hl-line-mode))


(add-hook 'prog-mode-hook 'set-default-programming-style)


(defun indent-block()

  (interactive)

  (if (region-active-p)

   (shift-region tab-width)

    (insert-tab))

  (setq deactivate-mark nil))


(defun unindent-block()

  (interactive)

  (shift-region (- tab-width))

  (setq deactivate-mark nil))


(defun shift-region(numcols)

  "shift selected region"

  (make-region-as-full-line)

  (if (region-active-p)

    (save-excursion

      (indent-rigidly (region-beginning) (region-end) numcols)

      (setq deactivate-mark nil))))


(defun make-region-as-full-line()

  "expand the region to the beginning and end of the area selected"

  (if (region-active-p)

    (progn

      (if (< (point) (mark))

        (if (not(bolp))

          (progn

            (beginning-of-line)

            (exchange-point-and-mark)

            (end-of-line)))))))


;; (define-key global-map (kbd "M-]") 'indent-block)

;; (define-key global-map (kbd "M-[") 'unindent-block)

;; (define-key global-map (kbd "<backtab>") 'unindent-block)



;;========================= Ctrl - Z  방지하기

(global-unset-key (kbd "C-z"))


(global-set-key (kbd "C-z C-z") 'my-suspend-frame)


(defun my-suspend-frame ()

  "In a GUI environment, do nothing; otherwise `suspend-frame'."

  (interactive)

  (if (display-graphic-p)

      (message "suspend-frame disabled for graphical displays.")

    (suspend-frame)))





;;==============================================================================

;; helm

;;==============================================================================

;(add-to-list 'load-path "~/.emacs.d/elpa/helm-20170103.444/")

(require 'helm)

 

(global-set-key "\C-x\ \C-r" 'helm-recentf)

(global-set-key (kbd "M-x") 'helm-M-x) ;; 헬름에 확장해서 사용

(global-set-key (kbd "C-c h o") 'helm-occur) ;;문자열을 이용해 코드 찾기

(global-set-key (kbd "C-h SPC") 'helm-all-mark-rings) ;;마크된 모든 곳 보기

;; (eval-after-load "helm"

;;   '(progn

;;      (define-key helm-map (kbd "<C-down>") (lambda () (interactive) (helm-next-line 5)))

;;      (define-key helm-map (kbd "<C-up>")   (lambda () (interactive) (helm-previous-line 5)))

;;      (if cua-mode

;;          (progn

;;            (define-key helm-map (kbd "C-v") 'cua-paste)

;;            (define-key helm-map (kbd "C-z") 'undo)))))




;;===========helm

;; 패턴을 치면 버퍼와 디렉토리에서 파일을 찾아준다.


(require 'helm-config)

(setq helm-idle-delay 0.1)

(setq helm-input-idle-delay 0.1)


(global-set-key (kbd "M-t") 'helm-for-files)





;;====================================

;;highlint-symbol

;;====================================


;; (add-to-list 'load-path "~/.emacs.d/elpa/auto-highlight-symbol-20130313.243")

(require 'auto-highlight-symbol)

(global-auto-highlight-symbol-mode t)


(load-library "highlight-symbol")

(setq highlight-symbol-on-navigation-p t)

(global-set-key (kbd "C-*") 'highlight-symbol-next)

(global-set-key (kbd "C-&") 'highlight-symbol-prev)




;; =====================================

;; expand-region ;;선택영역을 확장 해주는 extension

;; =====================================


;; expand-region이 설치된 경로

;;(add-to-list 'load-path "~/.emacs.d/elpa/expand-region-20161122.50")


(require 'expand-region)

(global-set-key (kbd "C-@") 'er/expand-region)



;; ==============================================

;; 검색 확장 기능  C-s 다음  C-w 를 할때 단어 자동으로 잡힘  한번더누르면 추가

;; ==============================================


(require 'thingatpt)


(defun my-isearch-yank-word-or-char-from-beginning ()

  "Move to beginning of word before yanking word in isearch-mode."

  (interactive)

  (if (= 0 (length isearch-string))

      (beginning-of-thing 'word))

  (isearch-yank-word-or-char)

  (substitute-key-definition 'my-isearch-yank-word-or-char-from-beginning 

        'isearch-yank-word-or-char

        isearch-mode-map))


(add-hook 'isearch-mode-hook

 (lambda ()

   "Activate my customized Isearch word yank command."

   (substitute-key-definition 'isearch-yank-word-or-char 

         'my-isearch-yank-word-or-char-from-beginning

         isearch-mode-map)))





;; =============================================================================

;; nyan-mode    현재 커서가 어느정도 위치에 있는지 시각적으로 표현

;; =============================================================================

;; M-x nyan-start-animation 으로 에니메이션 동작

;; M-x nyan-mode 로 모드 시작



;;(add-to-list 'load-path "~/.emacs.d/elpa/nyan-mode-20160429.1323")

(require 'nyan-mode)

(nyan-start-animation)

(nyan-mode)




;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

;; speed-bar

;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;

(require 'speedbar)

(require 'sr-speedbar)


;; set the speedbar on the left side, not on the right

(setq sr-speedbar-right-side nil)


;; auto-update file/directory list

(setq sr-speedbar-auto-refresh t)


;; toggle speedbar

(defun toggle-speedbar ()

  "Toggle sr-speedbar."

  (interactive)

  (progn

    (sr-speedbar-toggle)

    (if (sr-speedbar-exist-p)

        (sr-speedbar-select-windows))))


;; add file extensions

;;(speedbar-add-supported-extension ".c")

;;(speedbar-add-supported-extension ".cc")

;;(speedbar-add-supported-extension ".c++")

(speedbar-add-supported-extension ".cpp")

;;(speedbar-add-supported-extension ".C")

;;(speedbar-add-supported-extension ".cxx")

(speedbar-add-supported-extension ".h")

;;(speedbar-add-supported-extension ".hxx")

;;(speedbar-add-supported-extension ".hpp")

;;(speedbar-add-supported-extension ".m")

;;(speedbar-add-supported-extension ".mm")

;;(speedbar-add-supported-extension ".sh")

;;(speedbar-add-supported-extension ".py")

;;(speedbar-add-supported-extension ".pl")

;;(speedbar-add-supported-extension ".hs")

;;(speedbar-add-supported-extension ".lhs")

;;(speedbar-add-supported-extension ".clj")

;;(speedbar-add-supported-extension ".lisp")

;;(speedbar-add-supported-extension ".cl")

;;;(speedbar-add-supported-extension ".el")

(speedbar-add-supported-extension ".java")


;; set global shortcut

(global-set-key (kbd "M-s") 'toggle-speedbar)



;; =============================================================================

;; helm-gtags

;; (필요 : MELPA, helm-gtags

;; 쉘에서 global 설치후 gtags 만들어야함

;; =============================================================================


;; (require 'ggtags)

;; (add-hook 'c-mode-common-hook

;;           (lambda ()

;;             (when (derived-mode-p 'cc-mode 'c++-mode 'java-mode 'asm-mode)

;;               (ggtags-mode 1))))


;; (define-key ggtags-mode-map (kbd "C-c g s") 'ggtags-find-other-symbol)

;; (define-key ggtags-mode-map (kbd "C-c g h") 'ggtags-view-tag-history)

;; (define-key ggtags-mode-map (kbd "C-c g r") 'ggtags-find-reference)

;; (define-key ggtags-mode-map (kbd "C-c g f") 'ggtags-find-file)

;; (define-key ggtags-mode-map (kbd "C-c g c") 'ggtags-create-tags)

;; (define-key ggtags-mode-map (kbd "C-c g u") 'ggtags-update-tags)


;; (define-key ggtags-mode-map (kbd "M-,") 'pop-tag-mark)


(setq

 helm-gtags-ignore-case t

 helm-gtags-auto-update t

 helm-gtags-use-input-at-cursor t

 helm-gtags-pulse-at-cursor t

 helm-gtags-prefix-key "\C-cg"

 helm-gtags-suggested-key-mapping t

 )


(require 'helm-gtags)

;; Enable helm-gtags-mode

(add-hook 'dired-mode-hook 'helm-gtags-mode)

(add-hook 'eshell-mode-hook 'helm-gtags-mode)

(add-hook 'c-mode-hook 'helm-gtags-mode)

(add-hook 'c++-mode-hook 'helm-gtags-mode)

(add-hook 'asm-mode-hook 'helm-gtags-mode)

(add-hook 'java-mode-hook 'helm-gtags-mode)


(define-key helm-gtags-mode-map (kbd "C-c g a") 'helm-gtags-tags-in-this-function)

(define-key helm-gtags-mode-map (kbd "C-j") 'helm-gtags-select)

(define-key helm-gtags-mode-map (kbd "M-.") 'helm-gtags-dwim)

(define-key helm-gtags-mode-map (kbd "M-,") 'helm-gtags-pop-stack)

(define-key helm-gtags-mode-map (kbd "C-c <") 'helm-gtags-previous-history)

(define-key helm-gtags-mode-map (kbd "C-c >") 'helm-gtags-next-history)




;; =============================================

;; Revert-buffer

;; =============================================

(global-set-key (kbd "C-c r") (lambda ()

                                (interactive)

                                (revert-buffer t t t)

                                (message "buffer is reverted")))


;; ===============================================

;; fill-column-indicator

;; (require 'fill-column-indicator)

;; (setq fci-rule-width 1)

;; (setq fci-rule-color "darkblue")




;; ===============================================

;; Color Delimiters

(require 'rainbow-delimiters)

(add-hook 'prog-mode-hook 'rainbow-delimiters-mode)



;; ===============================================

;; highlight tail

(require 'highlight-tail)

(message "Highlight-tail loaded - now your Emacs will be even more sexy!")


(setq highlight-tail-colors '(("black" . 0)

                               ("#bc2525" . 25)

                               ("black" . 66)))


(setq highlight-tail-steps 14

       highlight-tail-timer 0.5)

 

(setq highlight-tail-posterior-type 'const)




;; ===========================================================

;; airline (power line)

;; (require 'airline-themes)

;; (load-theme 'airline-light)


;; (setq powerline-utf-8-separator-left        #xe0b0

;;       powerline-utf-8-separator-right       #xe0b2

;;       airline-utf-glyph-separator-left      #xe0b0

;;       airline-utf-glyph-separator-right     #xe0b2

;;       airline-utf-glyph-subseparator-left   #xe0b1

;;       airline-utf-glyph-subseparator-right  #xe0b3

;;       airline-utf-glyph-branch              #xe0a0

;;       airline-utf-glyph-readonly            #xe0a2

;;       airline-utf-glyph-linenumber          #xe0a1)


(require 'darkokai-theme)

(load-theme 'darkokai t)

;; (require 'color-theme-sanityinc-tomorrow)

;; (load-theme 'sanityinc-tomorrow-blue t)


;; (setq ;; foreground and background

;;       ;;  monokai-foreground     "#ABB2BF"

;;       ;;  monokai-background     "#282C34"

;;         ;; highlights and comments

;; ;;        monokai-comments       "#F8F8F0"

;; ;;        monokai-emphasis       "#282C34"

;; ;;        monokai-highlight      "#FFB269"

;;         monokai-highlight-alt  "#6D6CFF"

;; ;; monokeai-highlight-line "#1B1D1E"

;; monokai-highlight-line "#0100ff"

;; ;;        monokai-line-number    "#F8F8F0"

;;         ;; colours

;; ;;        monokai-blue           "#61AFEF"

;; ;;        monokai-cyan           "#56B6C2"

;; ;;        monokai-green          "#98C379"

;; ;;        monokai-gray           "#3E4451"

;; ;;        monokai-violet         "#C678DD"

;; ;;        monokai-red            "#E06C75"

;; ;;        monokai-orange         "#D19A66"

;; ;;        monokai-yellow         "#E5C07B")

;; )


;; ;;(load-theme 'monokai t)

;; (load-theme 'zenburn t)




< 파일 >

.emacs.el


'리눅스(ubuntu) > Emacs 관련' 카테고리의 다른 글

gtags 특정 디렉토리만 링크걸기  (0) 2018.09.14
한글입력 설정  (0) 2018.02.02
c/c++ emacs 설정 동영상 URL  (0) 2017.12.01
이맥스 관련 자료 모음  (0) 2017.01.08
관련 사이트  (0) 2017.01.08

+ Recent posts