-
-
Notifications
You must be signed in to change notification settings - Fork 69
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add
rewrap.autoWrap.enabled
setting (#87)
Adds a new setting: `rewrap.autoWrap.enabled` (boolean). To keep things simpler for now, it has `application` scope, meaning it can't be used in workspace or workspace folder settings files. For now I've also kept "hidden" internal setting to keep track of on/off state. How it works is like this: 1. If no '...enabled' setting exists in the user's settings file, the internal flag is still used as before. Using the toggle command will alter this flag. 2. If the '...enabled' setting *is* present in the user's setting's file (set either true or false), this takes precedence. If the toggle command is then used, it modifies the setting in the settings file instead. This can be changed in the future without too much impact. 2 ways to go on this: always store the on/off state in the setting; or use the setting just to set the state at startup (or if it's changed): the toggle would just set an extra flag to turn it off temporarily. Another option would be to make the toggle command invisible altogether if the feature is disabled in the settings.
- Loading branch information
Showing
3 changed files
with
52 additions
and
23 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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