From debbugs-submit-bounces@debbugs.gnu.org Wed Apr 02 12:31:19 2025 Received: (at submit) by debbugs.gnu.org; 2 Apr 2025 16:31:19 +0000 Received: from localhost ([127.0.0.1]:59122 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1u00zm-0006Bn-4T for submit@debbugs.gnu.org; Wed, 02 Apr 2025 12:31:18 -0400 Received: from lists.gnu.org ([2001:470:142::17]:38790) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1u00zi-0006BI-Ij for submit@debbugs.gnu.org; Wed, 02 Apr 2025 12:31:16 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1u00zc-0000RN-Ij for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2025 12:31:08 -0400 Received: from mail-il1-x12b.google.com ([2607:f8b0:4864:20::12b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1u00zW-0007OG-Q7 for bug-gnu-emacs@gnu.org; Wed, 02 Apr 2025 12:31:08 -0400 Received: by mail-il1-x12b.google.com with SMTP id e9e14a558f8ab-3d439dc0548so191155ab.3 for ; Wed, 02 Apr 2025 09:30:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1743611459; x=1744216259; darn=gnu.org; h=mime-version:message-id:date:subject:to:from:from:to:cc:subject :date:message-id:reply-to; bh=4Kg787R4Yw9jLQkXlMgaGWOEpMmDYQDhAMeXUdzGTOo=; b=EyGeql1l7xaH6TqRoLrjzsEFNeZyXNGRajMbq5vhyZeV+cGNqn/N30TWvNdzimcW66 M42BPGdnhMjd2mRPBzPpPCNbwn8ySZHUgfDcdXdXjlEY6b2MeR+kRB2oFiZjv52y8iyp AslA2dXeGdRlnTBdHvOGuaR7Pv8p44cLs7PdRR/GEzwCyITri5dfHrJhNo8JGZXYxtaz SLxX10Mm1Xs5WtAHCs/+/572lQhWwvgtdyufLR1GL0V0ZGac33Tqu/TfNePzGpDEZzTj 2eMcZ+q+iCH65ee3rQC2shtREVDHRdDN9l8tVIkOFLt7LCF8b7WoZvFEKssFBo0EpeuR PlwA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743611459; x=1744216259; h=mime-version:message-id:date:subject:to:from:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=4Kg787R4Yw9jLQkXlMgaGWOEpMmDYQDhAMeXUdzGTOo=; b=l3LSuf8XZvpopH7Ft7ZXThjUnUb3fWPUYZgRI0dT26421T04XQOJ2N0WA3q4+FpXnG sjFr8tVvvkWJ1BVRYtKcbXy/8APPts0ryuPUh3CdO9NI71A3kMjEajcNTM4vYGj1vnhR QDqluvta+p+TwNmJYTMrnFTcrnAshD7/oDccFT7ZFy72duAOUqLBHXvtvSncmRmpVEQ/ mWipei81vYOw2gLTC8XiXY6er5dRUXYX6rYroeQHstCqjrtn1bqw8gQiQhPfHl4XcUhd v+qCHernHnIplG8w07d4NDe8WompDacaPKn+K6L9V1mp3q8bzfjb1g4Y+X601Ck0FHYk DZNA== X-Gm-Message-State: AOJu0YygM05CYOm0wCszmSYgeFumET6WFr3uMd2hc0P7QKOoCB/FIEKY Lnbf5xbDWU9qP5+UrcuaoTWYLwn9YU9DAZtOXP62bWAGR3YbNqHXutQkncOjFg== X-Gm-Gg: ASbGncuuakSliuiqAocjlGcQky6CdrzSsXrev9Kgff5s+mQq3bZyH0xHf/CC4HdZ4AN S0R8mxd17FwRT4GWAeG0eluCWuJv245AwVCc4vGwVZSCn82k2hxkNUilgBHWwL6GQekYmNhr0sz eE4lsHgv+aA3xUZq0JxsUBCF168S8rbth5hxQuMBZZ6FWGtkM2JRiuFiiqfXrlN8TiNpOxZNGaP X23MCqHknzNZu5mOJPS5aPhPKPUnRlij6ltRvlegieYqu+41WwRlUTryD8T7W4WHPyCUDARec7f 9XJ4kGrGaE4JSwdRGzwQr+dEDjBXJ8aMrPeHCbUqFY+me66dj+GdQC9c3HFXSrxa X-Google-Smtp-Source: AGHT+IHfcXChx0ZNBvHocDhV2Y4hfiTtxqdL6JgJ64h4PSL965sBcWxZHZQAyK24hsLKq4bnFNE1Iw== X-Received: by 2002:a05:6e02:1b03:b0:3d5:df34:b21c with SMTP id e9e14a558f8ab-3d5e0907411mr159307535ab.6.1743611458747; Wed, 02 Apr 2025 09:30:58 -0700 (PDT) Received: from bapiya (97-122-123-18.hlrn.qwest.net. [97.122.123.18]) by smtp.gmail.com with ESMTPSA id e9e14a558f8ab-3d5d5a74499sm32733535ab.38.2025.04.02.09.30.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 02 Apr 2025 09:30:58 -0700 (PDT) From: Tom Tromey To: bug-gnu-emacs@gnu.org Subject: 29.4; VC annotate does not display tabs properly X-Attribution: Tom Date: Wed, 02 Apr 2025 10:30:57 -0600 Message-ID: <87bjte5xvi.fsf@tromey.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::12b; envelope-from=tromey@adacore.com; helo=mail-il1-x12b.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 1.0 (+) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.0 (/) Some projects I work on use tab characters for indentation. I used 'C-x v =' to annotate a file from one of these projects. In this case, because the VC-provided margin text is not a multiple of 8 characters, the tabs are rendered improperly, making the program text look strange. As an example, open emacs/src/alloc.c and C-x v = Then search for the tab character in code (with comments the weirdness isn't as pronounced). Here's an example from emacs where I've turned the tabs into spaces so you can see the effect: b88e9cded7ae (Paul Eggert 2016-01-26 226) else b88e9cded7ae (Paul Eggert 2016-01-26 227) { b88e9cded7ae (Paul Eggert 2016-01-26 228) if (!malloc_using_checking) b88e9cded7ae (Paul Eggert 2016-01-26 229) { b88e9cded7ae (Paul Eggert 2016-01-26 230) /* Work around a bug in glibc's malloc. MALLOC_CHECK_ must be One simple fix would be to ensure that the margin text is always a multiple of 8. However, a more sophisticated approach may be possible as well. In GNU Emacs 29.4 (build 1, x86_64-redhat-linux-gnu, GTK+ Version 3.24.43, cairo version 1.18.2) of 2025-03-13 built on 0cbb79ebeb714371b64bef3269323882 System Description: Fedora Linux 41 (Workstation Edition) Configured using: 'configure --build=x86_64-redhat-linux-gnu --host=x86_64-redhat-linux-gnu --program-prefix= --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --runstatedir=/run --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-cairo --with-dbus --with-gif --with-gpm=no --with-harfbuzz --with-jpeg --with-json --with-modules --with-native-compilation=aot --with-pgtk --with-png --with-rsvg --with-sqlite3 --with-tiff --with-tree-sitter --with-webp --with-xpm build_alias=x86_64-redhat-linux-gnu host_alias=x86_64-redhat-linux-gnu CC=gcc 'CFLAGS=-DMAIL_USE_LOCKF -O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=x86-64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -mtls-dialect=gnu2 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer ' 'LDFLAGS=-Wl,-z,relro -Wl,--as-needed -Wl,-z,pack-relative-relocs -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -specs=/usr/lib/rpm/redhat/redhat-package-notes ' PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig CXX=g++ 'CXXFLAGS=-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=x86-64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -mtls-dialect=gnu2 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer '' Configured features: ACL CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GSETTINGS HARFBUZZ JPEG JSON LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 MODULES NATIVE_COMP NOTIFY INOTIFY PDUMPER PGTK PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF TOOLKIT_SCROLL_BARS TREE_SITTER WEBP XIM GTK3 ZLIB Important settings: value of $LANG: en_US.UTF-8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Annotate Minor modes in effect: shell-dirtrack-mode: t which-function-mode: t erc-services-mode: t erc-networks-mode: t server-mode: t savehist-mode: t tooltip-mode: t global-eldoc-mode: t show-paren-mode: t electric-indent-mode: t mouse-wheel-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t buffer-read-only: t column-number-mode: t line-number-mode: t indent-tabs-mode: t transient-mark-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t Load-path shadows: /home/tromey/.emacs.d/elpa/ggtags-0.9.0/ggtags hides /home/tromey/.emacs.d/elpa/ggtags-0.8.13/ggtags /home/tromey/.emacs.d/elpa/ggtags-0.9.0/ggtags-pkg hides /home/tromey/.emacs.d/elpa/ggtags-0.8.13/ggtags-pkg /home/tromey/.emacs.d/elpa/ggtags-0.9.0/ggtags-autoloads hides /home/tromey/.emacs.d/elpa/ggtags-0.8.13/ggtags-autoloads Features: (shadow bbdb-message mailalias mail-hist emacsbug sh-script smie executable dabbrev goto-addr log-edit python ada-ts-mode-lspclient-eglot ada-ts-mode ada-ts-indentation ada-ts-casing eglot external-completion array jsonrpc ert debug backtrace flymake-proc flymake ada-ts-mode-lspclient treesit ada-ts-mode-autoloads noutline outline ggtags-autoloads loaddefs-gen tar-mode arc-mode archive-mode cus-edit cus-start package-vc lisp-mnt url-http url-auth url-gw display-line-numbers gud vc-annotate copyright vc-hg vc-bzr vc-src vc-sccs vc-svn vc-cvs vc-rcs log-view pcvs-util conf-mode term/xterm xterm mule-util ggtags hippie-exp etags fileloop generator xref project bug-reference vc-git cc-mode cc-fonts cc-guess cc-menus cc-cmds add-log flow-fill smerge-mode diff diff-mode gnus-html url-queue help-fns radix-tree url-cache mm-url sort smiley gnus-cite mm-archive mail-extr textsec uni-scripts idna-mapping ucs-normalize uni-confusable textsec-check gnus-bcklg gnus-async qp gnus-ml disp-table misearch multi-isearch gnus-topic nndraft nnmh nnfolder utf-7 bbdb-gnus bbdb-mua bbdb-com crm network-stream nsm gnus-agent gnus-srvr gnus-score score-mode nnvirtual gnus-msg gnus-art mm-uu mml2015 mm-view mml-smime smime gnutls dig nntp gnus-cache gnus-sum shr pixel-fill kinsoku url-file svg dom gnus-group gnus-undo smtpmail gnus-start gnus-dbus gnus-cloud nnimap nnmail mail-source utf7 nnoo gnus-spec gnus-int gnus-range message sendmail yank-media puny rfc822 mml mml-sec epa epg rfc6068 epg-config mm-decode mm-bodies mm-encode mail-parse rfc2231 rfc2047 rfc2045 ietf-drums mailabbrev gmm-utils mailheader gnus-win gnus nnheader gnus-util mail-utils range mm-util mail-prsvr display-fill-column-indicator flyspell ispell diminish appt diary-lib diary-loaddefs cal-menu calendar cal-loaddefs tramp tramp-loaddefs trampver tramp-integration files-x tramp-compat shell pcomplete parse-time which-func imenu autorevert filenotify desktop frameset cus-load git-link erc-track erc-notify erc-desktop-notifications erc-match erc-services notifications dbus erc-hl-nicks color erc-button erc-fill erc-stamp wid-edit erc-goodies erc iso8601 time-date thingatpt pp format-spec erc-backend erc-networks erc-common erc-compat compat erc-loaddefs dired-aux dired-x dired dired-loaddefs comp comp-cstr cl-extra warnings icons advice vc-dir ewoc vc vc-dispatcher flycheck easy-mmode find-func help-mode rx dash cl pcase jka-compr compile text-property-search cc-styles cc-align cc-engine cc-vars cc-defs bbdb derived bbdb-site timezone ange-ftp comint ansi-osc ansi-color ring server savehist finder-inf clang-rename clang-include-fixer let-alist clang-format xml info package browse-url url url-proxy url-privacy url-expand url-methods url-history url-cookie generate-lisp-file url-domsuf url-util mailcap url-handlers url-parse auth-source cl-seq eieio eieio-core cl-macs password-cache json subr-x map byte-opt gv bytecomp byte-compile url-vars cl-loaddefs cl-lib rmc iso-transl tooltip cconv eldoc paren electric uniquify ediff-hook vc-hooks lisp-float-type elisp-mode mwheel term/pgtk-win pgtk-win term/common-win pgtk-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list replace newcomment text-mode lisp-mode prog-mode register page tab-bar menu-bar rfn-eshadow isearch easymenu timer select scroll-bar mouse jit-lock font-lock syntax font-core term/tty-colors frame minibuffer nadvice seq simple cl-generic indonesian philippine cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese composite emoji-zwj charscript charprop case-table epa-hook jka-cmpr-hook help abbrev obarray oclosure cl-preloaded button loaddefs theme-loaddefs faces cus-face macroexp files window text-properties overlay sha1 md5 base64 format env code-pages mule custom widget keymap hashtable-print-readable backquote threads dbusbind inotify dynamic-setting system-font-setting font-render-setting cairo gtk pgtk multi-tty make-network-process native-compile emacs) Memory information: ((conses 16 1300064 422488) (symbols 48 57113 1) (strings 32 496408 8613) (string-bytes 1 13434307) (vectors 16 168369) (vector-slots 8 3590796 73717) (floats 8 506 768) (intervals 56 34255 18946) (buffers 984 93)) From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 03 03:47:31 2025 Received: (at 77465) by debbugs.gnu.org; 3 Apr 2025 07:47:31 +0000 Received: from localhost ([127.0.0.1]:60810 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1u0FIR-0002C3-2a for submit@debbugs.gnu.org; Thu, 03 Apr 2025 03:47:31 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59536) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1u0FIO-0002Bl-6e for 77465@debbugs.gnu.org; Thu, 03 Apr 2025 03:47:29 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1u0FII-00057I-PR; Thu, 03 Apr 2025 03:47:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=5gwjhi4k+MeJ/YDESv7HFri2ZSHmq985vlv4D3eT19Y=; b=Iu8sYCTa5n+Z1CESFoCX AreEzpHulgOJaWnVVj5PgT6EB2k4tvLw2OPax1E7U33VrtYSlz6inLta35QJV79cbwfyXDE4yQhdD lBDc7+eBLyxIr8bxg92Al06EDQro1mGcsUcg2rcrsA8Y2WYdL1GLmh5PA3M0Pid9qcIi7gPXoXXVt MLgJChy0HrIVOsHJazRVut05dtWT6souTgfChBZvrVYXe/rlPnsaG8biVxzMVsneuX4sCEHE+Ud53 Zh6IKU6jfDhMhN+uzMKJxV/UgVkzNTOg2IMvBZMmW9WYeCPKyNJAGS33oKOKya2BkrniLZuJRYb2g uj/e5+gWy8ZyIA==; Date: Thu, 03 Apr 2025 10:47:17 +0300 Message-Id: <86ldshzny2.fsf@gnu.org> From: Eli Zaretskii To: Tom Tromey In-Reply-To: <87bjte5xvi.fsf@tromey.com> (bug-gnu-emacs@gnu.org) Subject: Re: bug#77465: 29.4; VC annotate does not display tabs properly References: <87bjte5xvi.fsf@tromey.com> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 77465 Cc: 77465@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Wed, 02 Apr 2025 10:30:57 -0600 > From: Tom Tromey via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > > Some projects I work on use tab characters for indentation. Emacs uses TABs mixed with SPCes as a matter of policy. > I used 'C-x v =' to annotate a file from one of these projects. > > In this case, because the VC-provided margin text is not a multiple of 8 > characters, the tabs are rendered improperly, making the program text > look strange. > > As an example, open emacs/src/alloc.c and C-x v = > > Then search for the tab character in code (with comments the weirdness > isn't as pronounced). > > Here's an example from emacs where I've turned the tabs into spaces so > you can see the effect: > > b88e9cded7ae (Paul Eggert 2016-01-26 226) else > b88e9cded7ae (Paul Eggert 2016-01-26 227) { > b88e9cded7ae (Paul Eggert 2016-01-26 228) if (!malloc_using_checking) > b88e9cded7ae (Paul Eggert 2016-01-26 229) { > b88e9cded7ae (Paul Eggert 2016-01-26 230) /* Work around a bug in glibc's malloc. MALLOC_CHECK_ must be AFAICT, "git annotate" produces the same effect when invoked from the shell prompt. I'm not sure we should try to be "holier than the Pope" here. > One simple fix would be to ensure that the margin text is always a > multiple of 8. I don't think this is practical, since Git doesn't guarantee the prefix of a line to be of a fixed width. Here's a typical example: 47099d6f7 (Richard M. Stallman 1993-06-06 21:16:51 +0000 27) 4588ec205 (Jim Blandy 1991-07-03 12:10:07 +0000 28) a08795204 (Richard M. Stallman 1995-11-12 05:20:12 +0000 29) fd2e066a8 (Geoff Voelker 1995-11-07 07:14:59 +0000 30) fd2e066a8 (Geoff Voelker 1995-11-07 07:14:59 +0000 31) e5560ff7d (Andreas Schwab 2012-06-16 14:24:15 +0200 32) d43721a22 (Andrew Innes 2000-08-22 22:14:00 +0000 33) 502b9b644 (Jim Blandy 1992-07-13 19:54:34 +0000 34) 428a555ec (Károly Lőrentey 2004-01-05 05:54:35 +0000 35) 4588ec205 (Jim Blandy 1991-07-03 12:10:07 +0000 36) 4588ec205 (Jim Blandy 1991-07-03 12:10:07 +0000 37) 4588ec205 (Jim Blandy 1991-07-03 12:10:07 +0000 38) 97cf50e75 (Richard M. Stallman 1996-04-23 20:32:58 +0000 39) 58b2bb63f (Richard M. Stallman 1995-08-21 21:56:40 +0000 40) > However, a more sophisticated approach may be possible as well. The only idea I have is to replace each tab with a suitable number of spaces, but that would probably make this command much slower, since the buffer created by "C-x v =" is typically very large. Any other ideas? From debbugs-submit-bounces@debbugs.gnu.org Thu Apr 03 10:56:22 2025 Received: (at 77465) by debbugs.gnu.org; 3 Apr 2025 14:56:22 +0000 Received: from localhost ([127.0.0.1]:35145 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1u0LzR-0003oV-L0 for submit@debbugs.gnu.org; Thu, 03 Apr 2025 10:56:22 -0400 Received: from mail-io1-xd2b.google.com ([2607:f8b0:4864:20::d2b]:60832) by debbugs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.84_2) (envelope-from ) id 1u0LzP-0003oF-Jr for 77465@debbugs.gnu.org; Thu, 03 Apr 2025 10:56:20 -0400 Received: by mail-io1-xd2b.google.com with SMTP id ca18e2360f4ac-85da5a3667bso27947739f.1 for <77465@debbugs.gnu.org>; Thu, 03 Apr 2025 07:56:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=adacore.com; s=google; t=1743692174; x=1744296974; darn=debbugs.gnu.org; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:from:to:cc:subject:date:message-id:reply-to; bh=Z2F5z1SkVgL27/rEecggy+yWBIEUFCyazvuUCGnsZg8=; b=Lm9r4tnAF/yWIPAdA/ekvDnuXu1bZSz0iGIOHrTz8Wk5vI4a0X2/PV2+DZBXPrA1KF p/bTeThTdptfPa93ZAdVYSHA6okrV0GQtDAsFEic+dp2+5/cFaxEVXTyWuBOFxIUJXvV ZfKZsRSkdRAJUZeereJa4vXV2dvtlJQSWR31krR1sBUm22uhHIKhgEPbLywoTmqktNez eustC/vN31HIsj/Y6w/FF3dxb5me1XZzhrkqjb8ZE4qxEJ855c2vbNSkCzztQhQQ2rfe XDw0atAOv+jkjTjFHOiiSnun41Z0wrkXYllr3CPIxWtfqUbU6iPAoLQilI0X7Q+o50Rc eqWQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1743692174; x=1744296974; h=mime-version:user-agent:message-id:date:references:in-reply-to :subject:cc:to:from:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=Z2F5z1SkVgL27/rEecggy+yWBIEUFCyazvuUCGnsZg8=; b=gbvveqXr+5N/ceYHlj2ZCjeR6cRQSpZ7uibTyChHzRdaXir+qoSB222fOmMku8gTAe zQemZmyfczI4Q8OhQAp6rxHX56VuuCc4o0rh10vomIEJKsQmRcPVOwbr6fA0frG67XsO qEuJsQEIizUNApsOdqChEKpXr7RKDPdTlawn0bOQ+6yUsjMYXbr+0p+FShqP1FV/ppLs og3Thri0weeZV7Cf5GloX3Ot6rs18W7o5SHZc5PzQffY6zOvbifHX9Zc1atuYyuPzcrF 7lwbIQGl1GRX8+muC3BvRVqkKcKZ4r6jq1cg3xPQnMjQyf10tTsXjB/2IH0wVyd4QrAb eI1Q== X-Forwarded-Encrypted: i=1; AJvYcCXXnfVrytKwhLLNVQ3sw16WYqI8k8X5iQ+y3eKn8auOqf3rE3EtOD9BdHtgswnmQhH9h1ks/A==@debbugs.gnu.org X-Gm-Message-State: AOJu0YzRzXr+jTyE+ATyzWi/nKHa+axT61LKCD3kliREY5IRakRMl/gA Hc7EeN0DJJ1vDsNwlIpe5rOHJdhXQJstv6T2fGdrPm6MWD0cT4KbU45q8qV+IukbNV5zGmvgxZw = X-Gm-Gg: ASbGncsAUrlE7WWbhiiBaY20AARyS94osFaw5xwhpN527pNyJibGrlIZGi4ACE37O66 e7upzu9gfHgpfVUybSuJy0Wj9RWmGjx1fIwDLLLJuKF6UDE4HquGNkwKs3GPPEeesAsEKLSnCFs ZQNSjGz4zMwvbGYoFQufw6+HVgn5A+u7GndHeCNolUz5Jb418B4ZSuZRBENIHx+2vNKoPkk9vx5 W3U2BpTQTf42650Ld57OAHuDcXTmhKeXfn4SEi0Cu36+3NRVlcOmc8xZ3JQM0i5SuzC35NjC9cp L6lOtvnXIMzA7VGXVjECmTUZbYVmHq+veB+39T8bx1jr1gbmu1ikrIuEm151aEZk X-Google-Smtp-Source: AGHT+IEhqjv5Pqz/YgttJKFYOII5hohazntee/V3bfC+ZkZDXMfWegVylRD1HhGlQiMRkmAf7LI4eQ== X-Received: by 2002:a05:6602:3798:b0:85b:4484:182c with SMTP id ca18e2360f4ac-85e9e920b66mr2293401339f.11.1743692173670; Thu, 03 Apr 2025 07:56:13 -0700 (PDT) Received: from bapiya (97-122-123-18.hlrn.qwest.net. [97.122.123.18]) by smtp.gmail.com with ESMTPSA id 8926c6da1cb9f-4f4b5d2461esm339418173.90.2025.04.03.07.56.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 03 Apr 2025 07:56:13 -0700 (PDT) From: Tom Tromey To: Eli Zaretskii Subject: Re: bug#77465: 29.4; VC annotate does not display tabs properly In-Reply-To: <86ldshzny2.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 03 Apr 2025 10:47:17 +0300") References: <87bjte5xvi.fsf@tromey.com> <86ldshzny2.fsf@gnu.org> X-Attribution: Tom Date: Thu, 03 Apr 2025 08:56:12 -0600 Message-ID: <87mscx2t0z.fsf@tromey.com> User-Agent: Gnus/5.13 (Gnus v5.13) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 77465 Cc: 77465@debbugs.gnu.org, Tom Tromey X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) >> b88e9cded7ae (Paul Eggert 2016-01-26 230) /* Work around a bug in glibc's malloc. MALLOC_CHECK_ must be Eli> AFAICT, "git annotate" produces the same effect when invoked from the Eli> shell prompt. I'm not sure we should try to be "holier than the Pope" Eli> here. I see it as being along the line of font-locking the annotation buffer by age -- it's a display feature to help make the output more readable. That is, git may do the wrong thing but Emacs doesn't have to. >> One simple fix would be to ensure that the margin text is always a >> multiple of 8. Eli> I don't think this is practical, since Git doesn't guarantee the Eli> prefix of a line to be of a fixed width. I didn't realize that. >> However, a more sophisticated approach may be possible as well. Eli> The only idea I have is to replace each tab with a suitable number of Eli> spaces, but that would probably make this command much slower, since Eli> the buffer created by "C-x v =" is typically very large. Eli> Any other ideas? It's been a long time since I dug into this kind of thing but I was wondering if there is some kind of display and/or text property feature that would help. Maybe putting a :align-to on the space following the ")" would help. Note that, at least in the repositories I use, annotation display is already slow enough (presumably due to extensive history in git) that another minor slowdown to find the correct width would not really be noticeable. Tom