~a-roehler/python-mode/XEmacs-compat-test

« back to all changes in this revision

Viewing changes to python-mode.el

  • Committer: Andreas Roehler
  • Date: 2012-01-12 18:40:42 UTC
  • Revision ID: andreas.roehler@online.de-20120112184042-iu4nrigye5rqy2u8
menu entry "Customize Python mode" (customize-group 'python-mode)

thanks Richard Everson

new `python-mode' customization group
avoid confusion with python.el variables 

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
(unless (featurep 'xemacs)
40
40
  (require 'highlight-indentation))
41
41
 
42
 
(defgroup python nil
 
42
(defgroup python-mode nil
43
43
  "Support for the Python programming language, <http://www.python.org/>"
44
44
  :group 'languages
45
45
  :prefix "py-")
53
53
`\\[py-guess-indent-offset]' can usually guess a good value when
54
54
you're editing someone else's Python code."
55
55
  :type 'integer
56
 
  :group 'python)
 
56
  :group 'python-mode)
57
57
(make-variable-buffer-local 'py-indent-offset)
58
58
 
59
59
(defcustom pdb-path '/usr/lib/python2.7/pdb.py
62
62
If you ignore the location `M-x py-guess-pdb-path' might display it.
63
63
"
64
64
  :type 'variable
65
 
  :group 'python)
 
65
  :group 'python-mode)
66
66
 
67
67
(defun py-guess-pdb-path ()
68
68
  "If py-pdb-path isn't set, find location of pdb.py. "
80
80
(defcustom py-install-directory nil
81
81
  "Directory where python-mode.el and it's subdirectories should be installed. Needed for completion and other environment stuff only. "
82
82
  :type 'string
83
 
  :group 'python)
 
83
  :group 'python-mode)
84
84
 
85
85
(defcustom py-guess-py-install-directory-p t
86
86
  "If in cases, `py-install-directory' isn't set,  `py-set-load-path'should guess it from `buffer-file-name'. "
87
87
 
88
88
  :type 'boolean
89
 
  :group 'python)
 
89
  :group 'python-mode)
90
90
 
91
91
(defcustom py-load-pymacs-p  nil
92
92
 "If Pymacs as delivered with python-mode.el shall be loaded.
96
96
See original source: http://pymacs.progiciels-bpi.ca"
97
97
 
98
98
:type 'boolean
99
 
:group 'python)
 
99
:group 'python-mode)
100
100
 
101
101
(defcustom py-report-level-p nil
102
102
  "If indenting functions should report reached indent level.
104
104
Default is nil. "
105
105
 
106
106
  :type 'boolean
107
 
  :group 'python)
 
107
  :group 'python-mode)
108
108
 
109
109
(defcustom py-hide-show-minor-mode-p nil
110
110
  "If hide-show minor-mode should be on, default is nil. "
111
111
 
112
112
  :type 'boolean
113
 
  :group 'python)
 
113
  :group 'python-mode)
114
114
 
115
115
(defcustom py-outline-minor-mode-p t
116
116
  "If outline minor-mode should be on, default is `t'. "
117
117
 
118
118
  :type 'boolean
119
 
  :group 'python)
 
119
  :group 'python-mode)
120
120
 
121
121
(defcustom py-start-run-py-shell t
122
122
  "If `python-mode' should start a python-shell, `py-shell'. Default is `t'.
124
124
A running python-shell presently is needed by complete-functions. "
125
125
 
126
126
  :type 'boolean
127
 
  :group 'python)
 
127
  :group 'python-mode)
128
128
 
129
129
(defcustom py-use-number-face-p nil
130
130
  "If digits incl. hex-digits should get an own py-number-face.
134
134
when `py-number-face' was customized differently than inherited
135
135
default face. "
136
136
  :type 'boolean
137
 
  :group 'python)
 
137
  :group 'python-mode)
138
138
 
139
139
;; vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
140
140
(defcustom py-close-provides-newline t
141
141
  "If a newline is inserted, when line after block isn't empty. Default is non-nil. "
142
142
  :type 'boolean
143
 
  :group 'python)
 
143
  :group 'python-mode)
144
144
(make-variable-buffer-local 'py-close-provides-newline)
145
145
 
146
146
(defcustom py-dedent-keep-relative-column t
147
147
  "If point should follow dedent or kind of electric move to end of line. Default is t - keep relative position. "
148
148
  :type 'boolean
149
 
  :group 'python)
 
149
  :group 'python-mode)
150
150
 
151
151
(defcustom py-indent-honors-multiline-listing nil
152
152
  "If `t', indents to 1+ column of opening delimiter. If `nil', indent adds one level to the beginning of statement. Default is `nil'. "
153
153
  :type 'boolean
154
 
  :group 'python)
 
154
  :group 'python-mode)
155
155
 
156
156
(defcustom py-indent-honors-inline-comment nil
157
157
  "If non-nil, indents to column of inlined comment start.
158
158
Default is nil. "
159
159
  :type 'boolean
160
 
  :group 'python)
 
160
  :group 'python-mode)
161
161
 
162
162
(defcustom py-closing-list-dedents-bos nil
163
163
  "If non-nil, closing parentesis dedents onto column of statement, otherwise keeps additional `py-indent-offset', default is nil "
164
164
  :type 'boolean
165
 
  :group 'python)
 
165
  :group 'python-mode)
166
166
 
167
167
(defcustom py-electric-colon-active-p nil
168
168
  "`py-electric-colon' feature.  Default is `nil'. See lp:837065 for discussions. "
169
169
  :type 'boolean
170
 
  :group 'python)
 
170
  :group 'python-mode)
171
171
 
172
172
(defcustom py-electric-comment-p t
173
173
  "If \"#\" should call `py-electric-comment'. Default is `t'. "
174
174
  :type 'boolean
175
 
  :group 'python)
 
175
  :group 'python-mode)
176
176
 
177
177
(defcustom py-electric-comment-add-space-p nil
178
178
  "If py-electric-comment should add a space.  Default is `nil'. "
179
179
  :type 'boolean
180
 
  :group 'python)
 
180
  :group 'python-mode)
181
181
 
182
182
(defcustom py-mark-decorators nil
183
183
  "If py-mark-def-or-class functions should mark decorators too. Default is `nil'. "
184
184
  :type 'boolean
185
 
  :group 'python)
 
185
  :group 'python-mode)
186
186
 
187
187
(defcustom py-tab-indent t
188
188
  "*Non-nil means TAB in Python mode calls `py-indent-line'."
189
189
  :type 'boolean
190
 
  :group 'python)
 
190
  :group 'python-mode)
191
191
 
192
192
(defcustom py-complete-function 'py-shell-complete
193
193
  "Function used for completion in buffers. "
195
195
                 (const :tag "Pymacs based py-complete" py-complete)
196
196
                 (const :tag "py-shell-complete" py-shell-complete)
197
197
                 (const :tag "IPython's ipython-complete" ipython-complete))
198
 
  :group 'python)
 
198
  :group 'python-mode)
199
199
 
200
200
(defcustom py-shell-complete-function 'py-completion-at-point
201
201
  "Function used for completion in buffers. "
202
202
  :type '(choice (const :tag "py-completion-at-point" py-completion-at-point)
203
203
                 (const :tag "Pymacs based py-complete" py-complete)
204
204
                 (const :tag "IPython's ipython-complete" ipython-complete))
205
 
  :group 'python)
 
205
  :group 'python-mode)
206
206
 
207
207
(defcustom py-encoding-string " # -*- coding: utf-8 -*-"
208
208
  "Default string specifying encoding of a Python file. "
209
209
  :type 'string
210
 
  :group 'python)
 
210
  :group 'python-mode)
211
211
 
212
212
(defvar py-encoding-string-re "^[ \t]*#[ \t]*-\\*-[ \t]*coding:.+-\\*-"
213
213
  "Matches encoding string of a Python file. ")
217
217
(defcustom py-shebang-startstring "#! /bin/env"
218
218
  "Detecting the shell in head of file. "
219
219
  :type 'string
220
 
  :group 'python)
 
220
  :group 'python-mode)
221
221
 
222
222
(defvar py-shebang-regexp "#![ \t]?\\([^ \t\n]+\\)[ \t]?\\([iptj]+ython[^ \t\n]*\\)"
223
223
  "Detecting the shell in head of file. ")
225
225
(defcustom py-python-command-args '("-i")
226
226
  "*List of string arguments to be used when starting a Python shell."
227
227
  :type '(repeat string)
228
 
  :group 'python)
 
228
  :group 'python-mode)
229
229
(make-variable-buffer-local 'py-python-command-args)
230
230
 
231
231
(set-default 'py-python-command-args  '("-i"))
247
247
(defcustom py-lhs-inbound-indent 1
248
248
  "When line starts a multiline-assignment: How many colums indent should be more than opening bracket, brace or parenthesis. "
249
249
  :type 'integer
250
 
  :group 'python)
 
250
  :group 'python-mode)
251
251
(make-variable-buffer-local 'py-lhs-inbound-indent)
252
252
 
253
253
(defcustom py-rhs-inbound-indent 1
254
254
  "When inside a multiline-assignment: How many colums indent should be more than opening bracket, brace or parenthesis. "
255
255
  :type 'integer
256
 
  :group 'python)
 
256
  :group 'python-mode)
257
257
(make-variable-buffer-local 'py-rhs-inbound-indent)
258
258
 
259
259
(defcustom py-continuation-offset 2
261
261
Continuation lines are those that immediately follow a backslash
262
262
terminated line. "
263
263
  :type 'integer
264
 
  :group 'python)
 
264
  :group 'python-mode)
265
265
 
266
266
(defcustom py-smart-indentation t
267
267
  "*Should `python-mode' try to automagically set some indentation variables?
283
283
so if you want to defeat the automagic configuration, you must also
284
284
set `py-smart-indentation' to nil in your `python-mode-hook'."
285
285
  :type 'boolean
286
 
  :group 'python)
 
286
  :group 'python-mode)
287
287
(make-variable-buffer-local 'py-smart-indentation)
288
288
 
289
289
(defcustom py-align-multiline-strings-p t
293
293
lines are aligned to column zero."
294
294
  :type '(choice (const :tag "Align under preceding line" t)
295
295
                 (const :tag "Align to column zero" nil))
296
 
  :group 'python)
 
296
  :group 'python-mode)
297
297
 
298
298
(defcustom py-block-comment-prefix "##"
299
299
  "*String used by \\[comment-region] to comment out a block of code.
302
302
should be of the form `#x...' where `x' is not a blank or a tab, and
303
303
`...' is arbitrary).  However, this string should not end in whitespace."
304
304
  :type 'string
305
 
  :group 'python)
 
305
  :group 'python-mode)
306
306
 
307
307
(defcustom py-indent-comments t
308
308
  "When t, comment lines are indented. "
309
309
  :type 'boolean
310
 
  :group 'python)
 
310
  :group 'python-mode)
311
311
 
312
312
(defcustom py-temp-directory
313
313
  (let ((ok '(lambda (x)
328
328
can write into: the value (if any) of the environment variable TMPDIR,
329
329
/usr/tmp, /tmp, /var/tmp, or the current directory."
330
330
  :type 'string
331
 
  :group 'python)
 
331
  :group 'python-mode)
332
332
 
333
333
(defcustom py-beep-if-tab-change t
334
334
  "*Ring the bell if `tab-width' is changed.
342
342
displayed in the echo area, and if `py-beep-if-tab-change' is non-nil
343
343
the Emacs bell is also rung as a warning."
344
344
  :type 'boolean
345
 
  :group 'python)
 
345
  :group 'python-mode)
346
346
 
347
347
(defcustom py-jump-on-exception t
348
348
  "*Jump to innermost exception frame in *Python Output* buffer.
350
350
Python code synchronously in a subprocess, jump immediately to the
351
351
source code of the innermost traceback frame."
352
352
  :type 'boolean
353
 
  :group 'python)
 
353
  :group 'python-mode)
354
354
 
355
355
(defcustom py-ask-about-save t
356
356
  "If not nil, ask about which buffers to save before executing some code.
357
357
Otherwise, all modified buffers are saved without asking."
358
358
  :type 'boolean
359
 
  :group 'python)
 
359
  :group 'python-mode)
360
360
 
361
361
(defcustom py-backspace-function 'backward-delete-char-untabify
362
362
  "*Function called by `py-electric-backspace' when deleting backwards."
363
363
  :type 'function
364
 
  :group 'python)
 
364
  :group 'python-mode)
365
365
 
366
366
(defcustom py-delete-function 'delete-char
367
367
  "*Function called by `py-electric-delete' when deleting forwards."
368
368
  :type 'function
369
 
  :group 'python)
 
369
  :group 'python-mode)
370
370
 
371
371
(defcustom py-pdbtrack-do-tracking-p t
372
372
  "*Controls whether the pdbtrack feature is enabled or not.
376
376
source file and line that the program is stopped at, much the same way
377
377
as gud-mode does for debugging C programs with gdb."
378
378
  :type 'boolean
379
 
  :group 'python)
 
379
  :group 'python-mode)
380
380
(make-variable-buffer-local 'py-pdbtrack-do-tracking-p)
381
381
 
382
382
(defcustom py-pdbtrack-minor-mode-string " PDB"
383
383
  "*String to use in the minor mode list when pdbtrack is enabled."
384
384
  :type 'string
385
 
  :group 'python)
 
385
  :group 'python-mode)
386
386
 
387
387
(defcustom py-import-check-point-max
388
388
  20000
399
399
  '("java" "javax")
400
400
  "Imported packages that imply `jython-mode'."
401
401
  :type '(repeat string)
402
 
  :group 'python)
 
402
  :group 'python-mode)
403
403
(make-obsolete-variable 'py-jpython-packages 'py-jython-packages nil)
404
404
 
405
405
(defcustom py-current-defun-show  t
408
408
Default is `t'."
409
409
 
410
410
:type 'boolean
411
 
:group 'python)
 
411
:group 'python-mode)
412
412
 
413
413
(defcustom py-current-defun-delay  2
414
414
 "When called interactively, `py-current-defun' should wait PY-WHICH-FUNC-DELAY seconds at the definition name found, before returning to previous position. "
415
415
 
416
416
:type 'number
417
 
:group 'python)
 
417
:group 'python-mode)
418
418
 
419
419
(defcustom py-send-receive-delay  5
420
420
 "Seconds to wait for output, used by `python-send-receive'. "
421
421
 
422
422
:type 'number
423
 
:group 'python)
 
423
:group 'python-mode)
424
424
 
425
425
(defvar py-exec-command nil
426
426
  "Mode commands will set this. ")
448
448
 
449
449
"
450
450
  :type 'string
451
 
  :group 'python)
 
451
  :group 'python-mode)
452
452
(make-variable-buffer-local 'py-master-file)
453
453
 
454
454
(defvar py-pychecker-history nil)
474
474
(defcustom py-shell-input-prompt-1-regexp "^>>> "
475
475
  "*A regular expression to match the input prompt of the shell."
476
476
  :type 'string
477
 
  :group 'python)
 
477
  :group 'python-mode)
478
478
 
479
479
(defcustom py-shell-input-prompt-2-regexp "^[.][.][.] "
480
480
  "*A regular expression to match the input prompt of the shell after the
481
481
  first line of input."
482
482
  :type 'string
483
 
  :group 'python)
 
483
  :group 'python-mode)
484
484
 
485
485
(defcustom py-shell-switch-buffers-on-execute t
486
486
  "When non-nil switch to the Python output buffer. "
487
487
  :type 'boolean
488
 
  :group 'python)
 
488
  :group 'python-mode)
489
489
 
490
490
(defcustom py-split-windows-on-execute t
491
491
  "When non-nil split windows, make Python output buffer other. "
492
492
  :type 'boolean
493
 
  :group 'python)
 
493
  :group 'python-mode)
494
494
 
495
495
(defcustom py-hide-show-keywords
496
496
  '(
501
501
  "Keywords composing visible heads.
502
502
Also used by (minor-)outline-mode "
503
503
  :type '(repeat string)
504
 
  :group 'python)
 
504
  :group 'python-mode)
505
505
 
506
506
(defcustom py-hide-show-hide-docstrings t
507
507
  "*Controls if doc strings can be hidden by hide-show"
508
508
  :type 'boolean
509
 
  :group 'python)
 
509
  :group 'python-mode)
510
510
 
511
511
(defcustom python-mode-hook nil
512
512
  "Hook run when entering Python mode."
516
516
(defcustom imenu-create-index-p t
517
517
  "Non-nil means Python mode creates and displays an index menu of functions and global variables. "
518
518
  :type 'boolean
519
 
  :group 'python)
 
519
  :group 'python-mode)
520
520
 
521
521
(defcustom py-shell-name "python"
522
522
  "A PATH/TO/EXECUTABLE or default value `py-shell' may look for, if no shell is specified by command. "
523
523
  :type 'string
524
 
  :group 'python)
 
524
  :group 'python-mode)
525
525
(make-variable-buffer-local 'py-shell-name)
526
526
 
527
527
(defcustom py-source-modes '(python-mode jython-mode)
530
530
If a file is loaded into a buffer that is in one of these major modes, it is considered Python source by `py-load-file', which uses the
531
531
value to determine defaults."
532
532
  :type '(repeat function)
533
 
  :group 'python)
 
533
  :group 'python-mode)
534
534
 
535
535
(defcustom py-shell-prompt-alist
536
536
  '(("ipython" . "^In \\[[0-9]+\\]: *")
542
542
PROGRAM can also be t, which specifies the default when no other
543
543
element matches `py-shell-name'."
544
544
  :type 'string
545
 
  :group 'python
546
 
  :version "24.1")
 
545
  :group 'python-mode)
547
546
 
548
547
(defcustom py-shell-continuation-prompt-alist
549
548
  '(("ipython" . "^   [.][.][.]+: *")
556
555
PROGRAM can also be t, which specifies the default when no other
557
556
element matches `py-shell-name'."
558
557
  :type 'string
559
 
  :group 'python
560
 
  :version "24.1")
 
558
  :group 'python-mode)
561
559
 
562
560
;; ipython.el
563
561
(defvar ipython-de-input-prompt-regexp "\\(?:
587
585
Sets `py-match-paren-key' in python-mode-map.
588
586
Customize `py-match-paren-key' which key to use. "
589
587
  :type 'boolean
590
 
  :group 'python)
 
588
  :group 'python-mode)
591
589
 
592
590
(defcustom py-match-paren-key "%"
593
591
  "*String used by \\[comment-region] to comment out a block of code.
596
594
should be of the form `#x...' where `x' is not a blank or a tab, and
597
595
`...' is arbitrary).  However, this string should not end in whitespace."
598
596
  :type 'string
599
 
  :group 'python)
 
597
  :group 'python-mode)
600
598
 
601
599
(defcustom py-kill-empty-line t
602
600
  "*If t, py-indent-forward-line kills empty lines. "
603
601
  :type 'boolean
604
 
  :group 'python)
 
602
  :group 'python-mode)
605
603
 
606
604
(defcustom py-remove-cwd-from-path t
607
605
  "Whether to allow loading of Python modules from the current directory.
610
608
reasons, as it is easy for the Python process to be started
611
609
without the user's realization (e.g. to perform completion)."
612
610
  :type 'boolean
613
 
  :group 'python)
 
611
  :group 'python-mode)
614
612
 
615
613
(defcustom py-imenu-show-method-args-p nil
616
614
  "*Controls echoing of arguments of functions & methods in the Imenu buffer.
617
615
When non-nil, arguments are printed."
618
616
  :type 'boolean
619
 
  :group 'python)
 
617
  :group 'python-mode)
620
618
 
621
619
(defcustom python-default-interpreter 'cpython
622
620
  "*Which Python interpreter is used by default.
635
633
\\[py-toggle-shells] to change the interpreter shell."
636
634
  :type '(choice (const :tag "Python (a.k.a. CPython)" cpython)
637
635
                 (const :tag "JPython" jpython))
638
 
  :group 'python)
 
636
  :group 'python-mode)
639
637
 
640
638
(defcustom python-python-command-args '("-i")
641
639
  "*List of string arguments to be used when starting a Python shell."
642
640
  :type '(repeat string)
643
 
  :group 'python)
 
641
  :group 'python-mode)
644
642
 
645
643
(defcustom python-jython-command-args '("-i")
646
644
  "*List of string arguments to be used when starting a Jython shell."
660
658
gud-mode does for debugging C programs with gdb, but without
661
659
having to restart the program."
662
660
  :type 'boolean
663
 
  :group 'python)
 
661
  :group 'python-mode)
664
662
(make-variable-buffer-local 'python-pdbtrack-do-tracking-p)
665
663
 
666
664
(defcustom python-pdbtrack-minor-mode-string " PDB"
667
665
  "*Minor-mode sign to be displayed when pdbtrack is active."
668
666
  :type 'string
669
 
  :group 'python)
 
667
  :group 'python-mode)
670
668
 
671
669
(defcustom python-shell-prompt-alist
672
670
  '(("ipython" . "^In \\[[0-9]+\\]: *")
678
676
PROGRAM can also be t, which specifies the default when no other
679
677
element matches `python-python-command'."
680
678
  :type 'string
681
 
  :group 'python)
 
679
  :group 'python-mode)
682
680
 
683
681
(defcustom python-shell-continuation-prompt-alist
684
682
  '(("ipython" . "^   [.][.][.]+: *")
691
689
PROGRAM can also be t, which specifies the default when no other
692
690
element matches `python-python-command'."
693
691
  :type 'string
694
 
  :group 'python)
 
692
  :group 'python-mode)
695
693
 
696
694
(defcustom python-python-command "python"
697
695
  "Shell command to run Python interpreter.
709
707
  "Input matching this regexp is not saved on the history list.
710
708
Default ignores all inputs of 0, 1, or 2 non-blank characters."
711
709
  :type 'regexp
712
 
  :group 'python)
 
710
  :group 'python-mode)
713
711
 
714
712
(defcustom python-remove-cwd-from-path t
715
713
  "Whether to allow loading of Python modules from the current directory.
727
725
If a file is loaded into a buffer that is in one of these major modes, it is considered Python source by `py-load-file', which uses the
728
726
value to determine defaults."
729
727
  :type '(repeat function)
730
 
  :group 'python)
 
728
  :group 'python-mode)
731
729
 
732
730
(defcustom python-jython-packages '("java" "javax" "org" "com")
733
731
  "Packages implying `jython-mode'.
734
732
If these are imported near the beginning of the buffer, `python-mode'
735
733
actually punts to `jython-mode'."
736
734
  :type '(repeat string)
737
 
  :group 'python)
 
735
  :group 'python-mode)
738
736
 
739
737
 
740
738
(defface py-number-face
741
739
  '((t (:inherit default)))
742
740
  ;; '((t (:inherit 'font-lock-variable-name-face)))
743
741
  "Highlight numbers. "
744
 
  :group 'python)
 
742
  :group 'python-mode)
745
743
(defvar py-number-face 'py-number-face)
746
744
 
747
745
(defface py-XXX-tag-face
748
746
  '((t (:inherit font-lock-string-face)))
749
747
  "XXX\\|TODO\\|FIXME "
750
 
  :group 'python)
 
748
  :group 'python-mode)
751
749
(defvar py-XXX-tag-face 'py-XXX-tag-face)
752
750
 
753
751
;; ;; Face for None, True, False, self, and Ellipsis
754
752
(defface py-pseudo-keyword-face
755
753
  '((t (:inherit font-lock-keyword-face)))
756
754
  "Face for pseudo keywords in Python mode, like self, True, False, Ellipsis."
757
 
  :group 'python)
 
755
  :group 'python-mode)
758
756
(defvar py-pseudo-keyword-face 'py-pseudo-keyword-face)
759
757
 
760
758
(defface py-variable-name-face
761
759
  '((t (:inherit default)))
762
760
  ;; '((t (:inherit 'font-lock-variable-name-face)))
763
761
  "Face method decorators."
764
 
  :group 'python)
 
762
  :group 'python-mode)
765
763
(defvar py-variable-name-face 'py-variable-name-face)
766
764
 
767
765
;; PEP 318 decorators
768
766
(defface py-decorators-face
769
767
  '((t (:inherit font-lock-keyword-face)))
770
768
  "Face method decorators."
771
 
  :group 'python)
 
769
  :group 'python-mode)
772
770
(defvar py-decorators-face 'py-decorators-face)
773
771
 
774
772
;; Face for builtins
775
773
(defface py-builtins-face
776
774
  '((t (:inherit font-lock-builtin-face)))
777
775
  "Face for builtins like TypeError, object, open, and exec."
778
 
  :group 'python)
 
776
  :group 'python-mode)
779
777
(defvar py-builtins-face 'py-builtins-face)
780
778
 
781
779
(defface py-class-name-face
782
780
  '((t (:inherit font-lock-type-face)))
783
781
  "Face for classes."
784
 
  :group 'python)
 
782
  :group 'python-mode)
785
783
(defvar py-class-name-face 'py-class-name-face)
786
784
 
787
785
;; XXX, TODO, and FIXME comments and such
788
786
(defface py-exception-name-face
789
787
  '((t (:inherit font-lock-builtin-face)))
790
788
  "."
791
 
  :group 'python)
 
789
  :group 'python-mode)
792
790
(defvar py-exception-name-face 'py-exception-name-face)
793
791
 
794
792
;; ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1244
1242
            ["pychecker-run" py-pychecker-run]
1245
1243
            ["Debugger" pdb]
1246
1244
            "-"
 
1245
            ["Customize Python mode" (customize-group 'python-mode)]
1247
1246
            ["Help on symbol" py-describe-symbol]
1248
1247
            ["Complete symbol" completion-at-point]
1249
1248
            ["Find function" py-find-function]