Questions tagged [buffers]

The text you are editing in Emacs resides in an object called a buffer. Each time you visit a file, a buffer is used to hold the file's text. Each time you invoke Dired, a buffer is used to hold the directory listing.

Filter by
Sorted by
Tagged with
0
votes
1answer
47 views

Assign buffer-name to variable

I'd like to write Elisp code that compares text character by character between two buffers. To do that, I need to first assign buffer names to the variables source-buffer and target-buffer ...
1
vote
1answer
26 views

Left margin grows while typing

My buffer slips to the right while editing a file. Whenever I press a button, left margin area grows one character. This isn't happening for all files. My buffer normally looks like this: line with ...
0
votes
1answer
22 views

move focus between sub-windows (or buffers?) with ctrl-tab?

Currently using GNU Emacs 23.1.1. I've used xemacs since the late 90s and am only now switching to proper emacs. If I had my xemacs window split into a top buffer and bottom buffer, I could move the ...
2
votes
1answer
30 views

How to ignore case when switching buffers?

I want to open a buffer called Echo.md and switch-buffer (C-x b) does not auto-complete it when I type echo because of the case. But find-file does auto-complete from lower-case to upper-case. The ...
0
votes
2answers
51 views

Create many buffers, name properly, silently

I am trying to avoid using the desktop save mode 1 option in my .emacs file. We sudo a shared service account, so my buffers may differ from my colleagues buffers. I launch Emacs from GNU/Linux with ...
1
vote
2answers
76 views

switching from tmux + terminal emacs to Emacs only

I am thinking of switching from tmux + terminal emacs (emacs -nw) to just pure emacs. The only thing that is holding me back is tmux offer switching between sessions without switching the terminal ...
1
vote
1answer
41 views

get the full path (path + filename) of the currently editing file in to the OS clipboard

when editing a file (for example a .pl file) Whats the quickest way to get the full path (path + filename) of the currently editing file in to the OS clipboard. I'm on macOS, where echo "hello" | ...
1
vote
1answer
23 views

Next buffer command change when in the terminal window

I am totally new to Emacs and on this first day I am trying to do very basic stuff in emacs. I am stuck at switching buffers when there is a terminal window open (by using M-x term). The next buffer ...
1
vote
1answer
59 views

how to enable pager like behavior in a shell buffer?

I can't believe I'm saying this, but one thing that is "nice" about windows cmd is the pager. When I do man grep in a bash shell inside emacs buffer it spits out the entire content at once. Is there a ...
0
votes
1answer
28 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 ...
1
vote
1answer
88 views

Do not open “GNU Emacs” buffer when launching Emacs [duplicate]

"GNU Emacs" buffer is opened automatically when launching Emacs(both terminal and GUI), and I have to kill that buffer everytime. It's boring. How to turn "GNU Emacs" buffer off autimatically when ...
0
votes
0answers
30 views

setting left margin to particular buffer

I have buffer called *mydashboard* which is simply an org file. I want to set the left margin of this buffer to 20 chars. I am planning to use this as my dashboard where I can pin my links to other ...
0
votes
0answers
24 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
23 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 ...
1
vote
1answer
26 views

How to set setting for one mode only?

