;;; This is a sample _emacs, hence -*- Emacs-Lisp -*- 

;;; To use it, copy it to _emacs in a directory where emacs will
;;; search it. Were will emacs search it? If emacs is installed in a
;;; directory named `bin', it will search _emacs in the parent
;;; directory, else it will search it in the directory it is installed
;;; in. Setting the environment variable `HOME' probably interferes
;;; with this scheme.

;;; First, lets pretend we want to edit text as a default
(setq default-major-mode 'text-mode)
(add-hook 'text-mode-hook 'turn-on-auto-fill)
(setq next-line-add-newlines nil)
(setq require-final-newline t)

;;; Set the paths right.
(setq load-path (cons "c:/emacs/site-lisp" load-path))
(setq Info-default-directory-list '("c:/emacs/info"))

;;; highlight matching parens. Never leave home without it.
(require 'paren)

;;; have a colorful day
(add-hook 'c-mode-hook 'turn-on-font-lock)
(add-hook 'emacs-lisp-mode-hook 'turn-on-font-lock)
(add-hook 'tex-mode-hook 'turn-on-font-lock)

(transient-mark-mode t)
(setq visible-bell t)
(setq search-highlight t)
(setq query-replace-highlight t)

;;; useful info in the mode line
(display-time)
(setq display-time-24hr-format t)
(column-number-mode t)

;;; pc look-and-feel, either the first two
; (require 'pc-select)
; (pc-selection-mode)
;;; or this one
(require 's-region)

(setq scroll-step 1)

;;; Set to `'tilde' or `'bak'.
;;; dired does not recognize .bak extensions!
(setq dos-backup-name-method 'tilde)

;;; Work in 80x50 screen size, but switch back to 80x25
;;; before exiting and when suspending Emacs.
;(mode4350)
;
;(defun my-exit-stuff ()
;  "My own exit routine.  Currently just switches to the 25x80 mode."
;  (mode25))
;(add-hook 'kill-emacs-hook 'my-exit-stuff)
;
;(add-hook 'suspend-hook 'mode25)
;(add-hook 'suspend-resume-hook 'mode4350)

;;; enable this to to default to unix-type LF files
;;; instead of dos-style CR/LF
;(setq default-buffer-file-type t)

;;; alternatively, specify it for several file extensions
;(setq file-name-buffer-file-type-alist
;      (append '(
;		("\\.el$" . t)
;		("\\.\\(\\|c\\|cc\\|h\\)$" . t)
;		("\\.\\(tex\\|sty\\)$" . t))
;	       file-name-buffer-file-type-alist))


;;; Emacs thinks I'm dosuser@pc. Duh.
(setq user-full-name    "Dos User")
(setq user-login-name   "D.User")
(setq system-name       "peecee")
(setq mail-host-address "pc.com")
