git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH/RFC v2 2/2] diff.tcl: call "apply_tab_size 1" to fix alignment instead of spaces.

From
GitHub Chris Idema <github_chris_idema@proton.me>
Date
Jan 28, 2026, 09:07 UTC
Message-ID
<IY45fwv_UnBCPcj48xZ_Z6wduiXBWyIY71uw9lUY_DjFy7plkb1c980ZdCCMzx1S76QW9NgaXzbpejuVZ1tI4CicRalwL0v3VIiwx20g9Q8=@proton.me>
In-Reply-To
<xmqqfr7qeixq.fsf@gitster.g>
> Why does this series first add proc expand_tabs, only to remove its

use in this second step? Shouldn't these two patches be squashed into one, and explain why we want to use "apply_tab_size 1" here?

Because I received feedback on the first commit and realized the second solution is better. I didn't know you could squash the patches ones the first one was reviewed. I generally don't like rewriting history, but I will be squashing the commits. For some reason Johannes Sixt disappeared from the mailing list. I've never used such a clunky interface before. I guess linux users like self-flagellation.

> It is clear that "apply_tab_size 0" is designed for a single-parent

diff, while "apply_tab_size 1" is designed for two parents diff. If this new series to make sense, I think it should argue why that setting that users are already familiar with for the past 14 years is wrong, and "apply_tab_size 1" is more appropriate for a single parent diff (and presumably "apply_tab_size 2" is better for two aprent diff), I think.

The bug has been there for 14 years I guess. In gitk it works as expected.In git diff it works as expected when setting up the pager. In git-gui it doesn't. The alignment is inconsistent with gitk. For code review it's horrible. Here is a link to 2 images that show the before and after: https://github.com/git/git/pull/2179#issuecomment-3799576864

-- Chris
Previous: Junio C HamanoNext: Johannes Sixt
Message 13 of 30 in “diff.tcl: fixed alignment of tabs in git-gui diff by using spaces”
  1. diff.tcl: fixed alignment of tabs in git-gui diff by using spacesChris Idema via GitGitGadget, Jan 26, 2026
  2. Johannes SixtJan 26, 2026
  3. GitHub Chris IdemaJan 26, 2026
  4. Johannes SixtJan 26, 2026
  5. GitHub Chris IdemaJan 26, 2026
  6. Johannes SixtJan 26, 2026
  7. GitHub Chris IdemaJan 26, 2026
  8. GitHub Chris IdemaJan 26, 2026
  9. 0/2 diff.tcl: Fixed alignment of tabs in git-gui diff by using spaces.Chris Idema via GitGitGadget, Jan 27, 2026
  10. 2/2 diff.tcl: call "apply_tab_size 1" to fix alignment instead of spaces.Chris Idema via GitGitGadget, Jan 27, 2026
  11. Junio C HamanoJan 27, 2026
  12. Junio C HamanoJan 27, 2026
  13. GitHub Chris IdemaJan 28, 2026
  14. Johannes SixtJan 28, 2026
  15. GitHub Chris IdemaJan 28, 2026
  16. Johannes SixtJan 28, 2026
  17. Junio C HamanoJan 28, 2026
  18. Junio C HamanoJan 29, 2026
  19. GitHub Chris IdemaJan 29, 2026
  20. Johannes SixtJan 29, 2026
  21. Junio C HamanoJan 29, 2026
  22. 1/2 diff.tcl: fixed alignment of tabs in git-gui diff by using spacesChris Idema via GitGitGadget, Jan 27, 2026
  23. diff.tcl: made alignment of tabs in git-gui diff consistent with gitkChris Idema via GitGitGadget, Jan 28, 2026
  24. Johannes SixtJan 28, 2026
  25. GitHub Chris IdemaJan 28, 2026
  26. Junio C HamanoJan 29, 2026
  27. git-gui: shift tabstops to account for the first column of context diffsChris Idema via GitGitGadget, Jan 29, 2026
  28. Johannes SixtJan 29, 2026
  29. GitHub Chris IdemaMar 4, 2026
  30. Johannes SixtMar 4, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.