From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: =?iso-8859-1?q?Gustav_H=E5llberg?= Newsgroups: gmane.emacs.bugs Subject: vc-annotate does not copy truncate-lines from the origin buffer Date: 17 Apr 2003 11:34:18 +0200 Sender: bug-gnu-emacs-bounces+gnu-bug-gnu-emacs=m.gmane.org@gnu.org Message-ID: NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: main.gmane.org 1050572135 21292 80.91.224.249 (17 Apr 2003 09:35:35 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Thu, 17 Apr 2003 09:35:35 +0000 (UTC) Original-X-From: bug-gnu-emacs-bounces+gnu-bug-gnu-emacs=m.gmane.org@gnu.org Thu Apr 17 11:35:33 2003 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1965np-0005XI-00 for ; Thu, 17 Apr 2003 11:35:33 +0200 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 1965nO-0002dY-03 for gnu-bug-gnu-emacs@m.gmane.org; Thu, 17 Apr 2003 05:35:06 -0400 Original-Received: from list by monty-python.gnu.org with tmda-scanned (Exim 4.10.13) id 1965mx-0001rg-00 for bug-gnu-emacs@gnu.org; Thu, 17 Apr 2003 05:34:39 -0400 Original-Received: from mail by monty-python.gnu.org with spam-scanned (Exim 4.10.13) id 1965mr-0001Z4-00 for bug-gnu-emacs@gnu.org; Thu, 17 Apr 2003 05:34:33 -0400 Original-Received: from dns.vtab.com ([62.20.90.195] helo=gorgon.vtab.com) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 1965mn-0001Is-00 for bug-gnu-emacs@gnu.org; Thu, 17 Apr 2003 05:34:30 -0400 Original-Received: from virtutech.se (ash.hq.vtech [10.0.0.90]) by gorgon.vtab.com (8.11.7/8.11.0) with ESMTP id h3H9YIR31675; Thu, 17 Apr 2003 11:34:18 +0200 Original-Received: (from gustav@localhost) by virtutech.se (8.11.6/8.11.6) id h3H9YI215716; Thu, 17 Apr 2003 11:34:18 +0200 Original-To: bug-gnu-emacs@gnu.org Original-Lines: 11 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Bug reports for GNU Emacs, the Swiss army knife of text editors List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: bug-gnu-emacs-bounces+gnu-bug-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.bugs:4827 X-Report-Spam: http://spam.gmane.org/gmane.emacs.bugs:4827 --=-=-= If you have set truncate-lines in a buffer, it would make a lot of sense for the vc-annotate command to use that setting in the newly created annotation buffer too (the same could probably be said for other variables too, but this is the one I was being annoyed by right now). Suggested patch attached. - Gustav --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=vc-annotate-truncate-lines.patch --- /disk1/sources/emacs-21.3/lisp/vc.el Mon Jan 20 12:03:30 2003 +++ vc.el Thu Apr 17 11:27:14 2003 @@ -2941,6 +2941,7 @@ (vc-ensure-vc-buffer) (let* ((temp-buffer-name (concat "*Annotate " (buffer-name) "*")) (temp-buffer-show-function 'vc-annotate-display) + (temp-truncate-lines truncate-lines) (rev (vc-workfile-version (buffer-file-name))) (vc-annotate-version (if prefix (read-string @@ -2953,7 +2954,7 @@ nil nil "1.0")) 1.0)) (vc-annotate-backend (vc-backend (buffer-file-name)))) - (message "Annotating...") + (message "Annotating... %s" temp-truncate-lines) (if (not (vc-find-backend-function vc-annotate-backend 'annotate-command)) (error "Sorry, annotating is not implemented for %s" vc-annotate-backend)) @@ -2962,6 +2963,9 @@ (file-name-nondirectory (buffer-file-name)) (get-buffer temp-buffer-name) vc-annotate-version)) + (save-excursion + (set-buffer temp-buffer-name) + (setq truncate-lines temp-truncate-lines)) ;; Don't use the temp-buffer-name until the buffer is created ;; (only after `with-output-to-temp-buffer'.) (setq vc-annotate-buffers --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit _______________________________________________ Bug-gnu-emacs mailing list Bug-gnu-emacs@gnu.org http://mail.gnu.org/mailman/listinfo/bug-gnu-emacs --=-=-=--