[Top][All Lists]

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

Re: Changing buffer mode

From: Eduardo Ochs
Subject: Re: Changing buffer mode
Date: Thu, 21 Jul 2022 15:41:13 -0300

On Thu, 21 Jul 2022 at 12:56, carlmarcos--- via Users list for the GNU
Emacs text editor <> wrote:
> Have started with the following but with few ideas of how to supply 
> appropriate value to buffer.
> (defun mode-sweep (mode)
>   "Cycle the buffer through three major modes (text, org, normal)."
>   (interactive
>    (list
>     (let ( (cseq '("org-mode" "text-mode" "normal-mode")) )
>       (completing-read "Major-mode: " cseq nil t "normal-mode"))))
>   (with-current-buffer buffer
>    (funcall (intern mode))) )

Is cseq an existing function? Where can I find it?
I have my own function to cycle between major modes, but it is ugly,
and I would like to rewrite it using something like cseq...
  [[]], Edrx

reply via email to

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