Questions tagged [window]

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

Filter by
Sorted by
Tagged with
21
votes
4answers
3k views

Hide *compilation* window

It is annoying to see the compilation window appear when it is successful. How to remove that automatically? I want to see it though if it is not successful.
3
votes
5answers
52 views

Manually close a (compilation) window that was most recently opened by running e.g. 'grep'

I'm trying to find a way to quickly close the window that I just created by running 'grep' (i.e. a kind of compilation window). I'd like the solution to be independent of my current window layout and ...
0
votes
0answers
15 views

disable syntax highlight on inactive windows

I got the following code for highlighting inactive and active windows with different background color. How do I make so that inactive windows have no syntax highlighting, only the active window has? ...
28
votes
3answers
6k views

How to change Emacs windows from vertical split to horizontal split?

Window A ++++++++ Window B Is there a way to switch to Window A : Window B Is there a way to switch view without closing windows?
1
vote
1answer
26 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 ...
2
votes
1answer
38 views

How to leave mark region highlighted when switching windows

I usually have my Emacs frame split into windows. I'll select something in one window and then switch to another buffer. When I do this Emacs removes the active-region highlghting in the original ...
4
votes
2answers
329 views

Is there a generic toggle-previous-window function?

Some major modes have code and key-bindings to toggle focus back and forth between their inferior processes and the major-mode buffer. Is there an Emacs function which lets me do this between the ...
1
vote
1answer
27 views

Ispell suggested word window too small

When I use ispell, it suggests replacements for misspelled words in a window at the top of the screen. However, it is too small, and I can barely read the words it contains. How do I increase the ...
1
vote
1answer
22 views

Restore after `maximize-window`

If I have multiple windows open, I can maximize one using M-x maximize-window. How should I restore the windows to their original size?
1
vote
1answer
26 views

How to stop (aquamacs) emacs opening all new buffers in new (gui) window/emacs frame?

I've just upgraded my aquamacs installation and a bunch of packages, and now emacs is opening every new buffer in a new (gui) window (aka emacs frame). I don't like this. I want to have every buffer ...
4
votes
2answers
613 views

Neotree window permanently resizes other windows

