.emacs-my
changeset 698 2a081d4e2e7c
parent 691 0722f3949eda
child 699 9ec79850e725
equal deleted inserted replaced
691:0722f3949eda 698:2a081d4e2e7c
  1637   )
  1637   )
  1638 
  1638 
  1639 ;;; ----------------------------------------------------------------
  1639 ;;; ----------------------------------------------------------------
  1640 (message "psgml")
  1640 (message "psgml")
  1641 
  1641 
       
  1642 (setq my-html-template
       
  1643       '("html"
       
  1644         (nil
       
  1645          "\n<head>" \n
       
  1646          "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=" (read-input "Charset: ") "\">" \n
       
  1647          "<title>" (setq str (read-input "Title: ")) "</title>\n"
       
  1648          "</head>\n"
       
  1649          "<body>\n<h1>" str "</h1>"
       
  1650          "\n<address>" \n
       
  1651          "<a href=\"mailto:" user-mail-address "\">" (user-full-name) "</a>" \n
       
  1652          "</address>" \n
       
  1653          "</body>\n"
       
  1654          ))
       
  1655       )
       
  1656 
  1642 (setq sgml-set-face t)                  ; for highlighting in sgml
  1657 (setq sgml-set-face t)                  ; for highlighting in sgml
  1643 (eval-after-load 'sgml-mode
  1658 (eval-after-load 'sgml-mode
  1644   '(progn
  1659   '(progn
  1645      (setq html-tag-alist
  1660      (unless (featurep 'psgml)
  1646            (cons
  1661        (setq html-tag-alist
  1647             '("html" (nil
  1662              (cons
  1648                       "\n<head>" \n
  1663               my-html-template
  1649                       "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=" (read-input "Charset: ") "\">" \n
  1664               (my-filter
  1650                       "<title>" (setq str (read-input "Title: ")) "</title>\n"
  1665                (lambda (item) (not (equal (car item) "html")))
  1651                       "</head>\n"
  1666                html-tag-alist)))
  1652                       "<body>\n<h1>" str "</h1>"
  1667      )))
  1653                       "\n<address>" \n
       
  1654                       "<a href=\"mailto:" user-mail-address "\">" (user-full-name) "</a>" \n
       
  1655                       "</address>" \n
       
  1656                       "</body>\n"
       
  1657                       ))
       
  1658             (my-filter
       
  1659              (lambda (item) (not (equal (car item) "html")))
       
  1660              html-tag-alist)))
       
  1661      ))
       
  1662 
  1668 
  1663 ;;; ----------------------------------------------------------------
  1669 ;;; ----------------------------------------------------------------
  1664 (message "sh, bash")
  1670 (message "sh, bash")
  1665 
  1671 
  1666 (add-to-list 'auto-mode-alist '("\\.cygport\\'" . shell-script-mode))
  1672 (add-to-list 'auto-mode-alist '("\\.cygport\\'" . shell-script-mode))