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

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

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

revision 1.337 by monnier, Mon Nov 15 04:51:50 2004 UTC revision 1.338 by monnier, Mon Nov 15 23:09:19 2004 UTC
# Line 606  Faces `compilation-error-face', `compila Line 606  Faces `compilation-error-face', `compila
606                         2)))                         2)))
607      (compilation-internal-error-properties file line end-line col end-col type fmt)))      (compilation-internal-error-properties file line end-line col end-col type fmt)))
608    
609    (defun compilation-move-to-column (col screen)
610      "Go to column COL on the current line.
611    If SCREEN is non-nil, columns are screen columns, otherwise, they are
612    just char-counts."
613      (if screen
614          (move-to-column col)
615        (goto-char (min (+ (line-beginning-position) col) (line-end-position)))))
616    
617  (defun compilation-internal-error-properties (file line end-line col end-col type fmt)  (defun compilation-internal-error-properties (file line end-line col end-col type fmt)
618    "Get the meta-info that will be added as text-properties.    "Get the meta-info that will be added as text-properties.
619  LINE, END-LINE, COL, END-COL are integers or nil.  LINE, END-LINE, COL, END-COL are integers or nil.
# Line 640  FILE should be (ABSOLUTE-FILENAME) or (R Line 648  FILE should be (ABSOLUTE-FILENAME) or (R
648              (beginning-of-line (- (or end-line line) marker-line -1))              (beginning-of-line (- (or end-line line) marker-line -1))
649              (if (or (null end-col) (< end-col 0))              (if (or (null end-col) (< end-col 0))
650                  (end-of-line)                  (end-of-line)
651                (if compilation-error-screen-columns                (compilation-move-to-column
652                    (move-to-column end-col)                 end-col compilation-error-screen-columns))
                 (forward-char end-col)))  
653              (setq end-marker (list (point-marker))))              (setq end-marker (list (point-marker))))
654            (beginning-of-line (if end-line            (beginning-of-line (if end-line
655                                   (- line end-line -1)                                   (- line end-line -1)
656                                 (- loc marker-line -1)))                                 (- loc marker-line -1)))
657            (if col            (if col
658                (if compilation-error-screen-columns                (compilation-move-to-column
659                    (move-to-column col)                 col compilation-error-screen-columns)
                 (forward-char col))  
660              (forward-to-indentation 0))              (forward-to-indentation 0))
661            (setq marker (list (point-marker))))))            (setq marker (list (point-marker))))))
662    
# Line 1491  Use this command in a compilation log bu Line 1497  Use this command in a compilation log bu
1497                (if (car col)                (if (car col)
1498                    (if (eq (car col) -1) ; special case for range end                    (if (eq (car col) -1) ; special case for range end
1499                        (end-of-line)                        (end-of-line)
1500                      (if columns                      (compilation-move-to-column (car col) columns))
                         (move-to-column (car col))  
                       (beginning-of-line)  
                       (forward-char (car col))))  
1501                  (beginning-of-line)                  (beginning-of-line)
1502                  (skip-chars-forward " \t"))                  (skip-chars-forward " \t"))
1503                (if (nth 3 col)                (if (nth 3 col)

Legend:
Removed from v.1.337  
changed lines
  Added in v.1.338

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