.emacs-my
changeset 468 925f1b143a3d
parent 464 ae073d35f674
parent 467 e08ed1434053
child 469 a9adec4fbcbf
equal deleted inserted replaced
464:ae073d35f674 468:925f1b143a3d
   813 (defface my-tab-face
   813 (defface my-tab-face
   814   '((t :background "gray"))
   814   '((t :background "gray"))
   815   "Face for showing TABs."
   815   "Face for showing TABs."
   816   :group 'basic-faces)
   816   :group 'basic-faces)
   817 
   817 
   818 (defface my-conflict-face
   818 (defface my-contrasty-face
   819   '((t :background "pink" :foreground "red" :weight bold))
   819   '((t :background "pink" :foreground "red" :weight bold))
   820   "Font for showing conflicts."
   820   "Font for showing conflicts."
   821   :group 'basic-faces)
   821   :group 'basic-faces)
   822 
   822 
   823 (add-hook 'font-lock-mode-hook (function (lambda ()
   823 (dolist (mode my-devel-mode-list)
   824   (when (member major-mode my-devel-mode-list)
   824   (font-lock-add-keywords
   825     (font-lock-add-keywords nil
   825    mode
   826      '(
   826    '(
   827        ("\t+" 0 'my-tab-face t)
   827      ("\t+" 0 'my-tab-face t)
   828        ("\\<\\(FIXME:?\\|XXX:?\\|TODO:?\\)\\>" 1 'font-lock-warning-face t)
   828      ("\\<\\(FIXME:?\\|XXX:?\\|TODO:?\\)\\>" 1 'font-lock-warning-face t)
   829        ("\\(=\\{7,\\}\\|<\\{7,\\}\\|>\\{7,\\}\\)" 1 'my-conflict-face t)
   829      ("\\(=\\{7,\\}\\|<\\{7,\\}\\|>\\{7,\\}\\)" 1 'my-contrasty-face t)
   830        ))))))
   830      ;; 64 times, for highlight C-u C-u C-u <key>
   831 
   831      ("\\([^[:space:]]\\)\\1\\{63\\}" 0 'my-contrasty-face t)
   832 ;; (dolist (mode '(c-mode
   832      ))
   833 ;;                 java-mode
   833   )
   834 ;;                 cperl-mode
       
   835 ;;                 html-mode-hook
       
   836 ;;                 css-mode-hook
       
   837 ;;                 emacs-lisp-mode))
       
   838 ;;   (font-lock-add-keywords mode
       
   839 ;;                           '(("\\(XXX\\|FIXME\\|TODO\\)"
       
   840 ;;                              1 font-lock-warning-face prepend))))
       
   841 
   834 
   842 ;;; ----------------------------------------------------------------
   835 ;;; ----------------------------------------------------------------
   843 ;;; communication.
   836 ;;; communication.
   844 
   837 
   845 ;;; ----------------------------------------------------------------
   838 ;;; ----------------------------------------------------------------
  1031   (global-semantic-mru-bookmark-mode 1)
  1024   (global-semantic-mru-bookmark-mode 1)
  1032   ;; (setq semantic-stickyfunc-sticky-classes '(function type variable include package))
  1025   ;; (setq semantic-stickyfunc-sticky-classes '(function type variable include package))
  1033   (global-semantic-stickyfunc-mode -1)
  1026   (global-semantic-stickyfunc-mode -1)
  1034   (global-semantic-idle-completions-mode -1)
  1027   (global-semantic-idle-completions-mode -1)
  1035 
  1028 
       
  1029   (setq semantic-idle-scheduler-work-idle-time 60)
       
  1030   ;; (setq semantic-idle-work-parse-neighboring-files-flag nil)
       
  1031 
  1036   ;; semantic-dependency-system-include-path, semantic-customize-system-include-path
  1032   ;; semantic-dependency-system-include-path, semantic-customize-system-include-path
  1037   (setq-mode-local c-mode semanticdb-find-default-throttle '(project unloaded system recursive))
  1033   (setq-mode-local c-mode semanticdb-find-default-throttle '(project unloaded system recursive))
  1038   (add-hook 'c-mode-hook (lambda nil (semantic-add-system-include "~/.emacs.d/include" 'c-mode)))
  1034   (add-hook 'c-mode-hook (lambda nil (semantic-add-system-include "~/.emacs.d/include" 'c-mode)))
  1039   (add-hook 'c-mode-hook (lambda nil (semantic-add-system-include "~/.emacs.d/include" 'c++-mode)))
  1035   (add-hook 'c-mode-hook (lambda nil (semantic-add-system-include "~/.emacs.d/include" 'c++-mode)))
       
  1036   (require 'semanticdb)
  1040   (global-semanticdb-minor-mode 1)
  1037   (global-semanticdb-minor-mode 1)
  1041 
  1038 
  1042   (global-set-key (kbd "C-c , .") 'semantic-ia-fast-jump)
  1039   (global-set-key (kbd "C-c , .") 'semantic-ia-fast-jump)
  1043   (global-set-key (kbd "C-c , d") 'semantic-ia-show-doc)
  1040   (global-set-key (kbd "C-c , d") 'semantic-ia-show-doc)
  1044   (global-set-key (kbd "C-c , D") 'semantic-ia-describe-class)
  1041   (global-set-key (kbd "C-c , D") 'semantic-ia-describe-class)