diff options
author | Arnaud Fontaine <arnau@debian.org> | 2012-05-24 09:59:56 +0900 |
---|---|---|
committer | Arnaud Fontaine <arnau@debian.org> | 2012-12-19 19:39:09 +0900 |
commit | 5b0d66139a740ebe42e45eadc908daed3e2f7736 (patch) | |
tree | 823329cf806a9ed32430e4c679181dcba74cfefa /lisp/emms-compat.el | |
parent | 8b313708a9bce6611ba0b5e74e6c08b1dead3842 (diff) |
Support both XEmacs and Emacs to highlight playing lyrics.
* lisp/emms-compat.el: support highlighting for both XEmacs (highlight) and
Emacs (hl-line).
* lisp/emms-lyrics.el: use compatibility functions defined in emms-compat.el.
Diffstat (limited to 'lisp/emms-compat.el')
-rw-r--r-- | lisp/emms-compat.el | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/lisp/emms-compat.el b/lisp/emms-compat.el index f5ede0b..ba233ea 100644 --- a/lisp/emms-compat.el +++ b/lisp/emms-compat.el @@ -67,6 +67,26 @@ EMMS release version number." (< (nth 1 t1) (nth 1 t2))))) +;;; Highline + +(defun emms-activate-highlighting-mode () + "Activate highline mode." + (if (featurep 'xemacs) + (progn + (require 'highline) + (highline-local-mode 1)) + (progn + (require 'hl-line) + (hl-line-mode 1)))) + +(defun emms-line-highlight () + "Highlight the current line. You must call +emms-activate-highlighting-mode beforehand." + (if (featurep 'xemacs) + (highline-highlight-current-line) + (hl-line-highlight))) + + ;;; Movement and position (defun emms-move-beginning-of-line (arg) |