                                    space-after-tab
                                    space-before-tab))
 
-;;; Base Behavior
+  ;; Don't blink the cursor
+  (blink-cursor-mode -1)
+
+  ;; Always highlight the current line
+  (global-hl-line-mode 1)
+
+;;; Behavior
+  ;; UTF-8
+  (set-language-environment 'utf-8)
+  (prefer-coding-system 'utf-8)
+  (set-terminal-encoding-system 'utf-8)
+  (set-keyboard-coding-system 'utf-8)
+  (setq locale-coding-system 'utf-8)
+  (set-selection-coding-system 'utf-8)
+
+  ;; Default to Chinese pinyin
+  (setq default-input-method 'chinese-py)
+
+  ;; Sentences end with a dot, not with two spaces
+  (setq sentence-end-double-space nil)
+
   ;; Never insert tabs automatically
   (setq-default indent-tabs-mode nil)
 
-  ;; Default spaces for C-style
+  ;; Default space width
+  (setq default-tab-width rmg:indent-spaces)
+  (setq-default tab-width rmg:indent-spaces)
+
   (setq-default c-basic-offset rmg:indent-spaces)
   (setq c-basic-offset rmg:indent-spaces)
 
+  (setq css-indent-offset rmg:indent-spaces)
+
+  (setq-default sh-basic-offset rmg:indent-spaces)
+  (setq-default sh-indentation rmg:indent-spaces)
+
+  (setq-default perl-indent-level rmg:indent-spaces)
+
+  (setq-default js-indent-level rmg:indent-spaces)
+
+  ;; Fill at 79, not 70
+  (setq default-fill-column 79)
+
+  ;; Middle click should paste at cursor position, not mouse position
+  (setq mouse-yank-at-point t)
+
+  ;; Additional hideshow hotkeys
+  (global-set-key (kbd "C-c h H") 'hs-hide-all)
+  (global-set-key (kbd "C-c h S") 'hs-show-all)
+  (global-set-key (kbd "C-c h h") 'hs-hide-block)
+  (global-set-key (kbd "C-c h s") 'hs-show-block)
+  (global-set-key (kbd "C-c h t") 'hs-toggle-hiding)
+
+  ;; Don't use this init.el for customizations
+  (setq custom-file "~/.emacs.d/custom.el")
+  (load custom-file 'noerror)
+
+  ;; Start the emacs server for emacsclient
+  (server-start)
+
+
 ;;; End
 )

  (setq eshell-directory-name "~/.emacs.d/eshell/")
  (setq eshell-login-script "~/.emacs.d/eshell/login")
  (setq eshell-rc-script "~/.emacs.d/eshell/profile")

  ;; Magit Projects
  (setq magit-repo-dirs '("~/Projects"
                          "~/.emacs.d"))

  ;; Hotkeys to move back and forth between frames
  (global-set-key (kbd "C-o") 'other-window)

  (line-number-mode 1)
  (column-number-mode 1)

  ;; Setup graphical window
  (add-hook 'window-setup-hook
            (lambda ()
              (when window-system
                ;; Title format
                (setq frame-title-format (concat "%b - "
                                                 (downcase user-login-name)
                                                 "@"
                                                 (downcase system-name)))

                ;; No scrollbars
                (scroll-bar-mode -1)
                ;; No toolbar
