emms-help
[Top][All Lists]
Advanced

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

Re: How to move point in emms playlist?


From: Yuchen Pei
Subject: Re: How to move point in emms playlist?
Date: Wed, 12 Jul 2023 16:00:06 +1000
User-agent: K-9 Mail for Android

Does the command emms-playlist-mode-center-current (bound to the c key by 
default) that teleports point to the currently playing track help?

On 12 July 2023 02:36:56 GMT+10:00, Tom via <emms-help@gnu.org> wrote:
>Hello,
>
>I am always a little irritated that the currently playing track is not at 
>point (I'm using hl-line-mode), so there are 2 highlighted lines, point and 
>current track. I wanted to fix that with:
>
>  (defun tvd-emms-follow-playing-song()
>    (interactive)
>    (save-restriction
>      (when emms-playlist-selected-marker
>        (goto-char emms-playlist-selected-marker))))
>
>  (add-hook 'emms-playlist-selection-changed-hook 
> 'tvd-emms-follow-playing-song 1)
>
>However, this doesn't work, point is not moved when a new song starts to play.
>
>When I execute the function manually, it works (I added a couple of print 
>statements to the function, which are being executed every time the song 
>changes). So, it's actually being executed by the hook, but the goto-char part 
>doesn't have any effect.
>
>Does anyone have an idea what might be wrong here?
>
>
>Many thanks in advance,
>Tom



reply via email to

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