Introduction

GNU Emacs is more of an “environment” than just an editor, since it has the strong configuration language, emacs-lisp. There are a lot of applications written in emacs-lisp, and you may run many applications on your Emacs at the same time, i.e. e-mail reader, news reader, IRC client, a kind of IDE, etc. These applications likely consist of two or more windows, so when you switch among applications, you may want to save or restore how windows are located (this is called as “window-configuration”). For this purpose, Emacs has two functions, window-configuration-to-register and jump-to-register, but these are too primitive to use on a daily basis.

ElScreen provides the ease-to-use environment to save or restore several window-configurations. For instance, you just have to type C-z C-a to switch following two window-configurations:

Features

Screens are tabbed which makes it easier and faster to switch among applications.

ElScreen menu is also added to menu-bar to create, select or delete screens.

Each frame keeps up to 10 window-configurations.

List of screens can be shown in mini-buffer.

You can assign your own name to each window.

Environments

Following emacs variants are confirmed to run ElScreen:

GNU Emacs 25.1

GNU Emacs 23.0.92

GNU Emacs 22.0.50 (including Meadow 3.00-dev)

GNU Emacs 21.4

GNU Emacs 21.3

GNU Emacs 21.2

XEmacs 21.4

XEmacs 21.5

Tips

How to iconify (or suspend) Emacs?

C-z is assigned to `iconify-or-deiconify-frame` (or `suspend-emacs`), however ElScreen reassigns this key to its prefix key. How can we iconify (or suspend) our Emacs?

Ask emacs where `iconify-or-deiconify-frame` on with “C-h w iconify-or-deiconify”, and it will reply with “iconify-or-deiconify-frame is on C-x C-z”. … Yes, you can also use C-x C-z to iconify-or-deiconify (or suspend-emacs)!

Of course you can change it by setting elscreen-prefix-key as following:

(setq elscreen-prefix-key "\C-z")

Note: You must set this value before ElScreen is loaded.

How to change prefix-key after %%ElScreen%% is loaded?

As described above, ElScreen prefix key can be changed by setting elscreen-prefix-key. However, this will not have any effect after ElScreen is loaded. Even in this case, you can change it with `elscreen-set-prefix-key` as following:

(elscreen-set-prefix-key "\C-t")

How to create screen automatically when there is only one screen?

C-z C-n, C-z C-p and suchlike are used to switch screen. When there is only one screen, these commands just warn and exit. Following code fragment makes new screen for you automatically in that case, just put this to your InitFile.

How to display the list of screens on the frame-title of my Emacs?

Following code fragment will help those who does not want the tabs to occupy valuable space on their Emacsen but display the list of screens somewhere. This displays it on the frame-title of your Emacsen. (This code fragments now uses set-frame-name instead of setting frame-title-format if set-frame-name is avaiable, suggested by Evgeny V. Oleynik).

ElScreen Addons

Use with Anything

Anything, a candidate selection framework, can open files using elscreen .

Start with ‘M-x anything-for-files’ or ‘anything-find-files’, narrow the list by typing some patterns(multiple patterns are space-delimited string), select with up/down/pgup/pgdown/C-p/C-n/C-v/M-v, choose with enter, With TAB actions can be selected if the selected candidate has more than one possible action. With C-z contents of file/buffer is displayed without quitting anything session.

Interface to GNU ID Utils

GNU ID Utils is a package of language independent tools that indexes tokens in source codes. Through ID database, it becomes much easier to list these tokens.

ElScreen-GF is an Emacs interface to GNU ID Utils. With this add-on, you can list tokens with filename and line number in which each token apper, select interesting entries, and jump to them more easily, making use of ElScreen.

ElScreen-GF 1.5.0 or later also supports cscope, and 1.5.2 or later supports GNU GLOBAL. Moreover, 1.5.0 or later is expected to run on XEmacs.

Dired integration

In Dired, ‘dired-find-file-other-window’, which is bound to “o”, opens the entry in another window. With ElScreen Dired, new screen is created for the selected entry if it is a regular file.

ElScreen-server

Emacssen has the ways to access from remote program, emacsclient or GNUServ, and can ask running emacs to open files through these programs. With ElScreen-server, new screens are automatically created for each file.

ElScreen-dnd

On some window system, such as MacOS X, Microsoft Windows, X Window System with some cool toolkit, you can drag & drop files from a file manager to your emacsen to open. With ElScreen-dnd, new screens are automatically created for each file.

ElScreen-WL

Wanderlust is a mail and news client which can manage internet messages with IMAP. ElScreen-WL Add-On software provides the capability to manage draft buffers of Wanderlust effectively in conjunction with ElScreen. When you write new message or reply message, new screen is created for the draft buffer, and when a draft buffer is killed or a message is submitted, the screen for this draft buffer is automatically closed.

ElScreen-W3M

Emacs-W3M is the Web browser on Emacs variants using w3m. It supports tabbed browsing, so ElScreen’s tabbing capability is incompatible with it. ElScreen-W3M resolves this incompatibility by integrating Emacs-W3M’s tabbing into ElScreen.

Bugs

There appear to be bugs in elscreen-e21-command-line where it tries to use unbound symbols dir and line. Customizing elscreen-startup-command-line-processing and setting it to nil should suppress the bug.

Opinions

Compared to escreen (EmacsScreen) its frame support is better: it spawns a new set (0-9) of screens for each frame, which is more in line with what I expect. – DanDebertin

Questions

I want to let first sceen numbered as 1 instead 0, how to do ?

How do I deactivate elscreen once it was loaded?

I’m trying out elscreen, but when I switch buffers via “C-x b” which runs “switch-to-buffer”, I see buffers from all screens when I tab complete. Is there a way to set it up so only the current screen’s buffers show? Thanks!

This work is licensed to you under version 2 of the
GNUGeneral Public License.
Alternatively, you may choose to receive this work under any other
license that grants the right to use, copy, modify, and/or distribute
the work, as long as that license imposes the restriction that
derivative works have to grant the same rights and impose the same
restriction. For example, you may choose to receive this work under
the
GNUFree Documentation License, the
CreativeCommonsShareAlike
License, the XEmacs manual license, or
similar licenses.