iankelling.org
/
git
/
spray
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
update screencast
[spray]
/
spray.el
diff --git
a/spray.el
b/spray.el
index 7d42d01a39dcd0011e50af869c095503f5b8a1a8..10b44416706aade28d08720c460e9b1ec47a3e58 100644
(file)
--- a/
spray.el
+++ b/
spray.el
@@
-1,7
+1,12
@@
;; custom
;; custom
-(defvar spray-
freq (/ 60.0 400) "60.0 / WPM
")
+(defvar spray-
wpm 400 "words/min
")
(defvar spray-text-scale 5)
(defvar spray-text-scale 5)
-(defvar spray-orp-face 'error)
+
+(make-face 'spray-orp-face)
+(set-face-attribute 'spray-orp-face nil
+ :foreground "red"
+ :underline (face-foreground 'default)
+ :overline (face-foreground 'default))
;; internal variables for spraying
(defvar spray--padding-overlay nil)
;; internal variables for spraying
(defvar spray--padding-overlay nil)
@@
-22,11
+27,11
@@
(cond (spray-mode
(setq spray--orp-overlay (make-overlay 0 0)
spray--padding-overlay (make-overlay 0 0)
(cond (spray-mode
(setq spray--orp-overlay (make-overlay 0 0)
spray--padding-overlay (make-overlay 0 0)
- spray--timer (run-with-timer 0
spray-freq
'spray-next)
+ spray--timer (run-with-timer 0
(/ 60.0 spray-wpm)
'spray-next)
spray--saved-cursor-type cursor-type)
(setq cursor-type nil)
(text-scale-set spray-text-scale)
spray--saved-cursor-type cursor-type)
(setq cursor-type nil)
(text-scale-set spray-text-scale)
- (overlay-put spray--orp-overlay 'face spray-orp-face)
+ (overlay-put spray--orp-overlay 'face
'
spray-orp-face)
(add-hook 'pre-command-hook 'turn-off-spray-mode)
;; disable incompatible minor-modes
(when (boundp 'global-hl-line-mode)
(add-hook 'pre-command-hook 'turn-off-spray-mode)
;; disable incompatible minor-modes
(when (boundp 'global-hl-line-mode)