emms-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[emms-help] Re: toolbar for emms?


From: joakim
Subject: [emms-help] Re: toolbar for emms?
Date: Thu, 30 Oct 2008 21:03:33 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

Yoni Rabkin <address@hidden> writes:

> address@hidden writes:
>
>> I would like to use emms as a mediaplayer on the openmoko freerunner
>> mobile phone. Since it has only touchscreen, a toolbar would be
>> useful.
>
>> Is there a toolbar for emms? 
>
> (disclaimer: I don't have an openmoko, and hide the toolbars in Emacs)
>
> I grepped the Emms code for toolbar-ish code and found nothing.
>
>> If not, any ideas how I could implement one?
>
> Section 22.17.6 of the Emacs Lisp manual has a lot of information about
> toolbars. lisp/tool-bar.el in the Emacs source code might have useful,
> if somewhat more nitty gritty details.
>
> Please drop a line here if you decide to implement it, so we know
> someone is working on it. 
>
> It sounds like a great idea.

I tried something like the code below in an ielm session:

(setq emms-playlist-tool-bar-map
  (let ((map (make-sparse-keymap)))
    (tool-bar-local-item "prev-node" 'emms-previous 'emms-previous map
  emms-playlist-mode-map :rtl "next-node" :help "go to previous track")
    (tool-bar-local-item "next-node" 'emms-next  'emms-next map
  emms-playlist-mode-map :rtl "prev-node" :help "go to next track")
    map))

(defvar tool-bar-map)
(set (make-local-variable 'tool-bar-map) emms-playlist-tool-bar-map)

This does in fact work! The code was ripped from compile.el and info.el.

I'll see if I can come up with a patch suitable for inclusion. I do have
papers with the FSF.

-- 
Joakim Verona





reply via email to

[Prev in Thread] Current Thread [Next in Thread]