Add diff options as icon buttons#108
Open
stdout-se wants to merge 3 commits into
Open
Conversation
Shows tabs and spaces in diff view if setting is enabled
Add option in settings->code to select between different whitespace and line ending display methods
Add buttons to the right above the diff pane that allows user to select diff view options. All icons are MIT Licensed according to: https://www.svgrepo.com/svg/361077/clear-all https://www.svgrepo.com/svg/361075/circle-slash https://www.svgrepo.com/svg/361072/circle-large-filled https://www.svgrepo.com/svg/361073/circle-large-outline https://www.svgrepo.com/svg/361403/whitespace https://www.svgrepo.com/svg/361405/word-wrap
Contributor
Author
Contributor
Author
|
License update: I found the proper reference repo for the icons: License: While the license for the code in the repo is MIT, the icons are under The license is Creative Commons Attribution 4.0 International. Not great. Not terrible, I guess. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Overview
Adds toolbar controls to the right side of the diff file header for common diff display options, with matching entries in Preferences -> Code.
Toolbar
Preferences
New settings under Code:
(Note: Word wrap was already in Preferences, no change to this)
Comparison method
Controls how
git diffis run when loading a patch for the diff view. Options map to Git’s built-in flags:--ignore-cr-at-eol--ignore-cr-at-eol,--ignore-space-change--ignore-cr-at-eol,--ignore-all-spaceNote: Comparison method affects how patches are displayed on-screen only. This does not affect exporting patches, reverting files, etc. This still uses the precise methods.
Changing the comparison method reloads the current patch (re-runs
git diff). Word wrap and formatting marks apply immediately without reloading.Icons
Notes about icons I have used:
All icons are MIT Licensed according to these pages:Update: See comments below.
https://www.svgrepo.com/svg/361077/clear-all
https://www.svgrepo.com/svg/361075/circle-slash
https://www.svgrepo.com/svg/361072/circle-large-filled
https://www.svgrepo.com/svg/361073/circle-large-outline
https://www.svgrepo.com/svg/361403/whitespace
https://www.svgrepo.com/svg/361405/word-wrap