Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

In Emacs, a window is one part of a frame, displaying one buffer. For questions about operating system windows, see the tag 'frame.

0
votes
1answer
21 views

Magit popup set height automatically

When the magit-commit-popup window opens, there are one or two lines that are just below the screen. Calling fit-window-to-buffer in the popup buffer fixes the problem, but I would like to automate ...
2
votes
1answer
51 views

What is the difference between switch-to-next-buffer and next-buffer?

To go to the next/prev buffer I use the commands next-buffer / prev-buffer. This works well and is very comfortable. But there are also two other commands switch-to-next-buffer / switch-to-prev-buffer ...
1
vote
1answer
41 views

Minibuffer for each window

Is there a way to have a minibuffer window for each window? I don't want recursive minibuffers, just one per window so that I don't have to look to the bottom of the screen when editing a window ...
2
votes
1answer
46 views

Move to other window backwards?

Emacs has the function other-window that lets you jump between windows. The function's documentation states that it takes an optional argument that tells the function how many windows to jump ahead. ...
0
votes
1answer
26 views

Unable to use ediff with emacs and evil due to window configuration

Running emacs 25.2.2 with evil installed and updated from Melpa. When I run ediff, it asks for usual buffer A and buffer B and then ONLY the ediff buffer in its own frame is visible with 'Type ? for ...
1
vote
1answer
27 views

Reopen closed window in Spacemacs

How can I reopen a closed window in Spacemacs? Something like Cmd-Shift-t in Chrome. I open a window using SPC w s and delete it with SPC w d, but I don't know how to reopen one that I've closed.
1
vote
1answer
21 views

helm-find-file (and other things) appearing in my main split

I currently have helm installed. Sometimes when I have my window split vertically, when I run helm-find-files, it appears in one of the already open windows, rather than creating a new horizontal ...
0
votes
0answers
18 views

Why ace-window doesn't show sometimes the window id?

