Mercurial > hg > xemacs-beta
comparison lisp/modes/verilog-mode.el @ 142:1856695b1fa9 r20-2b5
Import from CVS: tag r20-2b5
author | cvs |
---|---|
date | Mon, 13 Aug 2007 09:33:18 +0200 |
parents | 34a5b81f86ba |
children | 25f70ba0133c |
comparison
equal
deleted
inserted
replaced
141:ea67ad3963dc | 142:1856695b1fa9 |
---|---|
1 ;;; verilog-mode.el --- major mode for editing verilog source in Emacs | 1 ;;; verilog-mode.el --- major mode for editing verilog source in Emacs |
2 ;; | 2 ;; |
3 ;; $Header: /afs/informatik.uni-tuebingen.de/local/web/xemacs/xemacs-cvs/XEmacs/xemacs/lisp/modes/Attic/verilog-mode.el,v 1.3 1997/04/19 23:21:05 steve Exp $ | 3 ;; $Header: /afs/informatik.uni-tuebingen.de/local/web/xemacs/xemacs-cvs/XEmacs/xemacs/lisp/modes/Attic/verilog-mode.el,v 1.4 1997/05/09 03:28:03 steve Exp $ |
4 | 4 |
5 ;; Copyright (C) 1996 Free Software Foundation, Inc. | 5 ;; Copyright (C) 1996 Free Software Foundation, Inc. |
6 | 6 |
7 ;; Author: Michael McNamara (mac@silicon-sorcery.com) | 7 ;; Author: Michael McNamara (mac@silicon-sorcery.com) |
8 ;; President, Silicon Sorcery | 8 ;; President, Silicon Sorcery |
68 ;;; Code: | 68 ;;; Code: |
69 | 69 |
70 (provide 'verilog-mode) | 70 (provide 'verilog-mode) |
71 | 71 |
72 ;; This variable will always hold the version number of the mode | 72 ;; This variable will always hold the version number of the mode |
73 (defconst verilog-mode-version "$$Revision: 1.3 $$" | 73 (defconst verilog-mode-version "$$Revision: 1.4 $$" |
74 "Version of this verilog mode.") | 74 "Version of this verilog mode.") |
75 | 75 |
76 ;; | 76 ;; |
77 ;; A hack so we can support either custom, or the old defvar | 77 ;; A hack so we can support either custom, or the old defvar |
78 ;; | 78 ;; |
91 (` (defvar (, var) (, value) (, doc)))))) | 91 (` (defvar (, var) (, value) (, doc)))))) |
92 | 92 |
93 (defun verilog-customize () | 93 (defun verilog-customize () |
94 "Link to customize screen for Verilog" | 94 "Link to customize screen for Verilog" |
95 (interactive) | 95 (interactive) |
96 (customize 'verilog-mode) | 96 (customize 'verilog) |
97 ) | 97 ) |
98 | 98 |
99 (defgroup verilog-mode nil | 99 (defgroup verilog nil |
100 "Faciliates easy editing of Verilog source text" | 100 "Faciliates easy editing of Verilog source text" |
101 :group 'languages) | 101 :group 'languages) |
102 | 102 |
103 (defcustom verilog-indent-level 3 | 103 (defcustom verilog-indent-level 3 |
104 "*Indentation of Verilog statements with respect to containing block." | 104 "*Indentation of Verilog statements with respect to containing block." |
105 :group 'verilog-mode | 105 :group 'verilog |
106 :type 'integer | 106 :type 'integer |
107 ) | 107 ) |
108 | 108 |
109 (defcustom verilog-indent-level-module 3 | 109 (defcustom verilog-indent-level-module 3 |
110 "* Indentation of Module level Verilog statements. (eg always, initial) | 110 "* Indentation of Module level Verilog statements. (eg always, initial) |
111 Set to 0 to get initial and always statements lined up | 111 Set to 0 to get initial and always statements lined up |
112 on the left side of your screen." | 112 on the left side of your screen." |
113 :group 'verilog-mode | 113 :group 'verilog |
114 :type 'integer | 114 :type 'integer |
115 ) | 115 ) |
116 | 116 |
117 (defcustom verilog-indent-level-declaration 3 | 117 (defcustom verilog-indent-level-declaration 3 |
118 "*Indentation of declarations with respect to containing block. | 118 "*Indentation of declarations with respect to containing block. |
119 Set to 0 to get them list right under containing block." | 119 Set to 0 to get them list right under containing block." |
120 :group 'verilog-mode | 120 :group 'verilog |
121 :type 'integer | 121 :type 'integer |
122 ) | 122 ) |
123 | 123 |
124 (defcustom verilog-indent-level-behavorial 3 | 124 (defcustom verilog-indent-level-behavorial 3 |
125 "*Absolute indentation of first begin in a task or function block | 125 "*Absolute indentation of first begin in a task or function block |
126 Set to 0 to get such code to start at the left side of the screen." | 126 Set to 0 to get such code to start at the left side of the screen." |
127 :group 'verilog-mode | 127 :group 'verilog |
128 :type 'integer | 128 :type 'integer |
129 ) | 129 ) |
130 | 130 |
131 (defcustom verilog-cexp-indent 1 | 131 (defcustom verilog-cexp-indent 1 |
132 "*Indentation of Verilog statements split across lines." | 132 "*Indentation of Verilog statements split across lines." |
133 :group 'verilog-mode | 133 :group 'verilog |
134 :type 'integer | 134 :type 'integer |
135 ) | 135 ) |
136 | 136 |
137 (defcustom verilog-case-indent 2 | 137 (defcustom verilog-case-indent 2 |
138 "*Indentation for case statements." | 138 "*Indentation for case statements." |
139 :group 'verilog-mode | 139 :group 'verilog |
140 :type 'integer | 140 :type 'integer |
141 ) | 141 ) |
142 | 142 |
143 (defcustom verilog-auto-newline t | 143 (defcustom verilog-auto-newline t |
144 "*Non-nil means automatically newline after semicolons" | 144 "*Non-nil means automatically newline after semicolons" |
145 :group 'verilog-mode | 145 :group 'verilog |
146 :type 'integer | 146 :type 'integer |
147 ) | 147 ) |
148 | 148 |
149 (defcustom verilog-auto-indent-on-newline t | 149 (defcustom verilog-auto-indent-on-newline t |
150 "*Non-nil means automatically indent line after newline" | 150 "*Non-nil means automatically indent line after newline" |
151 :group 'verilog-mode | 151 :group 'verilog |
152 :type 'integer | 152 :type 'integer |
153 ) | 153 ) |
154 | 154 |
155 (defcustom verilog-tab-always-indent t | 155 (defcustom verilog-tab-always-indent t |
156 "*Non-nil means TAB in Verilog mode should always reindent the | 156 "*Non-nil means TAB in Verilog mode should always reindent the |
157 current line, regardless of where in the line point is when the TAB | 157 current line, regardless of where in the line point is when the TAB |
158 command is used." | 158 command is used." |
159 :group 'verilog-mode | 159 :group 'verilog |
160 :type 'integer | 160 :type 'integer |
161 ) | 161 ) |
162 | 162 |
163 (defcustom verilog-indent-begin-after-if t | 163 (defcustom verilog-indent-begin-after-if t |
164 "*If true, indent begin statements following if, else, while, for | 164 "*If true, indent begin statements following if, else, while, for |
165 and repeat. otherwise, line them up." | 165 and repeat. otherwise, line them up." |
166 :group 'verilog-mode | 166 :group 'verilog |
167 :type 'boolean ) | 167 :type 'boolean ) |
168 | 168 |
169 (defcustom verilog-auto-endcomments t | 169 (defcustom verilog-auto-endcomments t |
170 "*Non-nil means a comment /* ... */ is set after the ends which ends | 170 "*Non-nil means a comment /* ... */ is set after the ends which ends |
171 cases and functions. The name of the function or case will be set | 171 cases and functions. The name of the function or case will be set |
172 between the braces." | 172 between the braces." |
173 :group 'verilog-mode | 173 :group 'verilog |
174 :type 'boolean ) | 174 :type 'boolean ) |
175 | 175 |
176 (defcustom verilog-minimum-comment-distance 40 | 176 (defcustom verilog-minimum-comment-distance 40 |
177 "*Minimum distance between begin and end required before a comment | 177 "*Minimum distance between begin and end required before a comment |
178 will be inserted. Setting this variable to zero results in every | 178 will be inserted. Setting this variable to zero results in every |
179 end aquiring a comment; the default avoids too many redundanet | 179 end aquiring a comment; the default avoids too many redundanet |
180 comments in tight quarters" | 180 comments in tight quarters" |
181 :group 'verilog-mode | 181 :group 'verilog |
182 :type 'integer | 182 :type 'integer |
183 ) | 183 ) |
184 | 184 |
185 (defvar verilog-auto-lineup '(all) | 185 (defvar verilog-auto-lineup '(all) |
186 "*List of contexts where auto lineup of :'s or ='s should be done. | 186 "*List of contexts where auto lineup of :'s or ='s should be done. |