;; .emacs ;; turn on font-lock mode (when (fboundp 'global-font-lock-mode) (global-font-lock-mode t)) ;; default to better frame titles (setq frame-title-format (concat "%b - emacs@" (system-name))) ;; Disable menu & tool bars in emacs as I never really use them. ;(menu-bar-mode -1) ;; (tool-bar-mode -1) ;; default to unified diffs (setq diff-switches "-u") ;; This makes the cursor automatically indent the next line... ;; However, it could make emacs a little slower (define-key global-map "\C-M" 'newline-and-indent) ;; Shortcut/Macro for goto-line (define-key global-map "\C-xg" 'goto-line) ;; Set tab width to 4 for the C++ mode.. (add-hook 'c++-mode-hook '(lambda () (setq c-basic-offset 4))) ;; Use spaces instead of tabs in C++ mode.. (add-hook 'c++-mode-hook '(lambda () (setq indent-tabs-mode nil))) ;; Supress beeping (setq visible-bell t) (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. '(auto-compression-mode t nil (jka-compr)) '(case-fold-search t) '(column-number-mode t) '(current-language-environment "Latin-9") '(default-input-method "latin-9-prefix") '(global-font-lock-mode t nil (font-lock)) '(inhibit-startup-screen t) '(ldap-host-parameters-alist (quote (("ldap.miamioh.edu" base "ou=People,dc=miamioh,dc=edu"))))) (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. ) ;; Set tab width to 4 for the C++ mode.. (setq-default tab-width 4) ;; Make the default font a bit bigger to make it easier to read (set-face-attribute 'default (selected-frame) :height 150) ;; Show column numbers by default (setq column-number-mode t) ;; Shortcut/Macro for compile and default command for compiling (define-key global-map "\C-xc" 'compile) (setq compile-command "g++ -g -Wall -std=c++11") ;; Enable semantic mode to parse source code and generate symbols (semantic-mode 1) (require 'semantic/sb) (global-semantic-idle-completions-mode 1) (global-semantic-idle-summary-mode 1) ;; Enable auto-complete and integrate it with semantic mode. (add-to-list 'load-path "/usr/share/emacs/site-lisp/auto-complete") (require 'auto-complete-config) (ac-config-default)