;;; user variables...
(defgroup strokes nil
- "Control Emacs through mouse strokes"
+ "Control Emacs through mouse strokes."
:link '(emacs-commentary-link "strokes")
:link '(url-link "http://www.mit.edu/people/cadet/strokes-help.html")
:group 'mouse)
(progn
(goto-char point)
(subst-char-in-region point (1+ point)
- ?\ strokes-character))
+ ?\s strokes-character))
;; otherwise, we can start drawing the next time...
(setq safe-to-draw-p t))
(push (cdr (mouse-pixel-position))
;; clean up strokes buffer and then bury it.
(when (equal (buffer-name) strokes-buffer-name)
(subst-char-in-region (point-min) (point-max)
- strokes-character ?\ )
+ strokes-character ?\s)
(goto-char (point-min))
(bury-buffer))))
;; Otherwise, don't use strokes buffer and read stroke silently
(when point
(goto-char point)
(subst-char-in-region point (1+ point)
- ?\ strokes-character))
+ ?\s strokes-character))
(push (cdr (mouse-pixel-position))
pix-locs)))
(setq event (read-event)))
;; protected
(when (equal (buffer-name) strokes-buffer-name)
(subst-char-in-region (point-min) (point-max)
- strokes-character ?\ )
+ strokes-character ?\s)
(goto-char (point-min))
(bury-buffer)))))))
"Erase the contents of the current buffer and fill it with whitespace."
(erase-buffer)
(loop repeat (frame-height) do
- (insert-char ?\ (1- (frame-width)))
+ (insert-char ?\s (1- (frame-width)))
(newline))
(goto-char (point-min)))
(insert strokes-xpm-header)
(loop repeat 33 do
(insert ?\")
- (insert-char ?\ 33)
+ (insert-char ?\s 33)
(insert "\",")
(newline)
finally
;; Otherwise, just plot the point...
(goto-line (+ 17 y))
(forward-char (+ 2 x))
- (subst-char-in-region (point) (1+ (point)) ?\ ?\*)))
+ (subst-char-in-region (point) (1+ (point)) ?\s ?\*)))
((strokes-lift-p point)
;; a lift--tell the loop to X out the next point...
(setq lift-flag t))))
;; (command-name (symbol-name (cdr def))))
;; (strokes-xpm-for-stroke stroke " *strokes-xpm*")
;; (newline 2)
-;; (insert-char ?\ 45)
+;; (insert-char ?\s 45)
;; (beginning-of-line)
;; (insert command-name)
;; (beginning-of-line)
(prin1-to-string (cdr def)))))
(strokes-xpm-for-stroke stroke " *strokes-xpm*")
(newline 2)
- (insert-char ?\ 45)
+ (insert-char ?\s 45)
(beginning-of-line)
(insert command-name)
(beginning-of-line)
(defsubst strokes-xpm-char-bit-p (char)
"Non-nil if CHAR represents an `on' or `off' bit in the XPM."
- (or (eq char ?\ )
+ (or (eq char ?\s)
(eq char ?*)))
;;(defsubst strokes-xor (a b) ### Should I make this an inline function? ###
(insert-char
(if current-char-is-on-p
?*
- ?\ )
+ ?\s)
(strokes-xpm-decode-char (char-after)))
(delete-char 1)
(setq current-char-is-on-p (not current-char-is-on-p)))