Mercurial > hg > xemacs-beta
comparison lisp/paragraphs.el @ 4103:b4f4e0cc90f1
[xemacs-hg @ 2007-08-07 23:08:47 by aidan]
Eliminate byte compiler warnings, give nicer errors in the absence of packages.
author | aidan |
---|---|
date | Tue, 07 Aug 2007 23:09:22 +0000 |
parents | 1b8351656013 |
children | 7d06a8bf47d2 f62141fe007d |
comparison
equal
deleted
inserted
replaced
4102:9856d458deda | 4103:b4f4e0cc90f1 |
---|---|
238 ;; Go to end of the previous (non-separating) line. | 238 ;; Go to end of the previous (non-separating) line. |
239 (end-of-line) | 239 (end-of-line) |
240 ;; Search back for line that starts or separates paragraphs. | 240 ;; Search back for line that starts or separates paragraphs. |
241 (if (if fill-prefix-regexp | 241 (if (if fill-prefix-regexp |
242 ;; There is a fill prefix; it overrides parstart. | 242 ;; There is a fill prefix; it overrides parstart. |
243 (let (multiple-lines) | 243 (let nil ; (multiple-lines) |
244 (while (and (progn (beginning-of-line) (not (bobp))) | 244 (while (and (progn (beginning-of-line) (not (bobp))) |
245 (progn (move-to-left-margin) | 245 (progn (move-to-left-margin) |
246 (not (looking-at parsep))) | 246 (not (looking-at parsep))) |
247 (looking-at fill-prefix-regexp)) | 247 (looking-at fill-prefix-regexp)) |
248 (unless (= (point) start) | 248 ; (unless (= (point) start) |
249 (setq multiple-lines t)) | 249 ; (setq multiple-lines t)) |
250 (forward-line -1)) | 250 (forward-line -1)) |
251 (move-to-left-margin) | 251 (move-to-left-margin) |
252 ;; This deleted code caused a long hanging-indent line | 252 ;; This deleted code caused a long hanging-indent line |
253 ;; not to be filled together with the following lines. | 253 ;; not to be filled together with the following lines. |
254 ;; ;; Don't move back over a line before the paragraph | 254 ;; ;; Don't move back over a line before the paragraph |
317 (and use-hard-newlines | 317 (and use-hard-newlines |
318 (not (get-text-property (1- start) 'hard))))) | 318 (not (get-text-property (1- start) 'hard))))) |
319 (forward-char 1)) | 319 (forward-char 1)) |
320 (if (< (point) (point-max)) | 320 (if (< (point) (point-max)) |
321 (goto-char start)))) | 321 (goto-char start)))) |
322 (constrain-to-field nil opoint t) | 322 (if-fboundp #'constrain-to-field |
323 (constrain-to-field nil opoint t) | |
324 (error | |
325 'void-function | |
326 "constrain-to-field not available; is xemacs-base installed?")) | |
323 ;; Return the number of steps that could not be done. | 327 ;; Return the number of steps that could not be done. |
324 arg)) | 328 arg)) |
325 | 329 |
326 (defun backward-paragraph (&optional arg) | 330 (defun backward-paragraph (&optional arg) |
327 "Move backward to start of paragraph. | 331 "Move backward to start of paragraph. |
432 (let ((par-end (save-excursion (end-of-paragraph-text) (point)))) | 436 (let ((par-end (save-excursion (end-of-paragraph-text) (point)))) |
433 (if (re-search-forward sentence-end par-end t) | 437 (if (re-search-forward sentence-end par-end t) |
434 (skip-chars-backward " \t\n") | 438 (skip-chars-backward " \t\n") |
435 (goto-char par-end))) | 439 (goto-char par-end))) |
436 (setq arg (1- arg))) | 440 (setq arg (1- arg))) |
437 (constrain-to-field nil opoint t))) | 441 (if-fboundp #'constrain-to-field |
442 (constrain-to-field nil opoint t) | |
443 (error | |
444 'void-function | |
445 "constrain-to-field not available; is xemacs-base installed?")))) | |
438 | 446 |
439 (defun backward-sentence (&optional arg) | 447 (defun backward-sentence (&optional arg) |
440 "Move backward to start of sentence. With arg, do it arg times. | 448 "Move backward to start of sentence. With arg, do it arg times. |
441 See `forward-sentence' for more information." | 449 See `forward-sentence' for more information." |
442 (interactive "_p") ; XEmacs | 450 (interactive "_p") ; XEmacs |