[Python-checkins] python/dist/src/Misc python-mode.el,4.36,4.37

montanaro@users.sourceforge.net montanaro@users.sourceforge.net
Thu, 31 Jul 2003 21:00:34 -0700


Update of /cvsroot/python/python/dist/src/Misc
In directory sc8-pr-cvs1:/tmp/cvs-serv20998

Modified Files:
	python-mode.el 
Log Message:
make pending-delete/delete-selection mode work with py-electric-colon


Index: python-mode.el
===================================================================
RCS file: /cvsroot/python/python/dist/src/Misc/python-mode.el,v
retrieving revision 4.36
retrieving revision 4.37
diff -C2 -d -r4.36 -r4.37
*** python-mode.el	31 Jul 2003 04:59:48 -0000	4.36
--- python-mode.el	1 Aug 2003 04:00:32 -0000	4.37
***************
*** 1188,1192 ****
  		(not (looking-at py-no-outdent-re)))
  	 )))
!       
  (defun py-electric-colon (arg)
    "Insert a colon.
--- 1188,1192 ----
  		(not (looking-at py-no-outdent-re)))
  	 )))
! 
  (defun py-electric-colon (arg)
    "Insert a colon.
***************
*** 1195,1199 ****
  non-electrically.  Electric behavior is inhibited inside a string or
  comment."
!   (interactive "P")
    (self-insert-command (prefix-numeric-value arg))
    ;; are we in a string or comment?
--- 1195,1199 ----
  non-electrically.  Electric behavior is inhibited inside a string or
  comment."
!   (interactive "*P")
    (self-insert-command (prefix-numeric-value arg))
    ;; are we in a string or comment?
***************
*** 1948,1951 ****
--- 1948,1953 ----
  
  ;; required for pending-del and delsel modes
+ (put 'py-electric-colon 'delete-selection t) ;delsel
+ (put 'py-electric-colon 'pending-delete   t) ;pending-del
  (put 'py-electric-backspace 'delete-selection 'supersede) ;delsel
  (put 'py-electric-backspace 'pending-delete   'supersede) ;pending-del