• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.10/emacs-93/emacs/lisp/emulation/

Lines Matching +defs:match +defs:beginning

240 ;;    strings, like beginning-of-line (^) and end-of-line ($).  When searching
245 ;; replace "^" "> " <add "> " to beginning of line>
251 ;; beginning or end of lines. They might work on a line-by-line basis, but
253 ;; goal is to add a string to the beginning or end of a particular set of
322 (string-match "Lucid" emacs-version)
353 (define-key map "24~" 'tpu-next-beginning-of-line) ; F12 (BS)
368 (define-key map "A" 'tpu-move-to-beginning) ; up-arrow
371 (define-key map "D" 'beginning-of-line) ; left-arrow
405 (define-key map "A" 'tpu-move-to-beginning) ; up-arrow
408 (define-key map "D" 'beginning-of-line) ; left-arrow
419 (define-key map "u" 'tpu-move-to-beginning) ; KP5
716 (defvar tpu-match-beginning-mark (make-marker))
717 (defvar tpu-match-end-mark (make-marker))
719 (defun tpu-set-match nil
720 "Set markers at match beginning and end."
721 ;; Add one to beginning mark so it stays with the first character of
723 (setq tpu-match-beginning-mark (copy-marker (match-beginning 0) t))
724 (setq tpu-match-end-mark (copy-marker (match-end 0))))
726 (defun tpu-unset-match nil
727 "Unset match beginning and end markers."
728 (set-marker tpu-match-beginning-mark nil)
729 (set-marker tpu-match-end-mark nil))
731 (defun tpu-match-beginning nil
732 "Returns the location of the last match beginning."
733 (marker-position tpu-match-beginning-mark))
735 (defun tpu-match-end nil
736 "Returns the location of the last match end."
737 (marker-position tpu-match-end-mark))
739 (defun tpu-check-match nil
740 "Returns t if point is between tpu-match markers.
741 Otherwise sets the tpu-match markers to nil and returns nil."
743 ;; 2- point is at or after beginning marker
746 ;; beginning, end, and point are equal.
748 (equal (marker-buffer tpu-match-beginning-mark) (current-buffer))
749 (>= (point) (marker-position tpu-match-beginning-mark))
751 (< (point) (marker-position tpu-match-end-mark))
752 (and (= (marker-position tpu-match-beginning-mark)
753 (marker-position tpu-match-end-mark))
754 (= (marker-position tpu-match-end-mark) (point))))) t)
756 (tpu-unset-match) nil)))
758 (defun tpu-show-match-markers nil
759 "Show the values of the match markers."
761 (if (markerp tpu-match-beginning-mark)
763 (marker-position tpu-match-beginning-mark)
764 (marker-position tpu-match-end-mark)
765 (marker-buffer tpu-match-end-mark)
866 (let ((beg (region-beginning)) (end (region-end)))
873 ((tpu-check-match)
874 (let ((beg (tpu-match-beginning)) (end (tpu-match-end)))
880 (tpu-unset-match)))
1115 ^H beginning of line
1122 ^U delete to beginning of line
1199 (tpu-move-to-beginning)
1322 "Returns names from BUFFER-LIST excluding those beginning with a space or star."
1359 (if (tpu-check-match)
1361 (tpu-match-beginning) (tpu-match-end) (current-buffer))
1431 (tpu-unset-match)
1438 (tpu-set-match) (goto-char (tpu-match-beginning)))
1447 (setq pos (match-beginning 0))))
1454 (goto-char pos) (tpu-set-match)
1470 (while (setq pos (string-match "\\\\\\\\" pat)) (aset pat (+ 1 pos) ?.))
1471 (while (setq pos (string-match "\\\\B" pat)) (aset pat (+ 1 pos) ?.))
1472 (while (setq pos (string-match "\\\\W" pat)) (aset pat (+ 1 pos) ?.))
1473 (while (setq pos (string-match "\\\\S." pat))
1582 ((tpu-check-match)
1583 (let ((beg (tpu-match-beginning)) (end (tpu-match-end)))
1586 (tpu-unset-match)))
1605 ((tpu-check-match)
1607 (buffer-substring (tpu-match-beginning) (tpu-match-end)))
1608 (tpu-unset-match))
1623 (let ((beg (region-beginning)) (end (region-end)))
1629 ((tpu-check-match)
1630 (let ((beg (tpu-match-beginning)) (end (tpu-match-end)))
1635 (tpu-unset-match)))
1665 "Delete text back to beginning of line.
1670 (tpu-next-beginning-of-line num)
1765 (let ((beg (region-beginning)) (end (region-end)))
1770 ((tpu-check-match)
1771 (let ((beg (tpu-match-beginning)) (end (tpu-match-end)))
1773 (replace-match tpu-last-deleted-region
1775 (tpu-unset-match)))
1784 (cond ((or (tpu-mark) (tpu-check-match))
1785 (while (and (not (= num 0)) (or (tpu-mark) (tpu-check-match)))
1811 (if (not (tpu-check-match)) (setq doit nil)
1814 (tpu-match-beginning) (tpu-match-end) (current-buffer))
1820 (replace-match to (not case-replace) (not tpu-regexp-p))
1831 (replace-match to (not case-replace) (not tpu-regexp-p))
1835 (while (tpu-check-match)
1837 (replace-match to (not case-replace) (not tpu-regexp-p))
1845 (replace-match to (not case-replace) (not tpu-regexp-p))
1851 (tpu-unset-match)
1872 "Add text to the beginning of each line in a region,
1881 (if (< (point) (tpu-mark)) (replace-match text))))
1887 (replace-match text))))))
1912 (save-match-data
1916 (delete-region (match-beginning 0) (match-end 0))))))
1949 "Move to the beginning of the next word in the current direction.
1955 "Move forward until encountering the beginning of a word.
1972 "Move backward until encountering the beginning of a word.
1977 (end (prog2 (beginning-of-line) (point) (goto-char beg))))
2039 (defun tpu-next-beginning-of-line (num)
2040 "Move to beginning of line; if at beginning, move to beginning of next line.
2073 "Move to the beginning of the next line in the current direction.
2079 "Move to beginning of next line.
2085 "Move to beginning of previous line.
2103 "Move to beginning of the next paragraph.
2106 (beginning-of-line)
2110 (goto-char (match-beginning 0))
2113 (beginning-of-line))
2117 "Move to beginning of previous paragraph.
2126 (goto-char (match-beginning 0)))))
2129 (beginning-of-line))
2184 (defun tpu-move-to-beginning nil
2185 "Move cursor to the beginning of buffer, but don't set the mark."
2202 (defun tpu-beginning-of-window nil
2260 (define-key minibuffer-local-must-match-map [kp-enter] 'minibuffer-complete-and-exit)
2280 (define-key map "\C-h" 'tpu-next-beginning-of-line) ; ^H (BS)
2344 ;; (define-key minibuffer-local-must-match-map cur 'tpu-previous-history-element)
2353 ;; (define-key minibuffer-local-must-match-map cur 'tpu-next-history-element)
2400 (if (string-match "/$" (car search-list)) "" "/")