/[emacs]/emacs/lisp/progmodes/delphi.el
ViewVC logotype

Diff of /emacs/lisp/progmodes/delphi.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3.15 by lektu, Fri Jun 10 14:15:47 2005 UTC revision 3.16 by lektu, Mon Jul 4 02:58:48 2005 UTC
# Line 88  Line 88 
88    )    )
89    
90  (defgroup delphi nil  (defgroup delphi nil
91    "Major mode for editing Delphi source in Emacs"    "Major mode for editing Delphi source in Emacs."
92    :version "21.1"    :version "21.1"
93    :group 'languages)    :group 'languages)
94    
# Line 1510  before the indent, the point is moved to Line 1510  before the indent, the point is moved to
1510       (set-marker-insertion-type marked-point t)       (set-marker-insertion-type marked-point t)
1511       (when (/= old-indent new-indent)       (when (/= old-indent new-indent)
1512             (delete-region line-start (point))             (delete-region line-start (point))
1513             (insert (make-string new-indent ?\ )))             (insert (make-string new-indent ?\s)))
1514       (goto-char marked-point)       (goto-char marked-point)
1515       (set-marker marked-point nil))))       (set-marker marked-point nil))))
1516    
# Line 1775  An error is raised if not in a comment." Line 1775  An error is raised if not in a comment."
1775                 (comment-end (delphi-token-end end-comment))                 (comment-end (delphi-token-end end-comment))
1776                 (content-start (delphi-comment-content-start start-comment))                 (content-start (delphi-comment-content-start start-comment))
1777                 (content-indent (delphi-column-of content-start))                 (content-indent (delphi-column-of content-start))
1778                 (content-prefix (make-string content-indent ?\ ))                 (content-prefix (make-string content-indent ?\s))
1779                 (content-prefix-re delphi-leading-spaces-re)                 (content-prefix-re delphi-leading-spaces-re)
1780                 (p nil)                 (p nil)
1781                 (marked-point (point-marker))) ; Maintain our position reliably.                 (marked-point (point-marker))) ; Maintain our position reliably.
# Line 1783  An error is raised if not in a comment." Line 1783  An error is raised if not in a comment."
1783              ;; // style comments need more work.              ;; // style comments need more work.
1784              (setq content-prefix              (setq content-prefix
1785                    (let ((comment-indent (delphi-column-of comment-start)))                    (let ((comment-indent (delphi-column-of comment-start)))
1786                      (concat (make-string comment-indent ?\ ) "//"                      (concat (make-string comment-indent ?\s) "//"
1787                              (make-string (- content-indent comment-indent 2)                              (make-string (- content-indent comment-indent 2)
1788                                           ?\ )))                                           ?\s)))
1789                    content-prefix-re (concat delphi-leading-spaces-re                    content-prefix-re (concat delphi-leading-spaces-re
1790                                              "//"                                              "//"
1791                                              delphi-spaces-re)                                              delphi-spaces-re)
# Line 1857  comment block. If not in a // comment, j Line 1857  comment block. If not in a // comment, j
1857               (comment-start (delphi-token-start start-comment))               (comment-start (delphi-token-start start-comment))
1858               (content-start (delphi-comment-content-start start-comment))               (content-start (delphi-comment-content-start start-comment))
1859               (prefix               (prefix
1860                (concat (make-string (delphi-column-of comment-start) ?\ ) "//"                (concat (make-string (delphi-column-of comment-start) ?\s) "//"
1861                        (make-string (- content-start comment-start 2) ?\ ))))                        (make-string (- content-start comment-start 2) ?\s))))
1862          (delete-horizontal-space)          (delete-horizontal-space)
1863          (newline)          (newline)
1864          (insert prefix)))))          (insert prefix)))))

Legend:
Removed from v.3.15  
changed lines
  Added in v.3.16

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26