parinfer / parinfer.js

Let's simplify the way we write Lisp
https://shaunlebron.github.io/parinfer
MIT License
1.76k stars 40 forks source link

Smart Mode - add selection option to allow users to correct indentation of selected text in isolation #167

Closed shaunlebron closed 7 years ago

shaunlebron commented 7 years ago

replace selectionStartLine with selection so we can use the extra information to allow correcting indentation of selected text (i.e. after pasting) to work without shifting subsequent lines inadvertently (i.e. by running non-smart Indent Mode when text is selected).

This gives the user a set of tools for when to maintain relative indentation of subsequent lines (when cursor is doing the changing), vs when to adjust indentation while ignoring other lines (when changes are made while text is selected).

shaunlebron commented 7 years ago

actually selectionStartLine is fine since we don't need full selection data.