Mark Germany -> Ctrl + Shift + o -> "Freut Mich!"
;; germany ;; http://stackoverflow.com/questions/10594208/how-do-i-get-region-selection-programmably-in-emacs-lisp (defun say-region (beg end) "message region or \"empty string\" if none highlighted" (interactive (if (use-region-p) (list (region-beginning) (region-end)) (list (point-min) (point-min)))) (let ((selection (buffer-substring-no-properties beg end))) (if (= (length selection) 0) (message "empty string") (shell-command (concat "say --quality 127 -v Steffi" " \"" selection "\"")) ) ) ) (define-key global-map (kbd "C-S-o") 'say-region)
使ってみるとこんな感じ
どうでもいいけどlebe -> liebe じゃないとカリーウルストと生きる!みたいなカオスになっちゃう。語集増やさねば....