Index: auctex/tex.el
diff -u auctex/tex.el:5.532 auctex/tex.el:5.533
--- auctex/tex.el:5.532 Fri Jul 8 16:43:29 2005
+++ auctex/tex.el Fri Jul 15 08:40:23 2005
@@ -1663,16 +1663,21 @@
(defun TeX-run-style-hooks (&rest styles)
"Run the TeX style hooks STYLES."
(mapcar (lambda (style)
- (if (TeX-member style TeX-active-styles 'string-equal)
- () ;Avoid recursion.
+ ;; Avoid recursion.
+ (unless (TeX-member style TeX-active-styles 'string-equal)
(setq TeX-active-styles
(cons style TeX-active-styles))
(TeX-load-style style)
- (if (string-match "\\`\\(.+[/\\]\\)\\([^/\\]*\\)\\'" style)
- (setq style ; Complex path
- (substring style (match-beginning 2) (match-end 2))))
- (mapcar 'funcall
- (cdr-safe (assoc style TeX-style-hook-list)))))
+ (let ((default-directory default-directory))
+ ;; Complex path.
+ (when (string-match "\\`\\(.+[/\\]\\)\\([^/\\]*\\)\\'" style)
+ ;; Adjust `default-directory' to the directory of the style.
+ (setq default-directory (expand-file-name
+ (file-name-directory style))
+ style (substring style
+ (match-beginning 2) (match-end 2))))
+ (mapcar 'funcall
+ (cdr-safe (assoc style TeX-style-hook-list))))))
styles))
(defcustom TeX-parse-self nil
_______________________________________________
auctex-diffs mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/auctex-diffs