(setq debug-on-error nil) (if (string-match "XEmacs\\|Lucid" emacs-version) (progn (setq options-save-faces t) (if (or (file-accessible-directory-p "/usr/X11R6/lib/xemacs/site-lisp/auctex/") (or (and (= emacs-major-version 19) (>= emacs-minor-version 15)) (= emacs-major-version 20))) (progn (require 'tex-site) (setq-default TeX-master nil))))) ;; # SQL-Modul ;; ########### (autoload 'sql "sql-mode" "Start the interactive SQL interpreter in a new buffer." t) (autoload 'sql-mode "sql-mode" "Mode for editing SQL files and running a SQL interpetror." t) (setq auto-mode-alist (cons '("\\.sql$" . sql-mode) auto-mode-alist)) ;; Für den TeX-Modus ;; ################# (require 'tex-site) (setq TeX-auto-save t) (setq TeX-parse-self t) (setq TeX-view-style '(("^a5$" "xdvi -thorough %d -paper a5") ("^landscape$" "xdvi -thorough %d -paper a4r -s 4") ("." "xdvi -thorough %d"))) (add-hook 'latex-mode-hook (function (lambda () (local-set-key (quote [228]) (quote "\"a")) (local-set-key (quote [246]) (quote "\"o")) (local-set-key (quote [252]) (quote "\"u")) (local-set-key (quote [223]) (quote "\"s")) (local-set-key (quote [196]) (quote "\"A")) (local-set-key (quote [214]) (quote "\"O")) (local-set-key (quote [220]) (quote "\"U")) ; start ispell in TeX mode (setq ispell-extra-args '("-t")) ))) ;; Run gv and ghostview (add-hook 'LaTeX-mode-hook (function (lambda() (add-to-list 'TeX-command-list '("GV" "gv %s.dvi" TeX-run-background t nil)) (add-to-list 'TeX-command-list '("Ghostview" "ghostview %s.ps" TeX-run-background t nil)) ))) ;; ISpell-Setup by Michael Deindl (global-set-key "\M-#" 'ispell-word) (global-set-key "\C-cim" 'ispell-message) (global-set-key "\C-cib" 'ispell-buffer) (global-set-key "\C-cic" 'ispell-change-dictionary) (global-set-key "\C-cid" '(lambda () "set german dictionary" (interactive) (ispell-change-dictionary "deutsch8") )) (global-set-key "\C-cie" '(lambda () "set english dictionary" (interactive) (ispell-change-dictionary "english") )) ;; German Quotes (defun tex-german-quotes () "mg : alters quotes to german ones" (interactive) (setq TeX-open-quote "\"`") (setq TeX-close-quote "\"'")) (add-hook 'tex-mode-hook 'tex-german-quotes) (message "LaTeX initialised") ;; Calendar (add-hook 'diary-display-hook 'fancy-diary-display) (add-hook 'list-diary-entries-hook 'sort-diary-entries) (setq mark-diary-entries-in-calendar t) (setq european-calendar-style t) (setq all-christian-calendar-holidays t) (setq calendar-date-display-form '((if dayname (concat dayname ", ")) day " " monthname " " year)) (setq calendar-time-display-form '(24-hours ":" minutes (if time-zone " (") time-zone (if time-zone ")"))) (setq appt-message-warning-time 30) (setq view-diary-entries-initially t) (setq appt-issue-message t) (add-hook 'diary-hook 'appt-make-list) ;:; German setup of easter holidays: (and (file-exists-p "~/emacs/site-holidays.el") ; contains all settings (load-library "~/emacs/site-holidays")) ; for local holidays (defun own-calendar-load-settings () (setq calendar-month-name-array [ "Januar" "Februar" "März" "April" "Mai" "Juni" "Juli" "August" "September" "Oktober" "November" "Dezember" ] calendar-day-name-array [ "Sonntag" "Montag" "Dienstag" "Mittwoch" "Donnerstag" "Freitag" "Samstag" ] calendar-week-start-day 1 diary-file "~/.diary" ;: I prefere a hidden file european-calendar-style t cal-tex-diary t) ;: I want it all! (setq mark-diary-entries-in-calendar t mark-holidays-in-calendar nil)) (defun own-calendar-initial-settings () (add-hook 'today-visible-calendar-hook 'calendar-mark-today) (add-hook 'diary-display-hook 'fancy-diary-display) ;: maybe this is set on the wrong hook but I found no other way to mark all ;: entries initially: (if (not mark-diary-entries-in-calendar) (progn (mark-diary-entries) (mark-calendar-holidays))) (show-all-diary-entries)) (add-hook 'calendar-load-hook 'own-calendar-load-settings) (add-hook 'initial-calendar-window-hook 'own-calendar-initial-settings) (message "calendar initialised") (setq-default tab-width 3) (add-hook 'text-mode-hook 'turn-on-auto-fill) (setq browse-url-browser-function (if (eq window-system 'x) 'browse-url-netscape 'browse-url-w3)) (autoload browse-url-browser-function "browse-url" "Ask a WWW browser to show a URL." t) (global-unset-key [backspace]) (global-set-key [backspace] 'delete-backward-char) (global-unset-key [delete]) (global-set-key [delete] 'delete-char) ;; Fuer den verf***** C/Java Mode (defun erics-looks-a-bit-better-hook-for-c-java-mode () (setq c-basic-offset 2)) (add-hook 'c-mode-common-hook 'erics-looks-a-bit-better-hook-for-c-java-mode) ; auskommentieren wenn package-Version von gnus benutzt werden soll (setq load-path (cons (expand-file-name "~/.xemacs/lisp/gnus/") load-path)) (require 'gnus) ; ausserdem brauche ich noch diverse andere Modi (setq load-path (cons (expand-file-name "~/.xemacs/lisp/misc/") load-path)) ;; Diverser Krempel ; ist glaube ich nicht mehr nötig. ;(load "mime-setup") (setq lpr-command "lpr") (setq ps-lpr-command "lpr") (setq lpr-switches (quote ("-Plp"))) (setq ps-lpr-switches (quote ("-Plp"))) (setq ps-paper-type 'a4small) ;(setq Info-directory-list (cons "/usr/lib/xemacs/mule-packages/info" ; Info-directory-list)) (setq message-kill-buffer-on-exit t) (setq calendar-week-start-day 1) (setq focus-follows-mouse t) (setq tab-width 2) (setq next-line-add-newlines t) (setq display-time-24hr-format t) (setq column-number-mode t) (setq line-number-mode t) ; Farben (defconst erics-font-size "12") (defconst erics-font-family "Fixed") (if (eq (console-type) 'x) (progn (set-face-foreground 'default "black") (set-face-background 'default "grey") (custom-set-faces '(default ((t (:foreground "black" :size erics-font-size :family erics-font-family))) t) '(info-xref ((t (:foreground "blue")))) '(info-node ((t (:foreground "blue" :bold t)))) '(widget-documentation-face ((((class color) (background light)) (:foreground "dark green" :size erics-font-size)))) '(border-glyph ((t (:size erics-font-size))) t) '(bold ((t (:family erics-font-family :bold t))) t) '(bold-italic ((t (:size erics-font-size :family erics-font-family :bold t :italic t))) t) '(blue ((t (:foreground "blue" :size erics-font-size :family erics-font-family))) t) '(isearch ((t (:foreground "black" :background "paleturquoise"))) t) '(highlight ((t (:foreground "black" :background "darkseagreen2"))) t)))) ;; Fuer bbdb (setq bbdb-file "~/.bbdb"); (setq bbdb-default-area-code "07071") (setq bbdb-north-american-phone-numbers-p nil) (setq bbdb-electric-p t) (setq bbdb/mail-auto-create-p t) (setq bbdb/news-auto-create-p nil) (setq bbdb-completion-display-record nil) (setq bbdb-use-pop-up nil) ; lpr Zeugs (setq lpr-switches (quote ("(\"--medium=a4dj\")"))) (setq lpr-command "a2ps") ; scheme mode (autoload 'run-scheme "cmuscheme" "Run an inferior Scheme process." t) (require 'cmuscheme48) (setq auto-mode-alist (cons '("\\.scm$" . scheme-mode) auto-mode-alist)) (setq scheme-program-name "scheme48 -h 10000000") (set-specifier default-toolbar-visible-p nil) ;; zenirc ;; ####### (setq zenirc-server-default "irc.uni-stuttgart.de") (setq zenirc-nick-default "hogwart03") ; lieber mail-lib als sendmail/exim zum Versenden von Mails nehmen ; Das kann wenigstens "von Haus aus" SMTP-Authentifizierung (setq send-mail-function 'smtpmail-send-it) ; für mail (setq message-send-mail-function 'smtpmail-send-it) ; für message (setq smtpmail-default-smtp-server "webmail.macnews.de") (setq smtpmail-local-domain "macnews.de") (setq smtpmail-debug-info t) (load-library "smtpmail") (setq smtpmail-code-conv-from nil) (setq user-full-name "Eric Knauel") (setq smtpmail-auth-credentials '(("webmail.macnews.de" 25 "eric%macnews.de" "very-secret"))) ; Bei Gelegenheit mal eins machen... ;(setq smtpmail-starttls-credentials ; '(("webmail.macnews.de" 25 "~/.my_smtp_tls.key" "~/.my_smtp_tls.cert"))) ;; PHP mode ;; ######## (autoload 'php-mode "php-mode" "PHP editing mode" t) (add-to-list 'auto-mode-alist '("\\.php3$" . php-mode)) (add-to-list 'auto-mode-alist '("\\.php$" . php-mode)) (setq efs-ftp-program-name "/usr/bin/ftp") (require 'uniquify) (setq ediff-window-setup-function (quote ediff-setup-windows-plain)) (setq uniquify-buffer-name-style (quote post-forward)) (setq uniquify-after-kill-buffer-p t) (font-lock-mode) ;; gnuserv starten (gnuserv-start)