Emacs Advent Calendar 13: Mouse Commands
Although all Emacs functionality can be accessed using only the keyboard, the graphical version also features mouse commands.
First a note on terminology: as usual,
Mouse-1 denotes the
left mouse button,
Mouse-2 is the middle mouse button and
Mouse-3 the right mouse button.
Although obvious, let's mention for consistency's sake that a click of
Mouse-1 on the buffer moves point to the position of the
Drag-Mouse-1 activates and sets the region around
the text selected by dragging and puts it into primary selection so it
can be pasted by clicking
Mouse-2 in Emacs or other X applications.
A concept usually not found outside emacs is the ability to change the
boundaries of an active region with a click of
Mouse-3: it moves the
nearer end of the region to the position clicked. If no region is
active, it activates a region spanning from point to the click
position. A second click of
Mouse-3 in the same position kills the
To select one word, use
Double-Mouse-1. To select text by
whole words, use
click selects the line, similarly
text by lines.
Combinations of mouse clicks and modifier buttons bring up
C-Mouse-1 pops up a menu for buffer
C-Mouse-3 opens a mode-specific menu, usually with
the contents of all the mode-specific menu-bar menus.
S-Mouse-1 contains functions to change the buffer font or the
size of it.
Clicking on the mode line has different effects.
selects the mode-line's window, dragging changes its
Mouse-2 makes the window fill the whole frame (like
Mouse-3 deletes the window (like
0). Other entries of the mode-line show available mouse click
commands in a tooltip when hovering the pointer over them.
C-Mouse-2 on the mode line splits a window
into two windows side by side. Depending on Emacs' compilation
C-Mouse-2 on the scroll bar creates a
More information on this can be found in sections 21.1 (Mouse Commands for Editing), 21.2 (Mouse Commands for Words and Lines), 21.4 (Mouse Clicks for Menus), 21.5 (Mode Line Mouse Commands) and 20.2 (Splitting Windows).Tags: emacs
This text by Ludger Sandig is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License.