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

Lines Matching +defs:last +defs:coord

603 		 artist-pen-reset-last-xy nil nil
882 the last point is set, but before the filling is done.
1102 (defun artist-get-last-non-nil-op (op-list &optional last-non-nil)
1103 "Find the last non-nil draw operation in OP-LIST.
1106 (artist-get-last-non-nil-op (cdr op-list)
1107 (or (car (car op-list)) last-non-nil))
1108 last-non-nil))
1122 last-non-nil-arg first-non-nil-arg
1127 (let* ((last-non-nil (or last-non-nil-arg
1128 (artist-get-last-non-nil-op
1133 (prev-op (or prev-op-arg last-non-nil))
1140 last-non-nil first-non-nil
1146 last-non-nil first-non-nil
1199 Pen fill-char at point line from last point
1282 For poly-lines: sets a point (use C-u \\[artist-key-set-point] to set last point)
1284 When cutting/copying: Sets first/last endpoint of rect/square
1914 ;; of the buffer, and that last line happened to be longer than
1915 ;; the current column, then we end up at the end of that last
1919 ;; Example: In the figure below, the `X' is the very last
1984 (setq last-command-event (aref artist-replacement-table new-char))
2006 (setq last-command-event (aref artist-replacement-table new-char))
2322 (defsubst artist-new-coord (x y &optional new-char)
2325 in the coord."
2326 (let ((coord (make-vector 4 x)))
2327 (aset coord 1 y)
2328 (aset coord 3 new-char)
2329 coord))
2331 (defsubst artist-coord-get-x (coord)
2333 (aref coord 0))
2335 (defsubst artist-coord-get-y (coord)
2337 (aref coord 1))
2339 (defsubst artist-coord-set-x (coord new-x)
2341 (aset coord 0 new-x)
2342 coord)
2344 (defsubst artist-coord-set-y (coord new-y)
2346 (aset coord 1 new-y)
2347 coord)
2349 (defsubst artist-coord-get-saved-char (coord)
2351 (aref coord 2))
2353 (defsubst artist-coord-get-new-char (coord)
2355 (aref coord 3))
2357 (defsubst artist-coord-add-saved-char (coord saved-char)
2359 (aset coord 2 saved-char)
2360 coord)
2362 (defsubst artist-coord-add-new-char (coord new-char)
2364 (aset coord 3 new-char)
2365 coord)
2367 (defsubst artist-coord-set-new-char (coord new-char)
2369 (aset coord 3 new-char)
2370 coord)
2376 "In POINT-LIST, store a ``pixel'' at coord X,Y."
2378 (list 'append point-list (list 'list (list 'artist-new-coord x y)))))
2423 (lambda (coord)
2424 (artist-coord-add-saved-char
2425 coord
2426 (artist-get-char-at-xy (artist-coord-get-x coord)
2427 (artist-coord-get-y coord))))
2433 ;; Depending on new-coord's position relative to last-coord one of the
2443 (defun artist-calculate-new-char (last-coord new-coord)
2445 (let ((last-x (artist-coord-get-x last-coord))
2446 (last-y (artist-coord-get-y last-coord))
2447 (new-x (artist-coord-get-x new-coord))
2448 (new-y (artist-coord-get-y new-coord)))
2449 (cond ((> new-x last-x) (cond ((< new-y last-y) ?/ )
2450 ((> new-y last-y) ?\\ )
2452 ((< new-x last-x) (cond ((< new-y last-y) ?\\ )
2453 ((> new-y last-y) ?/ )
2455 ((eq new-y last-y) ?o)
2461 (list (artist-coord-add-new-char (car point-list) ?o ))
2462 (let ((last-coord (car point-list)))
2463 (cons (artist-coord-add-new-char
2468 (lambda (this-coord)
2470 (artist-coord-add-new-char
2471 this-coord
2472 (artist-calculate-new-char last-coord this-coord))
2473 (setq last-coord this-coord)))
2485 (lambda (coord)
2486 (let* ((new-c (artist-coord-get-new-char coord))
2487 (saved-c (artist-coord-get-saved-char coord))
2489 (artist-coord-set-new-char coord modified-c)))
2546 (lambda (coord)
2547 (artist-move-to-xy (artist-coord-get-x coord)
2548 (artist-coord-get-y coord))
2551 (artist-replace-char (artist-coord-get-new-char coord)))
2552 coord)
2561 (lambda (coord)
2562 (artist-move-to-xy (artist-coord-get-x coord)
2563 (artist-coord-get-y coord))
2564 (artist-replace-char (artist-coord-get-saved-char coord))
2565 coord)
2601 ;; This is the last element. Set the second endpoint
2775 "Draws a line from last pen position to X1, Y1.
2786 ;; Draw line from last point to this
2787 (let ((x-last (car (car artist-key-poly-point-list)))
2788 (y-last (cdr (car artist-key-poly-point-list))))
2789 (artist-move-to-xy x-last y-last)
2791 (artist-draw-line x-last y-last x1 y1))
2797 (defun artist-pen-reset-last-xy (x1 y1)
2798 "Reset the last x and y points to X1, Y1 when doing pen-drawing."
3025 (x-last x1)
3026 (y-last y1)
3036 (setq x-last x
3037 y-last y
3071 (cons x-last y-last)))
3311 (artist-coord-set-x p (+ x-center (artist-coord-get-x p)))
3312 (artist-coord-set-y p (+ y-center (artist-coord-get-y p))))
3340 (last-y nil))
3345 (lambda (coord)
3346 (let* ((x (artist-coord-get-x coord))
3347 (y (artist-coord-get-y coord))
3350 (if (or (null last-y) (not (= y last-y)))
3357 (setq last-y y)))
3379 ;; First, if last char in that quadrant is `/', then replace it with `)'
3386 (let ((last-coord (car (last point-list))))
3387 (if (= (artist-coord-get-new-char last-coord) ?/)
3388 (artist-coord-set-new-char last-coord artist-ellipse-right-char)))
3395 (lambda (coord)
3396 (let ((c (artist-coord-get-new-char coord)))
3397 (artist-new-coord (artist-coord-get-x coord)
3398 (- (artist-coord-get-y coord))
3408 (lambda (coord)
3409 (let ((c (artist-coord-get-new-char coord)))
3410 (artist-new-coord (- (artist-coord-get-x coord))
3411 (artist-coord-get-y coord)
3447 (lambda (coord)
3448 (artist-move-to-xy (artist-coord-get-x coord)
3449 (artist-coord-get-y coord))
3452 (artist-replace-char (artist-coord-get-new-char coord)))
3453 coord)
3486 (new-coord (artist-new-coord line-x line-y)))
3487 (artist-coord-add-saved-char new-coord
3491 (setq point-list (append point-list (list new-coord)))
3539 (lambda (coord)
3540 (artist-move-to-xy (artist-coord-get-x coord)
3541 (artist-coord-get-y coord))
3542 (artist-replace-char (artist-coord-get-saved-char coord))
3543 coord)
3696 (last-x x))
3700 (setq last-x x)
3702 last-x)))
3713 (let ((last-line (artist-current-line)))
3717 ;; as last line
3718 (>= y (- last-line 1))
3719 (>= y last-line)))))
3735 (push (artist-new-coord x1 y1) stack))
3738 (let* ((coord (pop stack))
3739 (x (artist-coord-get-x coord))
3740 (y (artist-coord-get-y coord))
3746 (last-x 0)
3749 ;; Lines below the last one, and prior to the first-one
3756 (last-c-above -1)
3757 (last-c-below -1))
3762 (setq last-x x-rightmost)
3769 (if (and (= c-above c) (/= c-above last-c-above))
3770 (push (artist-new-coord x (- y 1)) stack))
3771 (setq last-c-above c-above)))
3772 (setq last-x x)
3776 (setq x-leftmost last-x)
3783 (if (and (= c-below c) (/= c-below last-c-below))
3784 (push (artist-new-coord x (1+ y)) stack))
3785 (setq last-c-below c-below)))
3855 (epn (car (last point-list)))
3856 (epn-1 (car (last point-list 2)))
4131 (defun artist-key-set-point-poly (x y &optional this-is-last-point)
4133 If optional argument THIS-IS-LAST-POINT is non-nil, this point is the last."
4172 "set last with C-u \\[artist-key-set-point]"))))
4176 ;; (last point if the argument this-is-last-point is non-nil)
4206 ;; Now do handle the case when this is the last point,
4207 ;; and the case when this point isn't the last
4209 (if (not this-is-last-point)
4210 ;; ** This is not the last point
4212 ;; Start drawing a new 2-point-shape from last endpoint.
4228 ;; ** This is the last point
4341 With non-nil ARG, set the last point."
4432 "Set a point for the current shape. With optional ARG, set the last point."
4851 (select-window (posn-window (event-start last-input-event)))
4852 (list last-input-event
4853 (x-popup-menu last-nonmenu-event artist-popup-menu-table))))
4887 "From the last SHIFT-STATE and EV, determine if the shift-state has changed."
4901 (defun artist-coord-win-to-buf (coord)
4903 (let ((window-x (car coord))
4904 (window-y (cdr coord))
4931 (ev-start-pos (artist-coord-win-to-buf (posn-col-row ev-start)))
4943 (setq ev-start-pos (artist-coord-win-to-buf
5005 (message "Mouse-1: set new point, mouse-2: set last point")
5022 (ev-start-pos (artist-coord-win-to-buf (posn-col-row ev-start)))
5023 (x1-last (car ev-start-pos))
5024 (y1-last (cdr ev-start-pos))
5025 (x2 x1-last)
5026 (y2 y1-last)
5032 (artist-funcall init-fn x1-last y1-last)
5034 (artist-no-rb-set-point1 x1-last y1-last))
5049 (setq shape (artist-funcall draw-fn x1-last y1-last x2 y2))))
5057 (setq x1-last (artist-endpoint-get-x endpoint2))
5058 (setq y1-last (artist-endpoint-get-y endpoint2))))
5059 (setq point-list (cons (artist-make-endpoint x1-last y1-last)
5109 ;; Draw shape from last place to this place
5113 (setq ev-start-pos (artist-coord-win-to-buf
5121 (setq shape (artist-funcall draw-fn x1-last y1-last x2 y2))
5123 (artist-no-rb-set-point1 x1-last y1-last)
5137 ;; Draw shape from last place to this place
5140 (setq ev-start-pos (artist-coord-win-to-buf
5145 ;; First undraw last shape
5146 ;; (unset last point if not rubberbanding)
5153 (setq shape (artist-funcall draw-fn x1-last y1-last x2 y2))
5192 ;; Reverse point-list (last points are cond'ed first)
5226 (ev-start-pos (artist-coord-win-to-buf (posn-col-row ev-start)))
5260 (ev-start-pos (artist-coord-win-to-buf (posn-col-row ev-start)))
5273 (setq ev-start-pos (artist-coord-win-to-buf
5284 ;; First undraw last shape (unset last point if not rubberbanding)
5517 ;; the function `artist-coord-win-to-buf'.