[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 258/299: Prettify file names in error overview.
From: |
Stefan Monnier |
Subject: |
[elpa] 258/299: Prettify file names in error overview. |
Date: |
Sun, 02 Nov 2014 03:11:50 +0000 |
monnier pushed a commit to branch externals/auctex
in repository elpa.
commit 4db3ed960f2d200802b7be6faa94501f03d908ea
Author: Mosè Giordano <address@hidden>
Date: Sat Jun 28 17:26:12 2014 +0200
Prettify file names in error overview.
* tex-buf.el (TeX-error-overview-make-entries): Add optional
`master-dir' argument, to shorten file names when they are relative.
(TeX-error-overview): Pass `TeX-master-directory' as argument to
`TeX-error-overview-make-entries'.
---
ChangeLog | 4 ++++
tex-buf.el | 13 +++++++++----
2 files changed, 13 insertions(+), 4 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 96fde52..9b163cc 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -30,6 +30,10 @@
(TeX-error-overview): New function.
(TeX-find-display-help): Expand the name of the file to be visited
starting from the directory of the master file.
+ (TeX-error-overview-make-entries): Add optional `master-dir'
+ argument, to shorten file names when they are relative.
+ (TeX-error-overview): Pass `TeX-master-directory' as argument to
+ `TeX-error-overview-make-entries'.
* tex.el (TeX-error-overview): Autoload `TeX-error-overview'.
(TeX-mode-specific-command-menu-entries): Add an entry for the
diff --git a/tex-buf.el b/tex-buf.el
index 7f669fb..b8785d2 100644
--- a/tex-buf.el
+++ b/tex-buf.el
@@ -2498,8 +2498,9 @@ please restart TeX error overview")))
(message "No more errors.")
(beep))))
-(defun TeX-error-overview-make-entries ()
- "Generate the list of errors to be printed using `tabulated-list-entries'."
+(defun TeX-error-overview-make-entries (&optional master-dir)
+ "Generate the list of errors to be printed using `tabulated-list-entries'.
+Write file names relative to MASTER-DIR when they are not absolute."
(with-current-buffer TeX-error-overview-active-buffer
(let ((id 0)
type file line msg entries)
@@ -2516,7 +2517,11 @@ please restart TeX error overview")))
id
(vector
;; File.
- (if (stringp file) file "")
+ (if (stringp file)
+ (if (file-name-absolute-p file)
+ file
+ (file-relative-name file master-dir))
+ "")
;; Line.
(if (numberp line)
(number-to-string line)
@@ -2634,7 +2639,7 @@ forward, if negative)."
TeX-error-list)
(progn
(setq TeX-error-overview-list-entries
- (TeX-error-overview-make-entries)
+ (TeX-error-overview-make-entries (TeX-master-directory))
TeX-error-overview-orig-window (selected-window)
TeX-error-overview-orig-frame
(window-frame TeX-error-overview-orig-window))
- [elpa] 237/299: Update biblatex support in style file., (continued)
- [elpa] 237/299: Update biblatex support in style file., Stefan Monnier, 2014/11/01
- [elpa] 250/299: Add TeX-previous-error to Command menu., Stefan Monnier, 2014/11/01
- [elpa] 247/299: Convert font-latex-fontify-sectioning to float when used as a number., Stefan Monnier, 2014/11/01
- [elpa] 252/299: Fix possible infinite loop in TeX-parse-all-errors., Stefan Monnier, 2014/11/01
- [elpa] 249/299: Backport from ELPA repository., Stefan Monnier, 2014/11/01
- [elpa] 245/299: Use TeX-esc as completion separator for units in siunitx.el., Stefan Monnier, 2014/11/01
- [elpa] 253/299: Cater for bad boxes in error descriptions., Stefan Monnier, 2014/11/01
- [elpa] 257/299: Fix TeX-find-display-help., Stefan Monnier, 2014/11/01
- [elpa] 251/299: Color TeX Help buffer., Stefan Monnier, 2014/11/01
- [elpa] 255/299: Better check for mgs., Stefan Monnier, 2014/11/01
- [elpa] 258/299: Prettify file names in error overview.,
Stefan Monnier <=
- [elpa] 259/299: Update Future Development section in manual., Stefan Monnier, 2014/11/01
- [elpa] 254/299: Simplify error finding and help displaying functions., Stefan Monnier, 2014/11/01
- [elpa] 263/299: Fix remaining XEmacs compilation issues., Stefan Monnier, 2014/11/01
- [elpa] 260/299: Improve selection of the forward/inverse search method., Stefan Monnier, 2014/11/01
- [elpa] 262/299: Fix some XEmacs compilation issues., Stefan Monnier, 2014/11/01
- [elpa] 264/299: Fix some runtime issues in XEmacs., Stefan Monnier, 2014/11/01
- [elpa] 248/299: Implement TeX-previous-error., Stefan Monnier, 2014/11/01
- [elpa] 267/299: Remove .cvsignore and tests from the release tarball., Stefan Monnier, 2014/11/01
- [elpa] 265/299: Fix other runtime issues in XEmacs and Emacs 21., Stefan Monnier, 2014/11/01
- [elpa] 269/299: Fix outline promotion/demotion., Stefan Monnier, 2014/11/01