I usually have my emacs frame something like this: | | | | <window 1> | <window 2> | | | | When I open neotree, it then looks like this (...
2
votes
2answers
132 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 ...
3
votes
1answer
199 views

Define the window location of the output of shell command

I use M-! to run the command shell-command. The output will open the buffer in a new window at the bottom. Can I configure it to appear on the right?
0
votes
1answer
251 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.
2
votes
2answers
365 views

How to open multiple files in multiple windows at startup

In earlier versions of emacs one could use emacs -nw file1 file2 file3 and see three files (and no buffer list) at startup. For recent versions this no longer works. Is it possible to add some code to ...
0
votes
0answers
84 views

How to make ibuffer open the selected buffer in the most recently selected window?

I use ibuffer-sidebar-mode and when you are on a file buffer name in it and hit enter, I am not sure how it decides where to open that buffer if the rest of the window is split in multiple buffers. I ...
1
vote
1answer
79 views

which-key takes up entire lower half of the screen (possibly related to package zoom)

Suddenly which-key, when triggered, takes up the entire lower half of the screen although only a portion of that is then filled with information. This behaviour started a couple of days ago, but I did ...
2
votes
1answer
49 views

Getting a sorted window list

(window-list) returns a list of visible windows. Is it possible to get this list sorted from the most recently active window to the least?
0
votes
0answers
51 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 ...
1
vote
1answer
156 views

How can I make emacsclient use an existing window in the current frame?

I'm on MS Windows, if that makes a difference. My desired behavior: There is only one frame visible at any time. Visiting a file should use an existing window in that frame. (This is the default ...
5
votes
3answers
80 views

Sending `C-c C-c` to the process window without swithcing to it

In ESS mode, I sometimes send some code to the process buffer and want to cancel it using C-c C-c. Can I do this without actually switching to the process window from the script window?
7
votes
2answers
4k views

How can I adjust the fixed-width of a Neotree buffer?

Using emacs 24, when I try to use the Neotree package I am having issues with modifying the fixed-width of the window. I believe I have found the responsible chunk of lisp, but changing the value ...
0
votes
1answer
52 views

Multiple initial buffers in different windows

I have Emacs set up to open an initial org mode buffer on startup by (setq initial-buffer-choice "~/Directory/Subdirectory/inital_buffer1.org") Ideally on start up, I would like to open 2 buffers in ...
2
votes
1answer
80 views

Why can't I resize my windows to be the same width?

When I split windows using SPC-w / then my windows are created with different widths. I want them to split in half. I can't resize it by dragging it nor by using the shortcuts. I downloaded emacs ...
0
votes
2answers
191 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 ...
1
vote
2answers
313 views

Automatically toggling margin width on resizing

So I'm using Emacs in Windows (Emacs 24.5.1, Windows 10). I've set a default margin width of 20 on both sides for text-mode, but occasionally I like to resize the window in half (Windows+left or right ...
6
votes
3answers
287 views

Is there a way to make the “o” keypress of other-window <C-x><C-o> repeatable?

Question is as stated in the title. Instead of using various packages for switching windows, it might be simpler to make <C-x><C-o> behave like <C-x><C-+>, such that repeated ...
0
votes
0answers
28 views

Tabs on windows with custom buffers

I am new to Emacs and I am trying to set up a decent workflow for projects I already have. What I want to do is to be able to have tabs of buffers on each window (not frame). What I want ...
0
votes
0answers
30 views

Is there a way to split-window-right and switch-to-buffer / find-file in single command?

As described in question title. Closest solution that I can find is to use ido-find-file-other-window orido-switch-buffer-other-windew, but these create a horizontal split by default, and if a ...
0
votes
0answers
32 views

How can I open WoMan's pages from bash?

I first tried emacsclient -t -e '(woman "sox")', but it opens the WoMan's buffer as a popup: Then I tried emacsclient -t -e '(woman "sox") (spacemacs/toggle-maximize-buffer) (sleep-for 3) (delete-...
1
vote
1answer
49 views

elisp debugger jumping windows around

I'm trying to use the built-in elisp debugger, invoked by debug, and read the source code at the same time. Unfortunately, whenever I continue execution, with either c or d, the debugger jumps around ...
3
votes
0answers
172 views

Adding Purpose to Layout Of Emacs

The rigidity to which emacs adheres to its layout is annoying at times. How can i get a layout like this when I shift to the particular modes? +------------------+-----------+ | | ...
2
votes
1answer
70 views

how can I programatically transition between those 2 window layouts?

I am trying to implement this window transition a/ b/ --------- ------------- | 1 | 2 | | | 1 | 2 | --------- -> | 0 |-------| | 3 | 4 | | | 3 | 4 | --------- ...
0
votes
0answers
15 views

Split frame as 2×2 max, with horizontal priority

Well, this is another window configuration question, and I feel like I'm totally missing the point. I have been spending the last couple of hours messing with split-height-threshold, split-width-...
1
vote
0answers
47 views

How to make find-file-other-window reuse existing window

Is it possible to make find-file-other-window open the file in a pre-existing window instead of creating a new one? Currently: |A---|B---| |A-|C-|B---| |----|----| -> ...
1
vote
1answer
63 views

How to return focus to dired window after killing buffer opened from dired?

Sometimes I use dired to view or edit several files in one folder, one after the other. Dired is open in one window, and I open the files in another window by typing o in dired. When I finish with one ...
4
votes
2answers
692 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 ...
0
votes
0answers
43 views

pop-to-buffer: Wrong type argument: window-valid-p, #<window 117>PNG warning: Interlace handling should be turned on when using png_read_image

I occasionally run into the following error when opening a new file with projectile: pop-to-buffer: Wrong type argument: window-valid-p, #<window 117>PNG warning: Interlace handling should be ...
2
votes
1answer
142 views

How to make Dired sort on special characters in the beginning of file or folder names?

In Windows File Explorer (FE) I can give a file or folder a name with a special character as the first character, and thereby make them move on top when sorting the files alphabetically. For instance, ...
1
vote
1answer
53 views

How can I create a window that can't be closed?

I create a window with the following (setq ook-window (display-buffer-in-side-window buffer '((side . bottom)))) (set-window-dedicated-p ook-window t) But then when I go to the main window and ...
0
votes
1answer
47 views

Switching directly to a certain window

If I have 3 windows beside each other, can I switch to any one of them without having to look for the cursor first (so I know whether to press C-x o once or twice)? Is there, for example, or could I ...
8
votes
3answers
734 views

How to cycle between two windows when I have more than two open?

Scenario: I have several (more than 2) windows open. I actively work with two of them. How do I best jump from one window to another, and back, with one command? I use ace-window; it's great but I ...
2
votes
1answer
115 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/...
3
votes
1answer
357 views

How to force new `shell` to appear in current window?

Whenever I run M-x shell, a buffer appears almost randomly somewhere - splitting current windows as it sees fit. I cannot work out the logic behind it. The docstring says: (shell &optional ...
4
votes
2answers
101 views

How to toggle between previous buffer in a given window (e.g toggle-previous-buffer-in-window)?

How can I make Emacs toggle between the previous buffer within a single window (e.g. ignoring buffer changes in other windows)?
1
vote
2answers
36 views

cycling between minibuffer and last window|buffer

I'd like to cycle between an active minibuffer window and the last recent buffer. 1 (defun cycle-to-minibuffer-window () 2 (interactive) 3 (when (active-minibuffer-window) 4 (if (...
1
vote
0answers
42 views

macOS-like look and behavior on Linux [closed]

I would like to get macOS-like look and behavior on Linux, e.g. global(app) menu, no border on the top of Emacs window etc. I don't care about fancy icons and themes, but these two features are key ...
1
vote
1answer
63 views

Edit with Emacs chrome extension closing windows

I have the edit with emacs chrome extension. I have emacs open in one frame with multiple windows on different buffers open. When I am in chrome and focused on a text box I press Alt-Enter. This ...
2
votes
1answer
64 views

If start with maximized frame, why do windows open top &bottom, not side by side?

I have the following in my .emacs: (add-to-list 'default-frame-alist '(fullscreen . maximized)) And (add-hook 'window-setup-hook (lambda () (find-file "FILE.org") (shell))) ...
1
vote
0answers
35 views

elisp: create window layout with specific cycling order

I'd like to create a window layout like so: -----------|-------------- a | b -----------|-------------- d | c -----------|-------------- This is so that I can cycle from a ->...

1 2 3 4 5 7