b3s
Mysti's Geeky Fiancée
one, html-mode is installed.
two, you will want to create an html-mode hook for your html preferences in your ~/.emacs. my html-mode hook (well, sgml, since i use it for xml as well) looks like:
mainly, i want hierarchical html/xml/xsl indenting, 80-column max, etc.
cool thing about emacs in html/java/c/c++-mode is that hitting tab anywere in the line will automagically indent it.
a few other things you will probably want in your ~/.emacs file:
couple of things i forgot to mention before:
C-x space starts marking.
C-w cuts mark.
ESC-w copies mark
C-g cancels
C-x u undo
C-s search
ESC-x replace-string search and replace.
two, you will want to create an html-mode hook for your html preferences in your ~/.emacs. my html-mode hook (well, sgml, since i use it for xml as well) looks like:
Code:
(add-hook 'sgml-mode-hook 'my-sgml-hook)
(defun my-sgml-hook()
"defaults for SGML mode."
(auto-fill-mode)
(setq fill-column 80)
(setq sgml-auto-activate-dtd t)
(setq sgml-omittag t)
(setq sgml-shorttag t)
(setq sgml-minimize-attributes nil)
(setq sgml-always-quote-attributes t)
(setq sgml-indent-step 2)
(setq sgml-indent-data t)
(setq sgml-parent-document nil)
(setq sgml-exposed-tags nil)
(setq sgml-local-catalogs nil)
(setq sgml-local-ecat-files nil)
)
mainly, i want hierarchical html/xml/xsl indenting, 80-column max, etc.
cool thing about emacs in html/java/c/c++-mode is that hitting tab anywere in the line will automagically indent it.
a few other things you will probably want in your ~/.emacs file:
Code:
;; sets up your name and e-mail for modes that use it.
(setq user-full-name "your-name")
(setq user-mail-address "your-email")
Code:
;; make ~/.backup and all backup files go there
(load-library "backup-dir")
(setq bkup-backup-directory-info
'((t "~/.backup/" full-path prepend-name search-upward)))
Code:
;;show paren, brace, and curly brace "partners" at all times
(show-paren-mode t)
;;highlight marked regions
(transient-mark-mode t)
;;show column number in status bar
(column-number-mode t)
couple of things i forgot to mention before:
C-x space starts marking.
C-w cuts mark.
ESC-w copies mark
C-g cancels
C-x u undo
C-s search
ESC-x replace-string search and replace.