[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/lisp/generic-x.el
From: |
Lute Kamstra |
Subject: |
[Emacs-diffs] Changes to emacs/lisp/generic-x.el |
Date: |
Thu, 12 May 2005 09:19:29 -0400 |
Index: emacs/lisp/generic-x.el
diff -c emacs/lisp/generic-x.el:1.34 emacs/lisp/generic-x.el:1.35
*** emacs/lisp/generic-x.el:1.34 Thu Apr 28 09:17:06 2005
--- emacs/lisp/generic-x.el Thu May 12 13:19:29 2005
***************
*** 116,126 ****
:group 'data
:version "20.3")
- (defgroup generic-x-modes nil
- "Individual modes in the collection of generic modes."
- :group 'generic-x
- :version "22.1")
-
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Default-Generic mode
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
--- 116,121 ----
***************
*** 158,164 ****
:type '(choice (const :tag "Don't check file names" nil) regexp))
;; This generic mode is always defined
! (define-generic-mode default-generic-mode (list ?#) nil nil nil nil :group
'generic-x-modes)
;; A more general solution would allow us to enter generic-mode for
;; *any* comment character, but would require us to synthesize a new
--- 153,159 ----
:type '(choice (const :tag "Don't check file names" nil) regexp))
;; This generic mode is always defined
! (define-generic-mode default-generic-mode (list ?#) nil nil nil nil)
;; A more general solution would allow us to enter generic-mode for
;; *any* comment character, but would require us to synthesize a new
***************
*** 308,315 ****
'((nil "^\\([-A-Za-z0-9_]+\\)" 1)
("*Directories*" "^\\s-*<Directory\\s-*\\([^>]+\\)>" 1)
("*Locations*" "^\\s-*<Location\\s-*\\([^>]+\\)>" 1))))))
! "Generic mode for Apache or HTTPD configuration files."
! :group 'generic-x-modes))
(when (memq 'apache-log-generic-mode generic-extras-enable-list)
--- 303,309 ----
'((nil "^\\([-A-Za-z0-9_]+\\)" 1)
("*Directories*" "^\\s-*<Directory\\s-*\\([^>]+\\)>" 1)
("*Locations*" "^\\s-*<Location\\s-*\\([^>]+\\)>" 1))))))
! "Generic mode for Apache or HTTPD configuration files."))
(when (memq 'apache-log-generic-mode generic-extras-enable-list)
***************
*** 322,329 ****
(2 font-lock-variable-name-face)))
'("access_log\\'")
nil
! "Mode for Apache log files"
! :group 'generic-x-modes))
;;; Samba
(when (memq 'samba-generic-mode generic-extras-enable-list)
--- 316,322 ----
(2 font-lock-variable-name-face)))
'("access_log\\'")
nil
! "Mode for Apache log files"))
;;; Samba
(when (memq 'samba-generic-mode generic-extras-enable-list)
***************
*** 337,344 ****
(2 font-lock-type-face)))
'("smb\\.conf\\'")
'(generic-bracket-support)
! "Generic mode for Samba configuration files."
! :group 'generic-x-modes))
;;; Fvwm
;; This is pretty basic. Also, modes for other window managers could
--- 330,336 ----
(2 font-lock-type-face)))
'("smb\\.conf\\'")
'(generic-bracket-support)
! "Generic mode for Samba configuration files."))
;;; Fvwm
;; This is pretty basic. Also, modes for other window managers could
***************
*** 363,370 ****
nil
'("\\.fvwmrc\\'" "\\.fvwm2rc\\'")
nil
! "Generic mode for FVWM configuration files."
! :group 'generic-x-modes))
;;; X Resource
;; I'm pretty sure I've seen an actual mode to do this, but I don't
--- 355,361 ----
nil
'("\\.fvwmrc\\'" "\\.fvwm2rc\\'")
nil
! "Generic mode for FVWM configuration files."))
;;; X Resource
;; I'm pretty sure I've seen an actual mode to do this, but I don't
***************
*** 377,384 ****
'(("^\\([^:\n]+:\\)" 1 font-lock-variable-name-face))
'("\\.Xdefaults\\'" "\\.Xresources\\'" "\\.Xenvironment\\'" "\\.ad\\'")
nil
! "Generic mode for X Resource configuration files."
! :group 'generic-x-modes))
;;; Hosts
(when (memq 'hosts-generic-mode generic-extras-enable-list)
--- 368,374 ----
'(("^\\([^:\n]+:\\)" 1 font-lock-variable-name-face))
'("\\.Xdefaults\\'" "\\.Xresources\\'" "\\.Xenvironment\\'" "\\.ad\\'")
nil
! "Generic mode for X Resource configuration files."))
;;; Hosts
(when (memq 'hosts-generic-mode generic-extras-enable-list)
***************
*** 389,396 ****
'(("\\([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+\\)" 1 font-lock-constant-face))
'("[hH][oO][sS][tT][sS]\\'")
nil
! "Generic mode for HOSTS files."
! :group 'generic-x-modes))
;;; Windows INF files
(when (memq 'inf-generic-mode generic-extras-enable-list)
--- 379,385 ----
'(("\\([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+\\)" 1 font-lock-constant-face))
'("[hH][oO][sS][tT][sS]\\'")
nil
! "Generic mode for HOSTS files."))
;;; Windows INF files
(when (memq 'inf-generic-mode generic-extras-enable-list)
***************
*** 401,408 ****
'(("^\\(\\[.*\\]\\)" 1 font-lock-constant-face))
'("\\.[iI][nN][fF]\\'")
'(generic-bracket-support)
! "Generic mode for MS-Windows INF files."
! :group 'generic-x-modes))
;;; Windows INI files
;; Should define escape character as well!
--- 390,396 ----
'(("^\\(\\[.*\\]\\)" 1 font-lock-constant-face))
'("\\.[iI][nN][fF]\\'")
'(generic-bracket-support)
! "Generic mode for MS-Windows INF files."))
;;; Windows INI files
;; Should define escape character as well!
***************
*** 424,431 ****
("*Variables*" "^\\s-*\\([^=]+\\)\\s-*=" 1))))))
"Generic mode for MS-Windows INI files.
You can use `ini-generic-mode-find-file-hook' to enter this mode
! automatically for INI files whose names do not end in \".ini\"."
! :group 'generic-x-modes)
(defun ini-generic-mode-find-file-hook ()
"Hook function to enter Ini-Generic mode automatically for INI files.
--- 412,418 ----
("*Variables*" "^\\s-*\\([^=]+\\)\\s-*=" 1))))))
"Generic mode for MS-Windows INI files.
You can use `ini-generic-mode-find-file-hook' to enter this mode
! automatically for INI files whose names do not end in \".ini\".")
(defun ini-generic-mode-find-file-hook ()
"Hook function to enter Ini-Generic mode automatically for INI files.
***************
*** 453,460 ****
(lambda ()
(setq imenu-generic-expression
'((nil "^\\s-*\\(.*\\)\\s-*=" 1))))))
! "Generic mode for MS-Windows Registry files."
! :group 'generic-x-modes))
;;; DOS/Windows BAT files
(when (memq 'bat-generic-mode generic-extras-enable-list)
--- 440,446 ----
(lambda ()
(setq imenu-generic-expression
'((nil "^\\s-*\\(.*\\)\\s-*=" 1))))))
! "Generic mode for MS-Windows Registry files."))
;;; DOS/Windows BAT files
(when (memq 'bat-generic-mode generic-extras-enable-list)
***************
*** 528,535 ****
"\\`[cC][oO][nN][fF][iI][gG]\\."
"\\`[aA][uU][tT][oO][eE][xX][eE][cC]\\.")
'(generic-bat-mode-setup-function)
! "Generic mode for MS-Windows BAT files."
! :group 'generic-x-modes)
(defvar bat-generic-mode-syntax-table nil
"Syntax table in use in `bat-generic-mode' buffers.")
--- 514,520 ----
"\\`[cC][oO][nN][fF][iI][gG]\\."
"\\`[aA][uU][tT][oO][eE][xX][eE][cC]\\.")
'(generic-bat-mode-setup-function)
! "Generic mode for MS-Windows BAT files.")
(defvar bat-generic-mode-syntax-table nil
"Syntax table in use in `bat-generic-mode' buffers.")
***************
*** 608,615 ****
(lambda ()
(setq imenu-generic-expression
'((nil "\\s-/\\([^/]+\\)/[i, \t\n]" 1))))))
! "Mode for Mailagent rules files."
! :group 'generic-x-modes))
;; Solaris/Sys V prototype files
(when (memq 'prototype-generic-mode generic-extras-enable-list)
--- 593,599 ----
(lambda ()
(setq imenu-generic-expression
'((nil "\\s-/\\([^/]+\\)/[i, \t\n]" 1))))))
! "Mode for Mailagent rules files."))
;; Solaris/Sys V prototype files
(when (memq 'prototype-generic-mode generic-extras-enable-list)
***************
*** 632,639 ****
(2 font-lock-variable-name-face)))
'("prototype\\'")
nil
! "Mode for Sys V prototype files."
! :group 'generic-x-modes))
;; Solaris/Sys V pkginfo files
(when (memq 'pkginfo-generic-mode generic-extras-enable-list)
--- 616,622 ----
(2 font-lock-variable-name-face)))
'("prototype\\'")
nil
! "Mode for Sys V prototype files."))
;; Solaris/Sys V pkginfo files
(when (memq 'pkginfo-generic-mode generic-extras-enable-list)
***************
*** 646,653 ****
(2 font-lock-variable-name-face)))
'("pkginfo\\'")
nil
! "Mode for Sys V pkginfo files."
! :group 'generic-x-modes))
;; Javascript mode
;; Includes extra keywords from Armando Singer address@hidden
--- 629,635 ----
(2 font-lock-variable-name-face)))
'("pkginfo\\'")
nil
! "Mode for Sys V pkginfo files."))
;; Javascript mode
;; Includes extra keywords from Armando Singer address@hidden
***************
*** 726,733 ****
(setq imenu-generic-expression
'((nil "^function\\s-+\\([A-Za-z0-9_]+\\)" 1)
("*Variables*" "^var\\s-+\\([A-Za-z0-9_]+\\)" 1))))))
! "Mode for JavaScript files."
! :group 'generic-x-modes))
;; VRML files
(when (memq 'vrml-generic-mode generic-extras-enable-list)
--- 708,714 ----
(setq imenu-generic-expression
'((nil "^function\\s-+\\([A-Za-z0-9_]+\\)" 1)
("*Variables*" "^var\\s-+\\([A-Za-z0-9_]+\\)" 1))))))
! "Mode for JavaScript files."))
;; VRML files
(when (memq 'vrml-generic-mode generic-extras-enable-list)
***************
*** 780,787 ****
("*Definitions*"
"DEF\\s-+\\([-A-Za-z0-9_]+\\)\\s-+\\([A-Za-z0-9]+\\)\\s-*{"
1))))))
! "Generic Mode for VRML files."
! :group 'generic-x-modes))
;; Java Manifests
(when (memq 'java-manifest-generic-mode generic-extras-enable-list)
--- 761,767 ----
("*Definitions*"
"DEF\\s-+\\([-A-Za-z0-9_]+\\)\\s-+\\([A-Za-z0-9]+\\)\\s-*{"
1))))))
! "Generic Mode for VRML files."))
;; Java Manifests
(when (memq 'java-manifest-generic-mode generic-extras-enable-list)
***************
*** 802,809 ****
(2 font-lock-constant-face)))
'("[mM][aA][nN][iI][fF][eE][sS][tT]\\.[mM][fF]\\'")
nil
! "Mode for Java Manifest files"
! :group 'generic-x-modes))
;; Java properties files
(when (memq 'java-properties-generic-mode generic-extras-enable-list)
--- 782,788 ----
(2 font-lock-constant-face)))
'("[mM][aA][nN][iI][fF][eE][sS][tT]\\.[mM][fF]\\'")
nil
! "Mode for Java Manifest files"))
;; Java properties files
(when (memq 'java-properties-generic-mode generic-extras-enable-list)
***************
*** 835,842 ****
(lambda ()
(setq imenu-generic-expression
'((nil "^\\([^#! \t\n\r=:]+\\)" 1))))))
! "Mode for Java properties files."
! :group 'generic-x-modes))
;; C shell alias definitions
(when (memq 'alias-generic-mode generic-extras-enable-list)
--- 814,820 ----
(lambda ()
(setq imenu-generic-expression
'((nil "^\\([^#! \t\n\r=:]+\\)" 1))))))
! "Mode for Java properties files."))
;; C shell alias definitions
(when (memq 'alias-generic-mode generic-extras-enable-list)
***************
*** 854,861 ****
(lambda ()
(setq imenu-generic-expression
'((nil "^\\(alias\\|unalias\\)\\s-+\\([-a-zA-Z0-9_]+\\)" 2))))))
! "Mode for C Shell alias files."
! :group 'generic-x-modes))
;;; Windows RC files
;; Contributed by address@hidden (Alfred Correira)
--- 832,838 ----
(lambda ()
(setq imenu-generic-expression
'((nil "^\\(alias\\|unalias\\)\\s-+\\([-a-zA-Z0-9_]+\\)" 2))))))
! "Mode for C Shell alias files."))
;;; Windows RC files
;; Contributed by address@hidden (Alfred Correira)
***************
*** 947,954 ****
(2 font-lock-variable-name-face nil t))))
'("\\.[rR][cC]\\'")
nil
! "Generic mode for MS-Windows Resource files."
! :group 'generic-x-modes))
;; InstallShield RUL files
;; Contributed by address@hidden
--- 924,930 ----
(2 font-lock-variable-name-face nil t))))
'("\\.[rR][cC]\\'")
nil
! "Generic mode for MS-Windows Resource files."))
;; InstallShield RUL files
;; Contributed by address@hidden
***************
*** 1568,1575 ****
font-lock-variable-name-face "[^_]" "[^_]"))) ; is this face the best
choice?
'("\\.[rR][uU][lL]\\'")
'(generic-rul-mode-setup-function)
! "Generic mode for InstallShield RUL files."
! :group 'generic-x-modes)
(define-skeleton rul-if
"Insert an if statement."
--- 1544,1550 ----
font-lock-variable-name-face "[^_]" "[^_]"))) ; is this face the best
choice?
'("\\.[rR][uU][lL]\\'")
'(generic-rul-mode-setup-function)
! "Generic mode for InstallShield RUL files.")
(define-skeleton rul-if
"Insert an if statement."
***************
*** 1619,1626 ****
(2 font-lock-variable-name-face)))
'("\\.mailrc\\'")
nil
! "Mode for mailrc files."
! :group 'generic-x-modes))
;; Inetd.conf
(when (memq 'inetd-conf-generic-mode generic-extras-enable-list)
--- 1594,1600 ----
(2 font-lock-variable-name-face)))
'("\\.mailrc\\'")
nil
! "Mode for mailrc files."))
;; Inetd.conf
(when (memq 'inetd-conf-generic-mode generic-extras-enable-list)
***************
*** 1640,1647 ****
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([-A-Za-z0-9_]+\\)" 1))))))
! :group 'generic-x-modes))
;; Services
(when (memq 'etc-services-generic-mode generic-extras-enable-list)
--- 1614,1620 ----
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([-A-Za-z0-9_]+\\)" 1))))))))
;; Services
(when (memq 'etc-services-generic-mode generic-extras-enable-list)
***************
*** 1659,1666 ****
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([-A-Za-z0-9_]+\\)" 1))))))
! :group 'generic-x-modes))
;; Password and Group files
(when (memq 'etc-passwd-generic-mode generic-extras-enable-list)
--- 1632,1638 ----
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([-A-Za-z0-9_]+\\)" 1))))))))
;; Password and Group files
(when (memq 'etc-passwd-generic-mode generic-extras-enable-list)
***************
*** 1702,1709 ****
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([-A-Za-z0-9_]+\\):" 1))))))
! :group 'generic-x-modes))
;; Fstab
(when (memq 'etc-fstab-generic-mode generic-extras-enable-list)
--- 1674,1680 ----
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([-A-Za-z0-9_]+\\):" 1))))))))
;; Fstab
(when (memq 'etc-fstab-generic-mode generic-extras-enable-list)
***************
*** 1753,1760 ****
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([/-A-Za-z0-9_]+\\)\\s-+" 1))))))
! :group 'generic-x-modes))
;; From Jacques Duthen <address@hidden>
(when (memq 'show-tabs-generic-mode generic-extras-enable-list)
--- 1724,1730 ----
(function
(lambda ()
(setq imenu-generic-expression
! '((nil "^\\([/-A-Za-z0-9_]+\\)\\s-+" 1))))))))
;; From Jacques Duthen <address@hidden>
(when (memq 'show-tabs-generic-mode generic-extras-enable-list)
***************
*** 1780,1786 ****
(((class color)) (:background "red"))
(t (:weight bold)))
"Font Lock mode face used to highlight TABs."
! :group 'generic-x-modes)
(defface show-tabs-space-face
'((((class grayscale) (background light)) (:background "DimGray" :weight
bold))
--- 1750,1756 ----
(((class color)) (:background "red"))
(t (:weight bold)))
"Font Lock mode face used to highlight TABs."
! :group 'generic-x)
(defface show-tabs-space-face
'((((class grayscale) (background light)) (:background "DimGray" :weight
bold))
***************
*** 1789,1795 ****
(((class color)) (:background "yellow"))
(t (:weight bold)))
"Font Lock mode face used to highlight spaces."
! :group 'generic-x-modes)
(define-generic-mode show-tabs-generic-mode
nil ;; no comment char
--- 1759,1765 ----
(((class color)) (:background "yellow"))
(t (:weight bold)))
"Font Lock mode face used to highlight spaces."
! :group 'generic-x)
(define-generic-mode show-tabs-generic-mode
nil ;; no comment char
***************
*** 1798,1805 ****
nil ;; no auto-mode-alist
;; '(show-tabs-generic-mode-hook-fun)
nil
! "Generic mode to show tabs and trailing spaces"
! :group 'generic-x-modes))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; DNS modes
--- 1768,1774 ----
nil ;; no auto-mode-alist
;; '(show-tabs-generic-mode-hook-fun)
nil
! "Generic mode to show tabs and trailing spaces"))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; DNS modes
***************
*** 1822,1829 ****
;; List of additional automode-alist expressions
'("/etc/named.boot\\'")
;; List of set up functions to call
! nil
! :group 'generic-x-modes))
(when (memq 'named-database-generic-mode generic-extras-enable-list)
--- 1791,1797 ----
;; List of additional automode-alist expressions
'("/etc/named.boot\\'")
;; List of set up functions to call
! nil))
(when (memq 'named-database-generic-mode generic-extras-enable-list)
***************
*** 1838,1845 ****
;; List of additional auto-mode-alist expressions
nil
;; List of set up functions to call
! nil
! :group 'generic-x-modes)
(defvar named-database-time-string "%Y%m%d%H"
"Timestring for named serial numbers.")
--- 1806,1812 ----
;; List of additional auto-mode-alist expressions
nil
;; List of set up functions to call
! nil)
(defvar named-database-time-string "%Y%m%d%H"
"Timestring for named serial numbers.")
***************
*** 1861,1868 ****
;; List of additional auto-mode-alist expressions
'("/etc/resolv[e]?.conf\\'")
;; List of set up functions to call
! nil
! :group 'generic-x-modes))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Modes for spice and common electrical engineering circuit netlist formats
--- 1828,1834 ----
;; List of additional auto-mode-alist expressions
'("/etc/resolv[e]?.conf\\'")
;; List of set up functions to call
! nil))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; Modes for spice and common electrical engineering circuit netlist formats
***************
*** 1906,1913 ****
(function
(lambda()
(setq font-lock-defaults '(generic-font-lock-keywords nil t)))))
! "Generic mode for SPICE circuit netlist files."
! :group 'generic-x-modes))
(when (memq 'ibis-generic-mode generic-extras-enable-list)
--- 1872,1878 ----
(function
(lambda()
(setq font-lock-defaults '(generic-font-lock-keywords nil t)))))
! "Generic mode for SPICE circuit netlist files."))
(when (memq 'ibis-generic-mode generic-extras-enable-list)
***************
*** 1918,1925 ****
("\\(\\(_\\|\\w\\)+\\)\\s-*=" 1 font-lock-variable-name-face))
'("\\.[iI][bB][sS]\\'")
'(generic-bracket-support)
! "Generic mode for IBIS circuit netlist files."
! :group 'generic-x-modes))
(when (memq 'astap-generic-mode generic-extras-enable-list)
--- 1883,1889 ----
("\\(\\(_\\|\\w\\)+\\)\\s-*=" 1 font-lock-variable-name-face))
'("\\.[iI][bB][sS]\\'")
'(generic-bracket-support)
! "Generic mode for IBIS circuit netlist files."))
(when (memq 'astap-generic-mode generic-extras-enable-list)
***************
*** 1956,1963 ****
(function
(lambda()
(setq font-lock-defaults '(generic-font-lock-keywords nil t)))))
! "Generic mode for ASTAP circuit netlist files."
! :group 'generic-x-modes))
(when (memq 'etc-modules-conf-generic-mode generic-extras-enable-list)
--- 1920,1926 ----
(function
(lambda()
(setq font-lock-defaults '(generic-font-lock-keywords nil t)))))
! "Generic mode for ASTAP circuit netlist files."))
(when (memq 'etc-modules-conf-generic-mode generic-extras-enable-list)
***************
*** 2001,2008 ****
;; List of additional automode-alist expressions
'("/etc/modules.conf" "/etc/conf.modules")
;; List of set up functions to call
! nil
! :group 'generic-x-modes))
(provide 'generic-x)
--- 1964,1970 ----
;; List of additional automode-alist expressions
'("/etc/modules.conf" "/etc/conf.modules")
;; List of set up functions to call
! nil))
(provide 'generic-x)
- [Emacs-diffs] Changes to emacs/lisp/generic-x.el,
Lute Kamstra <=