I currently have the hook below for displaying tabs when in text mode: (add-hook 'text-mode-hook (lambda () (standard-display-ascii ?\t "!---"))) I only want that setting to apply in text ...
0
votes
0answers
21 views

How to silence *Org Preview LaTeX Output* buffer?

Every time I preview a math segment, this buffer pops up with the following text: This is /path/to/bin/dvipng (dvipng (TeX Live)) 1.15 Copyright 2002-2015 Jan-Ake Larsson [1] Is there a way I can ...
0
votes
1answer
26 views

Making resize-mini-windows buffer-local while locally let-bound

Upon striking C-x s (save-some-buffers) or C-x C-c, it report errorsin mini-buffer Making resize-mini-windows buffer-local while locally let-bound. Search the above errors but return no helpful ...
0
votes
0answers
22 views

goto-last-change for multiple buffers

Is there a way to move the cursor to the place of the last change when working with multiple buffers? For working with a single buffer, the command goto-last-change can do the job. My question is for ...
0
votes
1answer
42 views

Emacs freeze with async command

Emacs 27.0.50. Windows 10. This function works finely when the line is commented: (defun Pfedj/write-async-file () (interactive) (async-start (lambda () (setq path "~/org/file....
1
vote
1answer
27 views

Disaable the prompts to save files

Every time, I save files, it prompts that save files ..? (y, n !) There are few cases that saving files are mistake operations. How could disable the confirmation prompts?
0
votes
0answers
14 views

emacs breaks down text snippet copied from another X Window application

When I select with a mouse a block of text in Firefox or VIM for example, copy it and then try to paste in Emacs, it gets pasted, but unaligned, meaning that beginning of the lines shift away to the ...
0
votes
0answers
13 views

When scrolling a list of buffer, can the buffer content be shown in a second window?

When using dired and peep together, I can scroll up (C-p) or down (C-n) the dired file list in the left window, and see the content of each file in the right window. This is a very practical ...
0
votes
0answers
26 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-...
0
votes
1answer
12 views

Invoke select-buffer inside the current buffer

I accidentally activate select-buffer inside the current buffer's working area However, no idea how to repeat the above operation even though pressing various keys. Cloned the configuration from ...
0
votes
0answers
34 views

Filter to track end of process output in buffer by default

Taking advice from the manual as per this link: https://www.gnu.org/software/emacs/manual/html_node/elisp/Filter-Functions.html I've created a filter for a process I'm running under emacs. (defun ...
2
votes
1answer
36 views

Can flymake or flycheck mark in dired (or in buffer lists) files with errors?

It would be nice if, in addition to flymake/flycheck marking errors in particular files, they could somehow mark files with errors in dired (or maybe just in the open-buffers list). The goal would be ...
3
votes
3answers
172 views

User command to reload file-local variables

How can I easily reload file-local variables, after I have changes their values in the file buffer? I know a work around Save and close the file and re-open. But this is pretty cumbersome.
0
votes
1answer
21 views

window-configuration-change-hook false positives from desktop-mode

I'm trying to use window-configuration-change-hook in a package to perform some action when a buffer becomes visible for the first time. It works, however when starting Emacs, desktop-mode calls ...
1
vote
0answers
31 views

How to always show buffer in the new created frame?

My workflow is: I initialize emacs with a shortcut (in my ~/.i3/config I have a line like this bindcode $mod+49 exec emacsclient -c -n -q -a=''. I use i3wm.org) By default it goes to temp.org, in ....
2
votes
3answers
40 views

How to get the argument from previous use of `command-execute`?

I want to automatically rename the buffer name of compilation mode. The default name is *compilation*. Let's call my new compilation command my-compile. So supposing we run my command like this: M-x ...
1
vote
1answer
49 views

How can I automatically swap frame buffers if the buffer is already open?

I've seen the https://www.emacswiki.org/emacs/buffer-move.el script, but I'm trying to something a bit different. Suppose I have a frame with a buffer from file A.h in it and A.cpp in another frame ...
0
votes
2answers
58 views

Save place in files but don't move the cursor to the saved position automatically

I'd like to have a command that moves the cursor to the last position it was in when I left the buffer (either by killing it or by killing Emacs). I know I can use saveplace.el to save the position ...
0
votes
0answers
42 views

How to show the output of a command in a quick-fix window?

If I have a command that runs and generates the following output. /path/to/file.rst:1 /another/path/to/file.rst:42 How would I call the command so a buffer is opened and clicking on the line jumps ...
0
votes
0answers
48 views

Force opening file in new buffer

Is there a way in emacs to open a file (or a dired directory) in a new buffer, even if there's a buffer with the same file (or directory)? find-file and find-alternate-file always return the open ...
2
votes
1answer
46 views

Set the major mode of a new buffer interactively

When creating a new buffer via: C-x b NonExistentBufferName RET RET I would like Emacs to ask me what major mode this buffer is going to use upon opening. Moreover, I want Emacs to infer the major ...
0
votes
0answers
12 views

How to use helm-locate (or similar) when saving a buffer?

When opening a file, I often use helm-locate to quickly access any file anywhere. But when saving a new buffer, I navigate through the directory structure to get the location I need. Is there a way to ...
1
vote
1answer
67 views

How to make *Shell Command Output* buffer scroll to the end?

I often execute shell commands via M-! and their output is then shown in the buffer *Shell Command Output*. How can I make this buffer display the end (rather than the beginning) so that I can see ...
1
vote
1answer
48 views

desktop-save-mode: prevent emacs from showing each buffer on start-up

If you use desktop-save-mode, and have several hundred buffers saved, when you start emacs, emacs cycles through these buffers and shows each of them for a split second. Can this be prevented?
1
vote
1answer
35 views

emacs 25: display-buffer-other-window behavior change, how to tune for the old way?

I have a number of macros for browsing source code for many emacs versions. I wrote this in 2009 and it's been solid until upgrading to U18.04. I know it worked in U16.04: (defun get-file-from-...
1
vote
1answer
45 views

Select *Input History* buffer

The Emacs *shell* has a nice command history accessible via C-c C-l (comint-dynamic-list-input-ring). However, in classic Emacs fashion, the *Input History* buffer which displays the history is not ...
0
votes
1answer
47 views

Treat symbolic-link as separate files while visiting

Is there a way to make Emacs visit already visited file(with active buffer) via symbolic-link as a different file? I want them(links/file paths) to be visited by different buffers. It will be best if ...
0
votes
1answer
29 views

What does it mean in ebib when a field of an entry is preceeded with an asterisk '*'?

When viewing entries in a database in ebib, some fields of some entries are marked with an asterisk (*). In my case, these are usually year or month field. I don't see a rhyme or reason to the types ...
1
vote
2answers
31 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 (...
0
votes
2answers
49 views

Sort lines in a string

Given I have a string that maybe came from a buffer, or a clipboard, or wherever; how do I sort-lines in it? Given that sort-lines only works with a region, I assume I have to put it to a temporary ...
1
vote
0answers
38 views

Do buffers have the notion of a “parent”? [closed]

Often times, when I'm done a task, I'd like to close out of all buffers I was using for it. However, I usually don't, because I think it'd be a pain. What I'd like is to be able to kill all buffers ...
1
vote
1answer
58 views

How to change font size only for the buffer *Org Export Dispatcher*?

I'm using emacs with a large font, however I do not need the font to be too large on certain buffers and/or modes. For example, when I use neotree I use a different font and a smaller size, I do that ...
0
votes
0answers
36 views

Display annotation contents horizontally in pdf-tools *with* live-preview

When looking at annotations with the pdf-annot-list-annotations command from the pdf-tools package, I prefer to preview my annotation contents in a separate buffer, which is the default behavior. ...
0
votes
0answers
27 views

Emacs flashes when changing buffer with `ido-switch-buffer`

When I change buffer via ido-switch-buffer and enter a python buffer my entire Emacs flashes visually for a second. If I handle other files the same way, it does not. What can be the reason for that? ...
0
votes
0answers
26 views

buffer opens in window below if font size is changed

In my config file I changed the line (set-face-attribute 'default nil :height 100) to (set-face-attribute 'default nil :height 90) and suddenly, when I try to open a file in a separate vertical ...
0
votes
1answer
99 views

Removing buffers from buffer list

This is my first day on Emacs, and I am really liking it so far, but I cannot seem to be able to work correctly with buffers. I am trying to kill specific buffers with C-x k, however upon checking the ...