I initialize the package ace-window with this code: (use-package ace-window :ensure t :config (global-set-key (kbd "M-p") 'ace-window) (custom-set-faces '(aw-leading-char-face ((t ...
0
votes
1answer
43 views

What keys can I use to create/delete and select side windows?

I have a shell buffer that's a good candidate for a side window: I also regularly use an org buffer, that's always good to have around. https://www.gnu.org/software/emacs/draft/manual/html_node/elisp/...
2
votes
2answers
100 views

Running elisp within an orgmode code block

Consider the following elisp source code within a .org file: #+BEGIN_SRC elisp :results silent (delete-other-windows) (split-window-right) (switch-to-buffer-other-window '"*Python*") #+END_SRC This ...
0
votes
1answer
51 views

Emacs daemon multiple buffers for same file

When running Emacs as a daemon, function find-file automatically selects and uses a preexisting buffer that is visiting the same file. My problem is, when using the same buffer in multiple frames ...
1
vote
1answer
150 views

How to set up custom layout for spacemacs?

I want to ask something regarding making my own custom layout for spacemacs. I have read the documentation. They have an example like this: This is the custom layout for ERC buffers. (spacemacs|...
0
votes
1answer
83 views

How can I split the neotree window in spacemacs/emacs

I want my neotree window not to extend all the way to the bottom as shown here. How is that possible? If I try to split it I get an error saying the side window can't be split.
3
votes
0answers
33 views

Emacs 25.3.2: reverse windows on file opening

If I open 2 files by command line: emacs file1 file2 in Emacs 25.3.2, file2 is opened in the upper window and file1 in the lower. This didn't happen in previous versions of Emacs that had the ...
0
votes
1answer
48 views

Emacs Dired `C-x C-j` opens a new frame instead of a new window

I am using Aquamacs 3.3 GNU Emacs 25.1.1 and Dired+. Sometimes the key sequence C-x C-j opens the Dired buffer in a new frame instead of a new tab in the running frame. I want the behaviour that the ...
5
votes
3answers
132 views

How to autoscroll a window to always show the end of a growing buffer?

Context: I have a window that shows the output of a shell command. As new lines are added, I'd like the window to always show the most recent lines. Example: (let ((temp-window (or (get-buffer-...
0
votes
0answers
43 views

How to make new windows use the current font size?

When making a new window (using make-frame-command), how can I use the current font scale for new windows? Note: reported a bug, since it seems this might be good default behavior.
4
votes
2answers
622 views

Open new window and switch to it

Assume I'm opening a new window with for example C-x 2 or C-x 3 then the buffer opens and I need to switch to it by hand with C-x o. Is there a build in solution to do this with one command? Or even ...
0
votes
0answers
81 views

How to reuse org-tree indirect buffer windows?

So I would like to use the function below. The problem is that if I call this multiple times another window opens instead of the window that already exists. All the buffers that are created look like ...
2
votes
1answer
188 views

Prevent Helm from opening in a new frame

I recently updated Helm from MELPA to version helm-20180305.1056 and helm-core-20180306.2241. Now sometimes when I use Helm it opens in a new frame. I think this happens when I have 2x1 or 2x2 window ...
0
votes
0answers
50 views

How can I set a directory buffer in one window to open files in another window?

The setup I am going for would look something like this: ------------------------------ | | | | | B | | | | | A |----...
4
votes
2answers
147 views

Prefer vertical splits over horizontal ones

There are several questions similar to this one. I have read them all and they don't provide an answer for my scenario. I want emacs to prefer vertical splits (splitting windows into left and right ...
1
vote
1answer
100 views

Remapping C-x C-b to Open List of Buffers in Same Window

I use Emacs across different machines and operating systems. I noticed that when I press C-x C-b to get a list of all buffers, on some machines the list opens in the same window where the cursor is ...
2
votes
0answers
63 views

Jump between two frames, code improvement

I often have got multiple emacs frame in various desktop, but only two of them are visible. I often need to jump between those two frames, but since other frames are opened I can't use C-x 5 o, ...
0
votes
2answers
135 views

Newbie: Simple setup for dired in sidebar?

Simple question from a new Emacs user: I'd like to have my editing window have a sidebar (or a divided window, or a frame--I'm not sure of the terminology or the options here) that has a dired (or ...
0
votes
0answers
87 views

How to enable minimap when X and disable it when noX?

I want to disable minimap when nox system. (defun my:minimap-only-x() (when (eq window-system 'x) (add-hook 'prog-mode-hook 'minimap-mode))) (add-hook 'prog-mode-hook 'my:...
0
votes
0answers
205 views

Display calendar at bottom in Org Agenda

Recently I find that when I want to display calendar in Org Agenda, it opens a new window instead of displaying at bottom as in Org File. My Emacs version is 25.3.3 with Spacemacs 0.300.0(develop ...
2
votes
1answer
48 views

is there a hook that is run before a window is deleted

I want to do some custom stuff before a window is deleted? window-configuration-change-hook seems to be invoked after a window is deleted.
2
votes
1answer
324 views

Neotree window not resizable

I get this message when I try to resize the neotree window using my mouse: No resizable window on the left of this one Does anyone know how I can make the neotree window re-sizable?
1
vote
0answers
99 views

Set Neotree width by percentage?

I currently have this in my config file for neotree: ;(neotree-show) (setq neo-window-width 25) Does anyone know how I can set the window width to 25 percent?
4
votes
2answers
72 views

Display all/current CSV heading names

In CSV files (especially ones with a lot of columns and/or a lot of rows) I find that it's hard to tell which column I'm on. Normally I'd like to know either the column heading, or sometimes the ...
3
votes
0answers
23 views

Keyboard macro with occur

In a keyboard macro, there is an occur command. While recording the macro, I switched to the occur window, did some editing, closed occur buffer reverted back to original buffer to continue editing. ...
1
vote
0answers
46 views

Restrict Mode Line display to window

I am configuring mode-line and currently the time is displayed in each window's mode-line, as shown by the image below. Is it possible to restrict the time display to the bottom right mode-line?
0
votes
0answers
66 views

org-edit-src-code in a specific window

I am currently using org-mode to edit code blocks for presentations and blog posts. Currently I have a frame set up with one large window pane on the left, and two smaller panes on the right. The ...
2
votes
2answers
84 views

replace-buffer-in-windows issues in switching from emacs 24.5 to emacs 25.2

I installed Emacs 25.2 on a new system and cannot get the desired behavior with killing buffers when an Emacs frame is split into multiple windows. For example, I have C-x 3 bound to a variation of ...
3
votes
0answers
59 views

How to open all buffers in the same window and never create new one?

I'm using emacs in terminal via emacs-nox and I wish to sort of disable windows functionality at all. I mean I do not want each time to add some buffer to use display-buffer-same-window function, I ...
0
votes
1answer
56 views

Preserving Layout Using emacsclient

If I spawn Emacs in --daemon mode, I can then use emacsclient to connect to the daemon from within a terminal window. If this then dies, I can reconnect my terminal and my Emacs session is still ...
2
votes
1answer
141 views

How to control which window is opened as “other Window”?

I am new to Magit and Spacemacs. I do not understand descriptions of other-window and next-window in the manual. I have 4 windows open in a Spacemacs frame like this: +--+--+ | | | +--+--+ | | | ...
1
vote
1answer
97 views

get buffer scroll position and height (aka min and max on-screen buffer locations)

I'm interested in the region of a buffer that is visible on-screen. How do you get the current scroll position of a buffer? I.e. the line number of the topmost line in the viewable area? (Given ...
3
votes
1answer
138 views

How can I eliminate the side effect of left margin?

I've set a left margin like this: (set-window-margins (get-buffer-window) 20 0) (let ((gutter-sep (concat (make-string (- (car (window-margins (get-buffer-window))) 2) ? ) "+"))) (propertize "." '...
2
votes
0answers
60 views

Resize windows line by line, not pixel by pixel

Is it possible enforce that Emacs changes the window size line by line, not by some count of pixels, to eliminate the situation when I see a half-line on the screen? I mean window in Emacs sense (...
6
votes
0answers
104 views

How do i run zone (zone-when-idle) for all windows?

Zone Mode is awesome But when I run it using M-x zone, or by setting zone-when-idle variable it starts animating only one(selected) window. Is there any way to run it for all windows?
0
votes
0answers
86 views

How to prevent grep results from opening in a specific window

Lets say I have 4 windows open. In one of them I'm running a shell command that is constantly compiling the files that i'm modifying. I want to keep this buffer visible at all times. In one of my ...
1
vote
1answer
52 views

Dired+: Not enter in folder when window is split

Windows 10, Emacs 25.1., Dired+ I want to copy file from folder "test" to folder "response". My steps: Open folder "test" see screen: split window by command (split-window-vertically &optional ...
0
votes
0answers
39 views

Open multiple windows from buffers and auto-balance them

Is there a predefined way in Emacs/ a library function to select a number of buffers, open each of them in a separate window and then (intelligently) balance these windows? It would be great if the ...
1
vote
2answers
58 views

Opposite of display-buffer

My use-case: So, I have two windows in a frame. Each window has a different buffer rendering in it. Out of them one was previously displayed using the function display-buffer. Now, I want that buffer ...
3
votes
1answer
210 views

Opening emacsclient -n -c opens a small frame with small fonts

I had set up a emacs --daemon at the OS startup and whenever I try to open emacsclient -n -c emacs opens a small window (possibly the minimum size possible) and with unreadable fonts (they are too ...
1
vote
0answers
32 views

Change Emacs's frame size according to the file

Is it possible to change the size of the frame of Emacs according to the file opened? For example, I want Emacs to be in maximized mode when I visit file_a.
0
votes
0answers
30 views

Synchronizing the units in which horizontal scrolling is measured with buffer columns

The problem I am trying to solve is determining how many columns of the current buffer are hidden due to horizontal scrolling. The documentation states: The horizontal scroll position is measured ...
2
votes
2answers
75 views

Why does `text-scale-increase` not affect `window-text-width`

I am trying to calculate how many characters are being displayed in a window, but the information I get from (window-text-width) isn't updated if I call (text-scale-increase). Why? A typical session ...