Emacs Configuration
(package-initialize)
(load-theme 'leuven)
(tool-bar-mode 0)
(add-to-list 'default-frame-alist '(font . "Consolas 9"))
(dolist (charset '(bopomofo cjk-misc han kana symbol))
(set-fontset-font t
charset
(font-spec :family "Microsoft YaHei" :size 12)))
(setq-default auto-save-default nil)
(setq-default fill-column 120)
(setq-default indent-tabs-mode nil)
(setq-default inhibit-startup-screen t)
(setq-default make-backup-files nil)
(setq-default visible-bell t)
(column-number-mode t)
(when (display-graphic-p)
(global-hl-line-mode t))
(global-whitespace-mode t)
(setq-default whitespace-action '(auto-cleanup))
(setq-default whitespace-line-column nil)
(setq-default whitespace-style (remove 'newline-mark whitespace-style))
(set-face-background 'whitespace-space nil)
(global-visual-line-mode t)
(global-linum-mode t)
(unless (display-graphic-p)
(setq-default linum-format (lambda (line)
(let ((w (length (number-to-string (count-lines (point-min) (point-max))))))
(propertize (format (format "%%%dd│" w) line)
'face
'linum)))))
(setq-default show-paren-delay 0)
(show-paren-mode t)
(add-to-list 'default-frame-alist '(width . 120))