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 1K
  • Win 587
  • Mac 545
  • Linux 359
Apr 26 Apr 25 Apr 24 Apr 23 Apr 22 Apr 21 Apr 20 Apr 19 Apr 18 Apr 17 Apr 16 Apr 15 Apr 14 Apr 13 Apr 12 Apr 11 Apr 10 Apr 9 Apr 8 Apr 7 Apr 6 Apr 5 Apr 4 Apr 3 Apr 2 Apr 1 Mar 31 Mar 30 Mar 29 Mar 28 Mar 27 Mar 26 Mar 25 Mar 24 Mar 23 Mar 22 Mar 21 Mar 20 Mar 19 Mar 18 Mar 17 Mar 16 Mar 15 Mar 14 Mar 13
Windows 0 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 1 1 0 0 0 1 0 0 0 0 0 0 0 0 0
Mac 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 2 3 0 0 1 0 0 0 0 0 0 0 1 0 0 0 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 0 0 1 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