9
votes
Accepted
How to move the cursor to the next instance of the text the cursor is currently on?
I think what you're looking for is isearch-forward-symbol-at-point which is bound to M-s .
Here's its documentation:
(isearch-forward-symbol-at-point)
Do incremental search forward for a symbol found ...
7
votes
Accepted
Quickly jump to favorite folders
It's unclear to me why you want/need to add such symlinks. Why not just use Emacs bookmarks?
If you use Bookmark+ then you can have:
Bookmarks to Dired buffers (which record lots of stuff, including ...
7
votes
How can I navigate up/down a log from magit-rev-mode?
That isn't supported yet but you can do it "the other way around". Instead of pressing RET to show and select the revision buffer, press SPC to show the revision buffer but stay in the log buffer.
...
7
votes
Accepted
Navigate to the source code of built-in functions and variables
The reason you sometimes see “interactive compiled Lisp function” (or likewise for variables) with no file name is that the function was loaded from a byte-compiled file and the corresponding Elisp ...
6
votes
Accepted
After executing org-narrow-to-subtree, how do I move between subtrees of the same level?
If what you want to move the narrowing along with point to the next subtree, you can define a command that does that:
(defun my/org-narrow-forward ()
"Move to the next subtree at same level, and ...
6
votes
Accepted
Bookmarking / Highlighting lines in a file
There are several ways to do this. One of my preferred methods is the bm package. The package provides visual bookmarks:
The setup is dead simple:
(require 'bm)
(global-set-key (kbd "<C-f2>")...
5
votes
Accepted
Navigate to a certain paragraph number
I'm not aware of a built-in function for this, but as you already noted you can write one:
(defun goto-paragraph (arg)
"Go to paragraph ARG."
(interactive "nGoto paragraph: ")
(goto-char (point-...
5
votes
How to switch back and forth between two locations in a buffer
For the past 20 years or so, I've been using these two gems:
(defun ska-point-to-register ()
"Store cursorposition _fast_ in a register. Use ska-jump-to-register
to jump back to the stored position....
4
votes
How to switch between windows quickly?
Some good answers here, I also am a fan of WinMove, but I bind it to C- because org-mode uses M- for manipulating headings
(define-key global-map (kbd "C-<up>") 'windmove-up)
(define-key global-...
4
votes
Accepted
is there a keybinding to save curor position for returning after viewing other section of same buffer?
@Aaron answered well with the usual way to take care of this in Emacs: set a mark where you are now, then get back to it later using C-u C-SPC.
Another way is to use a bookmark, in particular a ...
4
votes
Accepted
Can I focus the echo area when there’s no prompt?
The echo area is not really a buffer. It is an area of a window. It is used to display messages and to display the minibuffer (which is a buffer).
You cannot "visit" the echo area and select text ...
4
votes
Accepted
Add browser bookmark to bookmark browser
The following seems working from here (I don't use the Bookmarks feature, and I ain't familir with its protocol.), I tested it with:
M-x your-bookmark-set-url https://example.com
M-x bookmark-jump ...
4
votes
Is there a way to make the "o" keypress of other-window <C-x><C-o> repeatable?
You could write a function similar to text-scale-adjust. E.g.
(defun mw-other-window-repeat (count &optional all-frames)
"Wrapper around `other-window' to continue to jump to other with key o."...
4
votes
Is there a way to make the "o" keypress of other-window <C-x><C-o> repeatable?
I use this in several of my libraries. Use it to make pretty much any command repeatable even when it's on a prefix key.
(defun repeat-command (command)
"Repeat COMMAND."
(require 'repeat)
(let ...
4
votes
Accepted
Selecting punctuation, namely, periods, commas, question marks, exclamations, etc. in Emacs
Two rules to take into account when solving your problem:
Do not persistently mess up the syntax table if you do not see through all the consequences. It is used for many tasks.
Do not advice forward-...
4
votes
How to navigate to the next/previous python class?
What I found so far and use to navigate between classes in python-mode:
First C-M-u which runs the command python-nav-backward-up-list to navigate up to class definition. After that C-M-a (beginning-...
4
votes
Is there a command (and ideally a key binding) to navigate to the top (or bottom) of an org table?
Not that I know of, but Org mode provides the ingredients to roll your own easily:
(defun org-table-goto-beginning ()
(interactive)
(goto-char (org-table-begin)))
(defun org-table-goto-end ()
(...
3
votes
Navigate to the source code of built-in functions and variables
If you're looking for ways to quickly jump to source code, there are also find-function-at-point and find-variable-at-point which will jump to the definition of the symbol under the cursor - you could ...
3
votes
is there a keybinding to save curor position for returning after viewing other section of same buffer?
Whenever I make a large jump in a file, I press C-SPC C-SPC first. That sets the mark to the current value of point*, effectively remembering the current cursor position. Then, once I'm done ...
3
votes
Accepted
How to open a diff at the position of the current buffer?
Edit: this is now a package: diff-at-point
This solution parses the diff hunks to lookup a buffer location in the diff.
By default, if the current location isn't part of the diff, the closest line ...
3
votes
Is there a way to make the "o" keypress of other-window <C-x><C-o> repeatable?
hydra (https://github.com/abo-abo/hydra) are another way to get repeatable commands. This doesn't move the point on the first call, but you can press o as many times as you want to move around.
(...
3
votes
How to move the cursor to the next instance of the text the cursor is currently on?
Alternatively, you can use C-s C-w to search for some text the cursor is on.
2
votes
How to navigate quickly to my installed packages?
In recent versions of Emacs, you can access the package view with M-x list-packages. You can then filter the packages:
by upgradable with / u;
by any other status (available, dependency, disabled, ...
2
votes
Is there a setting to automatically center the text after any jump?
This recenters the point when the window moves by more than 5 lines, except in Isearch mode or when a scroll command is used (for scroll commands I think it's best to use scroll-preserve-screen-...
2
votes
Accepted
Previous/next occur result, independently from compilation errors
Looking at the source of occur-mode, I found this:
(setq next-error-function 'occur-next-error))
This suggests occur-next-error is the function next-error calls in a "occured" buffer. And indeed, ...
2
votes
Next/previous buffer in arbitrary order
The built-in bs library has support for defining one or more configurations that you can use to cycle between buffers. The commands bs-cycle-next and bs-cycle-previous move back and forth between the ...
2
votes
Accepted
2
votes
Go to window by buffername
For a slightly different approach, you can install the https://github.com/abo-abo/ace-window package (available from melpa) and bind ace-window to some key sequence. When you invoke it, it gives each ...
2
votes
Go to window by buffername
You can use interactive to select a buffer, get-buffer-window to find the window showing that buffer, and select-window to switch to that window:
(defun open-window-by-buffer (buffer)
(interactive &...
2
votes
Accepted
Open Dired for an arbitrary set of files
Not exactly sure what you're asking, but perhaps this will help. Offhand, a guess is that bookmarking Dired buffers is close to what you are looking for.
Dired itself lets you have a Dired buffer ...
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
navigation × 85org-mode × 8
window × 7
buffers × 6
bookmarks × 6
key-bindings × 5
motion × 5
python × 4
mark-ring × 4
cursor × 3
syntax × 3
words × 3
magit × 2
evil × 2
dired × 2
frames × 2
completion × 2
c++ × 2
mouse × 2
c × 2
code-folding × 2
mark × 2
directories × 2
balanced-parentheses × 2
occur × 2