78eebbaefbd880925bb7694fc55192f10c648b88 — Bob Rogers 6 months ago cd9766c
New rgr-fill-sentence command

* rgr-hacks.el:
   + (rgr-fill-sentence):  New hack.
   + (rgr-install-global-editing-hacks):  Bind it to C-c q.
1 files changed, 16 insertions(+), 0 deletions(-)

M rgr-hacks.el
M rgr-hacks.el => rgr-hacks.el +16 -0
@@ 253,6 253,21 @@ backup file has already been made)."

(defun rgr-fill-sentence ()
  "Fill just the current sentence, as by fill-paragraph."
    (let ((start (save-excursion
		   ;; Include everything from bol on the first line so we don't
		   ;; go past the fill column.
	  (end (save-excursion (forward-sentence) (point))))
	(narrow-to-region start end)

(defun rgr-text-mode-hook ()
  ;; turning auto-fill-mode on unconditionally may not be the right thing in

@@ 540,6 555,7 @@ M-x buffer-menu)."
  (global-set-key "\C-cgc" 'goto-char)
  (global-set-key "\C-cgs" 'rgr-view-sequence-at-point)
  (global-set-key "\C-cf" 'rgr-goto-file-in-vc-dir)
  (global-set-key "\C-cq" 'rgr-fill-sentence)
  ;; Bindings compatible with Emacs 22, which already has goto-line on "M-g M-g"
  ;; and "M-g g".
  (cond ((not (rgr-emacs-version-p 22))