Skip to content

Commit

Permalink
Prefixed the semantic linefeed settings with WrapPlus.semantic_
Browse files Browse the repository at this point in the history
(cherry picked from commit 7b1c0cc)
  • Loading branch information
evandrocoan committed Nov 9, 2017
1 parent b5886f6 commit 7e7fa1f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions Base File.sublime-settings
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
// will wrap near its end,
//
// This is valid only when the `WrapPlus.semantic_line_wrap` above is enabled.
"WrapPlus.balance_characters_between_line_wraps": true,
"WrapPlus.semantic_balance_characters_between_line_wraps": true,

// The minimum of the percentage of the current maximum line width a line can
// have. For example, if you `wrap_width` is set to 100, and you set this to `0.2`,
Expand All @@ -34,13 +34,13 @@
// to disable the minimum width and always wrap the lines despite their size.
//
// This is valid only when the `WrapPlus.semantic_line_wrap` above is enabled.
"WrapPlus.minimum_line_size_percent": 0.0,
"WrapPlus.semantic_minimum_line_size_percent": 0.0,

// When wrapping lines, it will consider they to be a list of words if between
// two sequential commas is find at the maximum these number of words.
//
// This is valid only when the `WrapPlus.semantic_line_wrap` above is enabled.
"WrapPlus.maximum_words_in_comma_separated_list": 3,
"WrapPlus.semantic_maximum_words_in_comma_separated_list": 3,

// The `semantic_line_wrap` detects the maximum line width and uses it to
// limite/delimite the maximum line width. If you like your lines only to be
Expand All @@ -49,7 +49,7 @@
// * This is valid only when the `WrapPlus.semantic_line_wrap` above is enabled.
// * If the setting `WrapPlus.balance_characters_between_line_wraps` is enabled,
// this setting will be ignored.
"WrapPlus.disable_line_wrapping_by_maximum_width": false,
"WrapPlus.semantic_disable_line_wrapping_by_maximum_width": false,

// Determines whether or not line endings are included in the line size:
// - true: Always included.
Expand Down
8 changes: 4 additions & 4 deletions wrap_plus.py
Original file line number Diff line number Diff line change
Expand Up @@ -661,10 +661,10 @@ def run(self, edit, width=0):
break_long_words = view_settings.get('WrapPlus.break_long_words', True)
break_on_hyphens = view_settings.get('WrapPlus.break_on_hyphens', True)

minimum_line_size_percent = view_settings.get('WrapPlus.minimum_line_size_percent', 0.2)
balance_characters_between_line_wraps = view_settings.get('WrapPlus.balance_characters_between_line_wraps', False)
disable_line_wrapping_by_maximum_width = view_settings.get('WrapPlus.disable_line_wrapping_by_maximum_width', False)
maximum_words_in_comma_separated_list = view_settings.get('WrapPlus.maximum_words_in_comma_separated_list', 3) + 1
minimum_line_size_percent = view_settings.get('WrapPlus.semantic_minimum_line_size_percent', 0.2)
balance_characters_between_line_wraps = view_settings.get('WrapPlus.semantic_balance_characters_between_line_wraps', False)
disable_line_wrapping_by_maximum_width = view_settings.get('WrapPlus.semantic_disable_line_wrapping_by_maximum_width', False)
maximum_words_in_comma_separated_list = view_settings.get('WrapPlus.semantic_maximum_words_in_comma_separated_list', 3) + 1

wrapper = textwrap.TextWrapper(break_long_words=break_long_words,
break_on_hyphens=break_on_hyphens)
Expand Down

0 comments on commit 7e7fa1f

Please sign in to comment.