all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* How to split the popup "Buffer Menu" by major mode?
@ 2010-10-18 18:22 Lingyu Ma
  2010-10-18 20:17 ` Drew Adams
       [not found] ` <mailman.14.1287433119.15066.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 5+ messages in thread
From: Lingyu Ma @ 2010-10-18 18:22 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 430 bytes --]


When press click the left button with ctrl key pressed (<C-down-mouse-1>), emacs will run the command "mouse-buffer-menu".

If I open a lot of buffers in different modes, the popup menu will generate several submenus as "Buffers 1", "Buffers 2", "Buffers 3" and so on.

Is there a way to make the popup menu split according to buffers' major modes? For example, "C++", "Java", "Org-mode"?

Thanks in advance!
 		 	   		  

[-- Attachment #2: Type: text/html, Size: 647 bytes --]

^ permalink raw reply	[flat|nested] 5+ messages in thread

* How to split the popup "Buffer Menu" by major mode?‏
@ 2010-10-18 18:57 Pony
  2010-10-18 19:31 ` Andreas Politz
  0 siblings, 1 reply; 5+ messages in thread
From: Pony @ 2010-10-18 18:57 UTC (permalink / raw)
  To: help-gnu-emacs

When press click the left button with ctrl key pressed (<C-down-
mouse-1>), emacs will run the command "mouse-buffer-menu".

If I open a lot of buffers in different modes, the popup menu will
generate several submenus as "Buffers 1", "Buffers 2", "Buffers 3" and
so on.

Is there a way to make the popup menu split according to buffers'
major modes? For example, "C++", "Java", "Org-mode"?

Thanks in advance!


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: How to split the popup "Buffer Menu" by major mode?‏
  2010-10-18 18:57 How to split the popup "Buffer Menu" by major mode?‏ Pony
@ 2010-10-18 19:31 ` Andreas Politz
  0 siblings, 0 replies; 5+ messages in thread
From: Andreas Politz @ 2010-10-18 19:31 UTC (permalink / raw)
  To: help-gnu-emacs

Pony <lingyu.ma.fu@googlemail.com> writes:

> Is there a way to make the popup menu split according to buffers'
> major modes? For example, "C++", "Java", "Org-mode"?

(setq mouse-buffer-menu-mode-mult 0)

Try this,

-ap


^ permalink raw reply	[flat|nested] 5+ messages in thread

* RE: How to split the popup "Buffer Menu" by major mode?
  2010-10-18 18:22 How to split the popup "Buffer Menu" by major mode? Lingyu Ma
@ 2010-10-18 20:17 ` Drew Adams
       [not found] ` <mailman.14.1287433119.15066.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 5+ messages in thread
From: Drew Adams @ 2010-10-18 20:17 UTC (permalink / raw)
  To: 'Lingyu Ma', help-gnu-emacs

> When press click the left button with ctrl key pressed
> (<C-down-mouse-1>), emacs will run the command "mouse-buffer-menu".
>
> If I open a lot of buffers in different modes, the popup menu will
> generate several submenus as "Buffers 1", "Buffers 2", "Buffers 3"
> and so on.
> Is there a way to make the popup menu split according to buffers'
> major modes? For example, "C++", "Java", "Org-mode"?

No doubt someone else will be able to help you more, but take a look at option
`mouse-buffer-menu-mode-mult' (whose doc string is not very good, IMHO).
Setting it to 1 or 0 should apparently do what you want.

FWIW - `mouse-buffer-menu' also uses variable `mouse-buffer-menu-mode-groups'.
According to the (nearly incomprehensible) doc string for
`mouse-buffer-menu-mode-mult' you should not need to modify
`mouse-buffer-menu-mode-groups'.  But you might try doing so anyway just to see
what happens. ;-)  Apparently things are meant to be magic, which is too often
just another word for user-unfriendly. ;-)






^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: How to split the popup "Buffer Menu" by major mode?
       [not found] ` <mailman.14.1287433119.15066.help-gnu-emacs@gnu.org>
@ 2010-10-18 21:42   ` Pony
  0 siblings, 0 replies; 5+ messages in thread
From: Pony @ 2010-10-18 21:42 UTC (permalink / raw)
  To: help-gnu-emacs

On Oct 18, 10:17 pm, "Drew Adams" <drew.ad...@oracle.com> wrote:
> > When press click the left button with ctrl key pressed
> > (<C-down-mouse-1>), emacs will run the command "mouse-buffer-menu".
>
> > If I open a lot of buffers in different modes, the popup menu will
> > generate several submenus as "Buffers 1", "Buffers 2", "Buffers 3"
> > and so on.
> > Is there a way to make the popup menu split according to buffers'
> > major modes? For example, "C++", "Java", "Org-mode"?
>
> No doubt someone else will be able to help you more, but take a look at option
> `mouse-buffer-menu-mode-mult' (whose doc string is not very good, IMHO).
> Setting it to 1 or 0 should apparently do what you want.
>
> FWIW - `mouse-buffer-menu' also uses variable `mouse-buffer-menu-mode-groups'.
> According to the (nearly incomprehensible) doc string for
> `mouse-buffer-menu-mode-mult' you should not need to modify
> `mouse-buffer-menu-mode-groups'.  But you might try doing so anyway just to see
> what happens. ;-)  Apparently things are meant to be magic, which is too often
> just another word for user-unfriendly. ;-)



Hi Drew,

I add (setq mouse-buffer-menu-mode-mult 1) into .emacs, and it works
perfectly.
(setq mouse-buffer-menu-mode-mult 0) works also.
The default value is 4.

Thanks!

regards,
Lingyu


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2010-10-18 21:42 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-18 18:57 How to split the popup "Buffer Menu" by major mode?‏ Pony
2010-10-18 19:31 ` Andreas Politz
  -- strict thread matches above, loose matches on Subject: below --
2010-10-18 18:22 How to split the popup "Buffer Menu" by major mode? Lingyu Ma
2010-10-18 20:17 ` Drew Adams
     [not found] ` <mailman.14.1287433119.15066.help-gnu-emacs@gnu.org>
2010-10-18 21:42   ` Pony

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.