Questions tagged [window-splitting]

is for splitting an Emacs window into two. Multiple windows can display different buffers, or different parts of one buffer. Emacs has several default key bindings for splitting windows.

Filter by
Sorted by
Tagged with
0 votes
0 answers
22 views

Emacs opening .pdf in frame on right

I am trying to setup emacs to open a pdf in a window on the right but (crucially) not to split the frame in half but instead to double (or increase by some other ratio) the size of the GUI Window. I ...
user avatar
0 votes
2 answers
76 views

Using hydra to split windows like in doom-emacs and Spacemacs

I am writing my own Emacs config coming from doom-emacs and Spacemacs. One thing I really miss is the ability to split windows using split-window-below and split-window-right using S-w s s and S-w s v....
user avatar
0 votes
0 answers
24 views

How can I disable horizontal pop up buffers?

If my laptop is connected to a 4K monitor, org export dispatcher, magit other pop up buffers are placed vertically at the right side. If undocked these buffers are placed horizontally over the low-res ...
user avatar
  • 629
1 vote
1 answer
44 views

How can I keep windows from being shrunk past their fill-columns?

Typically I have two windows, left and right, with the left window (call it the "editing window") showing a buffer in a prog-mode or text-mode and the right window (call it the "...
user avatar
0 votes
1 answer
32 views

Trying to open Diary on startup but Emacs is launching in split screen, how can I stop it

I have (diary) setup in my .emacs file so that it will launch diary on launch but it always launches in horizontal split screen with fancy diary mode on bottom and Scratch on top. I've inhibited the ...
user avatar
3 votes
1 answer
63 views

How to get a window in a corner of the frame

Is there a built-in function to return a window in a particular corner of a frame (e.g., lower-left, upper-left, upper-right, lower-right). The following is a first draft to locate the lower-left ...
user avatar
  • 17.8k
1 vote
2 answers
81 views

Split window and move cursor to new window with predefined Emacs command/function

I can split windows with C-x 2 (split-window-below) or C-x 3 (split-window-right). But the cursor does not move to the new window. When I split I need to have the cursor in the new window. Is there a ...
user avatar
  • 569
1 vote
2 answers
46 views

Exotic dired-based window-splitting mode

NOTE: I added more info to this query. Initially, I didn't mention dired, but after experimenting, I see that it needs to be explicitly discussed here, because of how it manages buffers. I'm using ...
user avatar
  • 522
0 votes
0 answers
56 views

Buffer divider staggered upon split window and scroll

Whenever I split windows or scroll with a split window, the buffer dividers and text end up staggered horizontally. Here is a screenshot of a file without the split window or issue shown. And here is ...
user avatar
0 votes
0 answers
25 views

How to change the size of the popup window from org-edit-special?

When I type C-c ' on an org-babel source block, a horizontal split buffer appears where I can edit the source code. If I want to resize this pane, I can do it with window resizing commands or just ...
user avatar
1 vote
1 answer
54 views

Help window in ESS

I am using ESS for using R. When I use help in ESS, I have the screenshot like Picture 1. But, I want to get Picture 2. How do I manage my init.el? The following code is my init related to ESS. (use-...
user avatar
  • 101
0 votes
0 answers
24 views

default split into vertical panes, but don't further split more than 2 panes

When I open a new buffer I would like emacs to split the current buffer into two vertical panes side-by-side (with a vertical line down the middle). Eg I have a single buffer open with source code, I ...
user avatar
  • 101
3 votes
1 answer
53 views

How to control the resulting sizes when splitting a window?

I often split my windows into two with C-x 2. The window in the bottom tends to be the SLIME's REPL or Magit and the one at the top is usually the common lisp file being edited. I like to have more ...
user avatar
1 vote
1 answer
69 views

With side-by-side windows how to slide the middle vertical bar?

I often have two buffers open side by side and I'd like to be able to slide the central vertical bar to the left or to the right, in order to make either buffer wider or narrower. Is this supported in ...
user avatar
1 vote
1 answer
70 views

What controls whether `M-x compile` splits a frame into two windows?

To resolve some performance issues I refactored my .emacs, and since the refactoring, M-x compile does not split a frame into two windows. Instead, running M-x compile takes over the entire frame ...
user avatar
1 vote
1 answer
139 views

Is it possible to open Deft in a sidebar?

I'm trying to open Deft in the left sidebar using this code: (setq display-buffer-alist '(("*Deft*" (display-buffer-in-side-window) (window-width . 0.25) ...
user avatar
1 vote
1 answer
153 views

Using Shackle to manage WoMan buffers

I would like shackle.el to manage the buffers created by WoMan. Here's the configuration I'm using: (use-package shackle :config (setq shackle-rules '((woman-mode :select t :align below :size 0.5))...
user avatar
  • 1,740
0 votes
1 answer
142 views

Open two files on startup - how to set vertical split as default?

When I invoke Emacs from the shell with the command emacs fileA fileB, I'd like to have the Emacs window split vertically (i.e. with one file on the left and one file on the right), not horizontally, ...
user avatar
  • 143
3 votes
1 answer
101 views

How can I specify the maximum number of windows

I like to work with two windows split horizontally or vertically. However, when I try to use C-x 4 f (ido-find-file-other-window) when I already have two windows, it will split one of my windows so I ...
user avatar
  • 1,004
0 votes
0 answers
31 views

Stop reftex-toc from opening a new window if only one window is currently open

Currently when I choose an entry from RefTex's table of contents (opened using the C-c = keybinding), if I only have a single window open, the chosen file is opened in a new window to the right of the ...
user avatar
  • 1
0 votes
1 answer
53 views

Open a new buffer on the right

I just upgraded from Fedora Linux 32 to Fedora 33 and I think this updated emacs as well because I now see some new behaviours. I have set: (global-set-key (kbd "<f6>") 'org-todo-list) ...
user avatar
  • 103
0 votes
0 answers
27 views

Create term horizontal split that is 20% size key binding

I'd like a key binding that can create a term buffer in a 25 percent split. What I mean by that is, with a specific key binding like SPC t c, I'd like to open up a terminal in a split.
user avatar
0 votes
1 answer
40 views

Adapt a function to work when windows are split only vertically

As @drew asked me to do here I'm asking one question per problem I'm trying to enable/disable visual-fill-column when there is one window/multiple windows. (defun my-visual-fill-one-window () (...
user avatar
  • 178
1 vote
0 answers
28 views

How to show all split window titles in the X11 window title?

If I split an Emacs frame (one X11 window) into multiple Emacs windows (with C-x 2 and C-x 3) and open different Emacs buffers in different Emacs windows, Emacs frame title (X11 window title) displays ...
user avatar
  • 111
0 votes
0 answers
60 views

How to control the way windows are opened by "next-error" and "previous-error"?

The context In the gif shown below, I demostrate that the way next-error show the current error in a new window depends on the size of the font. When using the font Fira Code 20, a single window is ...
user avatar
  • 487
1 vote
1 answer
244 views

Force one window when opening multiple files

Any time I open multiple files I'd like emacs to only show me one buffer. I do not want any split windows. This would save me a keystroke every time. I learned I could do away with the buffer list ...
user avatar
0 votes
1 answer
74 views

Prevent screen splitting by julia-repl

I want to prevent julia-repl from splitting my screen, which seems like a common request given the numbers of questions I have found relating to this. Drawing on advice found here and here, I came up ...
user avatar
  • 191
3 votes
0 answers
63 views

Why is file buffer replaced by scratch buffer on startup?

When I open an R file in ESS-mode, I'd like emacs to setup my panes in a certain format. To this end, I've added the following to my init.el. (add-hook 'ess-mode-hook (lambda() (...
user avatar
  • 191
0 votes
0 answers
28 views

Patching together emacs buffers and shells outside of emacs

I'd like to use emacs as a replacement for my current IDE when using R. I like to divide my workspace into three panes: Text editor R console zsh Previously, I had used tmux to achieve this by ...
user avatar
  • 191
2 votes
1 answer
84 views

In EXWM `split-window-right` followed by immediate `windmove-right` swaps order of buffers

I have a function (defun bad-fn () (interactive) (split-window-right) (windmove-right) ) If I go to a frame with just one window visiting EXWM buffer A (and buffer B is next), and call split-...
user avatar
6 votes
1 answer
168 views

How to open new window below _all_ other windows?

Suppose my Emacs frame looks like this: .-------------. |a |b | | | | | | | | |------| | |c | | | | | | | '-------------' Is is possible ...
user avatar
1 vote
0 answers
60 views

Split window on specific buffer

I am new to Emacs but I'm working hard to catch up :) I try to get Emacs splits a window (with C-x 3 for example) not on the same buffer (default behaviour) but on a specific *dashboard* buffer. I've ...
user avatar
  • 11
1 vote
1 answer
123 views

How can I create a frame and open two files split vertically in it?

I am trying to write an Elisp function that will create a new frame and in that new frame open two files split vertically. I have been unable to find anything about this in the Elisp manual, node ...
user avatar
  • 121
1 vote
1 answer
57 views

How can I split a window so that the cursor ends up in the right / lower window?

The functions I have found for splitting windows are (split-window-right) and (split-window-below). When these are evaluated the cursor ends up in the right window in the case of (split-window-right)...
user avatar
0 votes
1 answer
247 views

Why set-window-dedicated-p doesn't work with certain buffers?

I use emacs for latex, with pdf-tools. My layout is always a window with PDFView buffer on the right, any other buffer on the left. I always want the right window that cannot be touched by ...
user avatar
4 votes
1 answer
1k views

Split Emacs Screen Three Ways

In my .emacs file I have (split-window-right). This has been working fine so far, but now I'm finding it would be easier if my workspace looked like: where each box is a separate window. So really I ...
user avatar
0 votes
1 answer
117 views

Get org-agenda toggle all agenda and todo below frame (similar to ivy list buffer)

I have this function: (defun org-agenda-show-agenda-and-todo (&optional arg) (interactive "p") (org-agenda arg "n")) When calls, it will toggle a window with all of my current agenda ...
user avatar
  • 285
0 votes
0 answers
54 views

Function to toggle 'list-bookmark' in the style of Neotree or speedbar

I modified this function: #+BEGIN_SRC emacs-lisp (defun toggle-bookmark-list () "Toggles between bookmark list and current buffer " (interactive) (if (string= (buffer-name) "*Bookmark ...
user avatar
  • 285
0 votes
2 answers
134 views

How could "C-x 4 b "which pop-up-window but display to the right?

In emacs -Q, I strike C-x 4 b which invoke (switch-to-buffer-other-window) and display the other window vertically as I reference it's source code (defun switch-to-buffer-other-window (buffer-or-...
user avatar
  • 1,099
0 votes
0 answers
15 views

Provide hint about which windows for a function to use?

I like follow-mode which I have recently discovered. But I would like to avoid completely losing my window setup within a frame. Is there a way to label a window as usable by a function?
user avatar
  • 1,173
1 vote
1 answer
126 views

How to prevent the completion window from hogging up nearly whole frame (-3 lines)?

One or the other of the various Emacsen has been, at different times, my one and only editor on all *nix systems¹. I usually use one X window per buffer, so I can arrange windows side by side, or use ...
user avatar
  • 153
2 votes
1 answer
132 views

Linked, Split screen scrolling for a single buffer?

I would like to be able to have a C-x 3 split to have two windows in a frame both windows view a single buffer window on left ends at line n window on right starts at line n +/- configurable offset ...
user avatar
  • 1,173
1 vote
2 answers
456 views

Two windows split horizontally-> can't split vertically

emacs 26.1 I split windows-horizontally by split-window-horizontally Nice. Now I want to get smt like this: I try split-window-vertically , but I get this (not correct result):
user avatar
  • 3,445
6 votes
2 answers
322 views

C-x 3 open a new buffer to the left of the current buffer

When strike C-x 3, a new window and buffer will open to the right of the current buffer. How could set it open to the left of the current?
user avatar
  • 1,099
1 vote
1 answer
181 views

Choose where org-agenda-tree-to-indirect-buffer window opens

If I have an org file open: +----------------------------------------+ | | | | | ...
user avatar
  • 281
0 votes
0 answers
90 views

How to keep a high-level window configuration?

I use Emacs as a single maximized frame. The monitor is wide enough for two windows to sit together there, with a vertical split. I want this window configuration to be permanent, i.e.: I want it to ...
user avatar
  • 5,497
1 vote
0 answers
304 views

How to open two files in two frames on startup?

Here's what I'm trying to make happen: on startup, I want emacs to split vertically into two windows displaying two different files, with my to-do list on the left side of the screen and my notes on ...
user avatar
1 vote
0 answers
125 views

Open code snippet from org-mode with C-' in a vertical split instead of an horizontal one

In org-mode, I open a code snippet with C-' (org-edit-special) to edit it in a separate split. By default, it opens it in a horizontal split. Is there a way to open a code snippet from org-mode with ...
user avatar
  • 21
1 vote
2 answers
131 views

How prevent `display-buffer` from opening a specific buffer in a new window if and only if it is shown in another frame

I want the *compilation* buffer to not pop up in my main frame when I have it in another frame already open. However if the buffer is not shown anywhere, I do want it to pop up in a new window of the ...
user avatar
  • 1,081
5 votes
1 answer
387 views

How to display *help* buffers below one specific window?

I am (really) new in Emacs and ESS, and I am currently trying to customize my environment. The default settings of ESS[R] are convenient for me, since ESS[R] organizes the windows as follows: --------...
user avatar
  • 1,014