ctrl+shift+p filters: :st2 :st3 :win :osx :linux
Browse

Move By Paragraph

by xsleonard ALL

Navigate and select text by paragraph

Details

Installs

  • Total 2K
  • Win 604
  • Mac 554
  • Linux 363
Nov 21 Nov 20 Nov 19 Nov 18 Nov 17 Nov 16 Nov 15 Nov 14 Nov 13 Nov 12 Nov 11 Nov 10 Nov 9 Nov 8 Nov 7 Nov 6 Nov 5 Nov 4 Nov 3 Nov 2 Nov 1 Oct 31 Oct 30 Oct 29 Oct 28 Oct 27 Oct 26 Oct 25 Oct 24 Oct 23 Oct 22 Oct 21 Oct 20 Oct 19 Oct 18 Oct 17 Oct 16 Oct 15 Oct 14 Oct 13 Oct 12 Oct 11 Oct 10 Oct 9 Oct 8
Windows 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Mac 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 0 0 0 0 0 0 0 0 0 0 4 0 0 0 0 0 0 1 0 0 0
Linux 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0

Readme

Source
raw.​githubusercontent.​com

sublime-MoveByParagraph

A Sublime Text 2 plugin extension to the move command

A new command is added, "move_by_paragraph". These "args" are accepted:

  • "forward" (bool): True if this moves down the page
  • "extend" (bool): True if this should create a selection
  • ignore_blank_lines (bool): Set to true to ignore lines with nothing but whitespace (excluding newline) as text for paragraph boundaries. Defaults to true.
  • stop_at_paragraph_begin (bool): Set to true to stop the cursor at the beginning of paragraphs. Defaults to true
  • stop_at_paragraph_end (bool): Set to true to stop the cursor at the end of paragraphs. Defaults to false. Both stop_at_paragraph_begin and stop_at_paragraph_end can be set at the same time.

Moving by Paragraph

Example (add this to your keymap):

{"keys": ["ctrl+up"], "command": "move_by_paragraph", "args": {"forward": false}},
{"keys": ["ctrl+down"], "command": "move_by_paragraph", "args": {"forward": true}},

Example with selection (add this to your keymap):

{"keys": ["ctrl+shift+up"], "command": "move_by_paragraph", "args": {"forward": false, "extend": true}},
 {"keys": ["ctrl+shift+down"], "command": "move_by_paragraph", "args": {"forward": true, "extend": true}},

Note that "ctrl+shift+up/down" will overwrite the default action of moving the current selection up or down, which is why this is not set by default. Personally, I remapped that behaviour to "ctrl+t" and "ctrl+g".

Suggested Plugins