The diff view is pretty OK, but could be much better:
[x] Make resizable, convert to menus
[ ] Colourize rows
[x] Handle tabs trailing whitespace (especially \r\n); Windows text rendering can't really do it, so we may need to render ourselves
[x] Save diff, just like copy
[ ] Navigate by file/hunk
[ ] Find text, Windows provides a built-in dialog for this
[ ] In the future, handle getting diffs from different sources, as well ones with commits attached (could we display commit metadata in the diff window? save/copy would also format an email-style patch too)
[ ] Make text fragments copyable, but complicates impl because then we need a real (rich?) text view
Old post:
Right now, it's a ListBox that can barely handle newlines.
Prior art from i.e. SourceSafe would suggest a split view, but the lg2 diff format and git's own view of them makes this a little awkward, because it deals with actual diffs, not comparing two file instances. The SccDiff API also deals in single files, but we can support DirDiff later, and that can be the exact same window, just we gather a bigger diff.
What would be a more interesting way of going about it is say, using a ListView and an image list; with the git_diff_foreach (not print since we're not making a blob/printing to text), we can insert an item and tag it with file/hunk/binary/context/add/remove. We can also add commands for i.e saving/copying the diff as a text blob, dealing with hunks, etc.
The diff view is pretty OK, but could be much better:
Old post:
Right now, it's a ListBox that can barely handle newlines.
Prior art from i.e. SourceSafe would suggest a split view, but the lg2 diff format and git's own view of them makes this a little awkward, because it deals with actual diffs, not comparing two file instances. The SccDiff API also deals in single files, but we can support DirDiff later, and that can be the exact same window, just we gather a bigger diff.
What would be a more interesting way of going about it is say, using a ListView and an image list; with the git_diff_foreach (not print since we're not making a blob/printing to text), we can insert an item and tag it with file/hunk/binary/context/add/remove. We can also add commands for i.e saving/copying the diff as a text blob, dealing with hunks, etc.